[jboss-jira] [JBoss JIRA] Created: (JBMESSAGING-1762) Jboss shutdown produce error if ServerPeer's DefaultQueueJNDIContext is set empty.
Zemian Deng (JIRA)
jira-events at lists.jboss.org
Tue Nov 17 15:42:29 EST 2009
Jboss shutdown produce error if ServerPeer's DefaultQueueJNDIContext is set empty.
----------------------------------------------------------------------------------
Key: JBMESSAGING-1762
URL: https://jira.jboss.org/jira/browse/JBMESSAGING-1762
Project: JBoss Messaging
Issue Type: Bug
Components: AS Integration
Affects Versions: 1.4.3.GA
Environment: all platforms
Reporter: Zemian Deng
Hi there,
I think this affect on all jboss-server that using jboss-messaging-1.4.0.SP. I verified that this happens on jboss-5.1 as well as jboss-4.2
To reproduce it:
1. Open conf/deploy/jboss-messaging.sar/messaging-service.xml (jboss-4.x)
or conf/deploy/messaging/messaging-service.xml (jboss-5.x)
2. Change line from
<attribute name="DefaultQueueJNDIContext">/queue</attribute>
To
<attribute name="DefaultQueueJNDIContext"></attribute>
Startup jboss server (eg: bin/run -c default). Note that it starts up without problem, but when hit CTRL+C to shutdown, you will get Exception thrown:
15:27:14,652 ERROR [ExceptionUtil] ServerPeer[0] stopService
javax.naming.InvalidNameException
at org.jnp.server.NamingServer.unbind(NamingServer.java:308)
at org.jnp.interfaces.NamingContext.unbind(NamingContext.java:871)
at org.jnp.interfaces.NamingContext.unbind(NamingContext.java:854)
at javax.naming.InitialContext.unbind(InitialContext.java:416)
at org.jboss.jms.server.DestinationJNDIMapper.stop(DestinationJNDIMapper.java:264)
at org.jboss.jms.server.ServerPeer.stopService(ServerPeer.java:377)
I think the cause is that it tries to unbind an empty JNDI name!
Suggested solution:
On DestinationJNDIMapper.java:264, check getDefaultQueueJNDIContext() for empty before calling initialContext.unbind(serverPeer.getDefaultQueueJNDIContext());
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list