Can I use JMS from Applets or do I have to use the J2EE Framework?
1 posts in topic
Flat View  Flat View

Posted By:   Giancarlo_Gallardo
Posted On:   Wednesday, March 6, 2002 02:09 PM

I'd like to send and receive messages using JMS but my client is an Applet and I don't know if this is possible.
I 've been searching but it seems that I always have to build a J2EE Application Client or an EJB to send messages, so I have to use an J2EE compliant server.

What about Applets????

thanks in advance.

Re: Can I use JMS from Applets or do I have to use the J2EE Framework?

Posted By:   Laurent_Mihalkovic  
Posted On:   Thursday, March 7, 2002 03:07 PM

i would venture that 'most likely you can't'. The reason would be that first of all, the applet can only talk to its server. So it means that the jms server should be at the same location as the applet's origine. But that is not an actual reason. What would be more of a pb is the way JMS is usaually implemented. It would not work with a JMS provider that uses client-based storage (the messages are sent directly to each client machines and stored on the file system). It would not work either with multicat based implementations. so considering all the technical impossibilities, you'd be left searching for a specific JMS client library implementation that can 'walk in between the rain-drops'.

I would avoid the problem alltogether by creating a servlet that does the job on behalf of the applet. The servlet is your JMS client (does the subscribe/publish) and the applet becomes a simple remote UI.

makes sense?



About | Sitemap | Contact