I have implemented some remote method invocation using sockets opened on 127.0.0.1. During programs run, computers public IP address changes, because my program connects to net via GPRS modem from time to time. Can you tell me how does that affect my opened sockets? Java version is 1.3, windows platform. There are several network interfaces and their ip address changes over time (+VPN connection is established). But client and server are on the same machine, and use 127.0.0.1 to establish connection over sockets. Is there any way that this address changing over these network interfaces affects 127.0.0.1 communication.
+7
A:
Beyond the obvious question of why on God's green earth you're using Java 1.3 (when Java 1.4 is no longer supported), localhost is localhost. It's not impacted by whatever IP address your modem (GPRS or otherwise) assigns you. It's fine.
cletus
2009-01-21 13:33:26
+1 for "why on God's green earth "
Markus Lausberg
2009-01-21 13:42:55
code is in process of moving to java version 1.6.0.11 ;)
tropikalista
2009-01-21 13:48:45
That will be an interesting transition. :)
Bill the Lizard
2009-01-21 13:54:00
There's plenty of 1.1 code still in production. Things have one downhill from there, anyway :)
2009-01-21 14:09:11
I interviewed somewhere last year that was still on java 1.2 ... I was mad confused
2009-01-21 14:15:26
I'd run to the hills from anyplace that didn't use at least Java 5.
cletus
2009-01-21 14:27:09
I'd want to see 1.3 -> 1.6 transition just for the kicks since there's bound to be tons of Generics, foreach and varargs related refactorings at least, not to mention all the possibly fixed API:s and replacements etc. :D
Esko
2009-01-21 15:47:01
You cannot defeat the loopback.
windfinder
2009-01-21 21:52:29
@Esko transition went well so far, refactoring will be part of the next patches, when we come along those issues they will be solved. core functionalities work very well @windfinder details please?
tropikalista
2009-01-22 13:33:31
@windfinder no need for details :)
tropikalista
2009-01-22 16:00:22
+2
A:
did you for sure bind to the localhost address on the server?
ServerSocket(int port, int backlog, InetAddress bindAddr)
l_39217_l
2009-01-21 17:36:16
A:
localhost will work even if you pull out your network connections and disable or remove all your network adapter.
Peter Lawrey
2009-01-21 21:45:21