You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by northshorefiend <sp...@JamesAshepherd.com> on 2007/05/02 20:52:08 UTC

WebClient and multiple chat client

As many before me, I'm sure, I tried the activemq-web-demo chat client and
found that you only get one working chat client per HttpSession.

I'm new to ActiveMQ, but has anyone tried something like optionally having
amq(.js) instances having a UID on birth and passing that to
MessageListenerServlet, which uses a corresponding instance of WebClient
stored in the HttpSession.

Seems to me this would enable the MesssageListenerServlet to know which amq
instance it was replying to, and each WebClient would acting on behalf of a
single amq instance.

I assume this behaviour may not be wanted by most users, but apart from
that, am I missing any asynchronous consequences?

If this is sensible I might try putting together a patch.
-- 
View this message in context: http://www.nabble.com/WebClient-and-multiple-chat-client-tf3682481s2354.html#a10292275
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.


Re: WebClient and multiple chat client

Posted by James Strachan <ja...@gmail.com>.
On 5/2/07, northshorefiend <sp...@jamesashepherd.com> wrote:
>
> As many before me, I'm sure, I tried the activemq-web-demo chat client and
> found that you only get one working chat client per HttpSession.
>
> I'm new to ActiveMQ, but has anyone tried something like optionally having
> amq(.js) instances having a UID on birth and passing that to
> MessageListenerServlet, which uses a corresponding instance of WebClient
> stored in the HttpSession.
>
> Seems to me this would enable the MesssageListenerServlet to know which amq
> instance it was replying to, and each WebClient would acting on behalf of a
> single amq instance.
>
> I assume this behaviour may not be wanted by most users, but apart from
> that, am I missing any asynchronous consequences?
>
> If this is sensible I might try putting together a patch.

There's a risk that the client could spoof zillions of UIDs though; so
you might want to restrict the number of UIDs on the broker side (&
reject fake ones). But sure, a patch sounds great :)

-- 
James
-------
http://macstrac.blogspot.com/