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

Attempt to sendMsg using a closed connection

0 views
Skip to first unread message

Steve Barber

unread,
Sep 12, 2002, 3:30:40 PM9/12/02
to

I just started getting these wonderful exceptions trying to look up a JMS Connection
Factory from an external process to WebLogic Server 6.1 SP3 (platform is Windows
2000):

java.rmi.ConnectException: Attempt to sendMsg using a closed connection
at weblogic.rmi.internal.BasicOutboundRequest.sendReceive(BasicOutboundRequest.java:85)
at weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java:262)
at weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java:229)
at weblogic.rmi.internal.ProxyStub.invoke(ProxyStub.java:35)
at $Proxy0.lookup(Unknown Source)
at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:341)
at javax.naming.InitialContext.lookup(InitialContext.java:345)
at com.abc.MyServer.initJMS(MyServer.java:250)
at com.abc.MyServer.MyServer.init(TradeFactoryServer.java:99)
at com.abc.MyServer.main(MyServer.java:612)

MyServer.java:250 looks like this:

QueueConnectionFactory factory = (QueueConnectionFactory) context.lookup(jmsFactory);

Doesn't happen all the time. The pattern is (usually) like this:

startWeblogic
startMyServer (everything is fine)
kill MyServer
startMyServer (get the exception)
startMyServer (get the exception)
startMyServer (get the exception)
. . .
wait a few hours
startMyServer (everything is fine)
kill MyServer
startMyServer (get the exception)
..etc.

"kill MyServer" could be Ctrl-C or exiting after calling queueConnection.stop();
queueReceiver.close();
queueSession.close();
queueConnection.close();

, it doesn't matter, the exception still happens

Could be a JMS problem, could be a JNDI problem, could be something else?

To make this even more fun, it happens on one machine's instance of WebLogic,
but not another's.

Any insights?

-Steve Barber


Zach

unread,
Sep 12, 2002, 5:02:48 PM9/12/02
to
The stack trace shown is JNDI. When you get this exception, throw away
your existing initial context and create a new one. Then do then do the
lookup with the new context.

"Steve Barber" <sba...@randomwalk.com> wrote in message
news:3d80...@newsgroups.bea.com...

0 new messages