Tuesday, January 6, 2004 06:08 AM
I have a spec here which talks about sending a string query to another system. The string is entered in a html form and then a servlet opens a socket connection to the consumer system written in C++. The system then processes the info and sends a response. When the system will finish the processing and send the data back is an unknown. I am caught between developing a pure sockets system versus using JMS. But the catch, I guess is that the other sys being in C++, cannot talk that easily to the JMS system. But again the user can't be kept waiting for the response
a)What is a good arch for doing this?
b) Any good literature (online preferably) on developing web based asynchronous socket apps?
Re: Can JMS be used to substitute for socket-based exchanges between heterogenous systems?
Wednesday, January 14, 2004 08:39 AM
In your case, the servlet could publish JMS messages (request for processing of form information) onto a queue (using default Java-JMS binding). Messages on this queue would then be consumed by the C++ back-end system, using the C++/JMS binding. The advantage of using JMS compared to sockets is that you get asynchrony and higher reliability (+transactions if requried). Disadvantage is additional architectural complexity and lower performance.
Hope this helps!Thomas www.arjuna.com
Thursday, January 8, 2004 08:46 AM