jackjav said:
Thanks for your help, sure that's a good way to start to learn on
sockets.
Although I am not an expert, I did do some search for the
multithreaded socket programming gathered some knowledge, but was
I'm not really an expert either, but I'm trying to learn more about Java
network programming so your question was interesting to me.
My first question back is "What is fixedformat?" Is that some Java term
I'm not familiar with or some other API? Other than the obvious (just a
descriptive term), I didn't recognize it.
The second server processes the input data, and returns response to
the socketserver, which inturn will send it to the client. The caveat
as you see is that for the secondserver I cannot use sockets, my
options are http/https/webservices.
An HTTP connection IS a socket. There's plenty of examples of speaking
HTTP over a Java socket on the web. If you can't find any to your
liking, I think the example HTTP server in O'Reilly's _Learning Java_ is
a pretty good example.
And the client waits for the response on the request made.
You have three servers here, not two. Any system that waits for
incoming requests is a server, and you'll need to make sure all
firewalls, proxies, etc. in front of this "client" can accept an
incoming request from a foreign system.
If not, you may have to leave the original connection open from the
client, and have the first sever relay the message for server2.