Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

weblogic.rjvm.PeerGoneException: Peer requested connection shutdown after message listener is idle for 5-10 minutes

667 views
Skip to first unread message

Matt Stone

unread,
Jul 1, 2003, 12:37:59 PM7/1/03
to

I am experiencing an error when using Weblogic Server 8.1 and subscribing to a
topic. I get this exception in the ExceptionListener when the connection is idle
(no messages have been received, because none have been sent) for 5-10 minutes:

weblogic.jms.common.LostServerException: weblogic.rjvm.PeerGoneException: Peer
requested connection shutdown
at weblogic.jms.client.JMSConnection.jmsPeerGone(JMSConnection.java:877)
at weblogic.jms.dispatcher.DispatcherWrapperState.peerGone(DispatcherWrapperState.java:658)
at weblogic.jms.dispatcher.DispatcherWrapperState.callback(DispatcherWrapperState.java:546)
at weblogic.rjvm.RJVMImpl$HeartbeatMonitorListenerDeliverer.execute(RJVMImpl.java:1392)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:178)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:151)


Here is how I create a connection, a session, and a subscriber, and set a single
MessageListener:

TopicConnectionFactory factory = (TopicConnectionFactory)ctx.lookup("weblogic.jms.ConnectionFactory");
jmsConnection = factory.createTopicConnection();
jmsSession = jmsConnection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
jmsConnection.setExceptionListener(exceptionListener);
TopicSubscriber subscriber = jmsSession.createSubscriber(topic, selector,
false);
subscriber.setMessageListener(messageListener);
jmsConnection.start();

And after about 5-10 minutes, the exceptionListener recieves the exception listed
above.

I have recently implemented something in the client that creates the connection
again if it fails. If I leave it running for a while, I get the LostServerException
every 5-10 minutes continually.

I read in the bea documents for 8.1 that a JMS Server will send a heartbeat every
60 seconds to a subscriber to make sure it is alive. If 4 of these messages are
not acknowleged, the server drops the connection. Could this be what is happening?
Why might the client not receive the heartbeats? Is there a way to determine if
these heartbeats are being received? Or could this be another problem entirely?

Thanks for any help,
Matt

Tom Barnes

unread,
Jul 2, 2003, 10:36:28 PM7/2/03
to Matt Stone
Hi Matt,

Are you by chance using the 8.1 thin client? The thin client
uses the IIOP protocol, even if t3 is specified in the URL.
Or perhaps http tunneling? Either http or iiop have
have configurable idle connection timeouts - these idle
timeouts are set on a per WebLogic server basis (not
a per JMS server basis). Check your WL server's network
settings.

Tom, BEA

P.S. You are largely correct about the heartbeat mechanism. But
technically, it is not the JMS layer, but the WebLogic RMI layer
which controls the heartbeats. In your case, I do not suspect
lost heartbeats are the problem, as I infer that other
RMI traffic does get through (in the form of JMS messages
for example).

0 new messages