-
1. Re: [BisocketServerInvoker] unrecognized listener ID: ...
smurfs Apr 24, 2007 10:00 AM (in response to smurfs)Apologies, forgot to mention - I'm running jboss-messaging-1.2.0.SP1 on jboss-4.0.5.GA
-
2. Re: [BisocketServerInvoker] unrecognized listener ID: ...
ron_sigal Apr 26, 2007 4:08 AM (in response to smurfs)Hi Andrew,
I'm the author of that warning, which I expected to appear only in the event of some unexpected problem. Are you saying that that it's appearing in the normal course of events, in the absence of any problematic conditions, when you start and stop the server? Could you clarify the phrase "each time it fires"?
In any case, I don't think you've done anything wrong, but I'd like to understand what's happening.
Thanks,
Ron -
3. Re: [BisocketServerInvoker] unrecognized listener ID: ...
smurfs Apr 26, 2007 10:05 AM (in response to smurfs)Hi Ron,
Thanks for your response. I have spent a bit of time investigating the circumstances that trigger the WARN message, and can advise that it only seems to be triggered after a call to the connection close() method.
If you run the following code snippet in a session bean you ought to be able to replicate what I have been experiencing.@Resource(mappedName="ConnectionFactory") private ConnectionFactory connectionFactory; @Resource(mappedName="queue/someQueue") private Destination someQueue; private void testMDB() { Connection connection = null; Session session = null; MessageProducer producer = null; try { log.info("\n**** MDB example 1 (with finally block) ****"); connection = connectionFactory.createConnection(); session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE); producer = session.createProducer(someQueue); ObjectMessage message = session.createObjectMessage(); message.setObject(new String("some serialized object 1")); producer.send(message); log.info("MDB example 1 dispatched"); } catch (JMSException jmse) { log.error("MDB example 1 jms error: " + jmse.getMessage()); jmse.printStackTrace(); } finally { try { log.info("MDB example 1 - closing connection in finally block"); if (connection != null) connection.close(); } catch (JMSException jmsex) {} } try { log.info("\n**** MDB Example 2 (without finally block) ****"); connection = connectionFactory.createConnection(); session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE); producer = session.createProducer(someQueue); ObjectMessage message = session.createObjectMessage(); message.setObject(new String("some serialized object 2")); producer.send(message); log.info("MDB example 2 dispatched"); } catch (JMSException jmse) { log.error("MDB example 2 jms error: " + jmse.getMessage()); jmse.printStackTrace(); } // No finally block and no WARN message, but connection not closed! }
I trust this clearly demonstrates the issue and clarifies what I previously tried to outline/explain.
Thanks, Andrew -
4. Re: [BisocketServerInvoker] unrecognized listener ID: ...
timfox Apr 26, 2007 10:12 AM (in response to smurfs)First observation - you are using the ConnectionFactory at /ConnectionFactory in JNDI - this is the non JCA (plain) connection factory - so you will be creating and closing a real JMS connection every time the MDB receives a message!
This is going to be *slow*. I'm assuming this is not what you intended to do.
The pattern you are using (Create connection every time) is only appropriate when you are using the JCA managed connection factory which actually caches the connections under the bonnet.
See http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossJMSRA.
The problem with remoting throwing the warning every time a connection is closed remains - I have seen this too and will wait for Ron to dig some more. -
5. Re: [BisocketServerInvoker] unrecognized listener ID: ...
smurfs Apr 26, 2007 4:35 PM (in response to smurfs)Tim, thanks for the feedback.
This is going to be *slow*. I'm assuming this is not what you intended to do.
No, it was not intentional but an oversight on my part due to my limited experience with messaging.
I have changed over to the JmsXA connection factory and this also appears to have solved the WARN issue when messages are dispatched to the JMS queue - although I still get them when shutting the server down, but that is something I can live with. -
6. Re: [BisocketServerInvoker] unrecognized listener ID: ...
ron_sigal Apr 27, 2007 3:04 AM (in response to smurfs)Hi Andrew,
1. I apologize for my bewildering request for a clarification of "each time it fires". I read too quickly and missed "a MDB" from the beginning of your question, and I thought "JBoss Messaging" was the antecedent of "it".
2. With your help I was able to reproduce the WARNING message, and I see why it's happening. I'll explain further in the related thread
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4040864#4040864
However, the cause is benign, and I'll make the message go away in the next release. Thanks for your help.
-Ron