activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From StanleyH <>
Subject Re: best way to implement online status
Date Tue, 05 Sep 2006 23:30:47 GMT

I would lose some logout messages and then the contact list will display
people who already logged out but still show them online.

	    session1= connection.createSession(false,//  transaction
	    session2= connection.createSession(false,//  transaction
	  System.out.println("Authenticator running");
	   myqueue=(ActiveMQQueue) jmslocator.getQueue("dynamicQueues/auth");
	   String selector1="typeOfMessage='Login'";
	 String selector2="typeOfMessage='Logout'";
	 logout_consumer.setMessageListener(new LogoutListener());

Adrian Co wrote:
> Hi,
> Could you be more specific on how the results are incorrect?
> StanleyH wrote:
>> hi,  
>> I am trying to implement online/offline status using a queue.   I  have
>> an
>> authenticator who consumes login requests and put the screennames on a
>> queue
>> and when someone logouts the authenticator consumes the screennames on
>> that
>> queue.  I don't seem to get correct results sometimes.  I have a
>> connection
>> with two sessions -consumes login/logout using OnMessage (different
>> MessageListeners)

View this message in context:
Sent from the ActiveMQ - User forum at

View raw message