[jboss-user] [JBoss Messaging] - JMS JNDI Names

loewe do-not-reply at jboss.com
Mon Nov 13 11:47:34 EST 2006


I ve written a simple Chat Programm, which uses the old JBossMQ JMS Provider.
In this Programm i am using subcontexts to build up a hierarchical structure of Chatrooms.
My old Service Descriptor looked like this:


  | <?xml version="1.0" encoding="UTF-8"?>
  | <!DOCTYPE server PUBLIC "-//JBoss//DTD MBean Service 3.2//EN" "http://www.jboss.org/j2ee/dtd/jboss-service_3_2.dtd">
  | 
  | <server>
  |  <mbean code="org.jboss.mq.server.jmx.Topic"
  |      name="jboss.mq.destination:service=Topic,name=jmschat/room/Lounge">
  |     <depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
  |   </mbean>
  | </server>
  | 
  | 

I ve realized that you developed a new "JBoss Messaging" and therefore i want to rewrite the Chat for the new Provider.
I added the Classloader entry and changed the Class-Names of the Topic's and Queue's.


  | <?xml version="1.0" encoding="UTF-8"?>
  | <!DOCTYPE server PUBLIC "-//JBoss//DTD MBean Service 3.2//EN" "http://www.jboss.org/j2ee/dtd/jboss-service_3_2.dtd">
  | 
  | <server>
  |   <loader-repository>jboss.messaging:loader=ScopedLoaderRepository
  |   	<loader-repository-config>java2ParentDelegation=false</loader-repository-config>
  |   </loader-repository>
  | 
  |   <mbean code="org.jboss.jms.server.destination.Topic"
  |      name="jboss.messaging.destination:service=Topic,name=jmschat/room/Lounge"
  |      xmbean-dd="xmdesc/Topic-xmbean.xml">
  |     <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
  |     <attribute name="SecurityConfig">
  |          <security>
  |             <role name="guest" read="true" write="true" create="true"/>
  |          </security>
  |     </attribute>
  |   </mbean>
  | </server>
  | 
  | 

But when i deploy the Service Descriptor, i get the following exception. :(


  | 17:42:49,765 ERROR [ExceptionUtil] Topic[null, name=jmschat/room/Lounge] startService
  | javax.naming.NameNotFoundException: jmschat not bound
  |         at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)
  |         at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)
  |         at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
  |         at org.jnp.server.NamingServer.rebind(NamingServer.java:165)
  |         at org.jnp.server.NamingServer.rebind(NamingServer.java:168)
  |         at org.jnp.interfaces.NamingContext.rebind(NamingContext.java:510)
  |         at org.jnp.interfaces.NamingContext.rebind(NamingContext.java:477)
  |         at org.jboss.jms.server.DestinationJNDIMapper.registerDestination(DestinationJNDIMapper.java:124)
  |         at org.jboss.jms.server.destination.DestinationServiceSupport.startService(DestinationServiceSupport.java:129)
  |         at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
  |         at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:196)
  |         at sun.reflect.GeneratedMethodAccessor69.invoke(Unknown Source)
  |         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  |         at java.lang.reflect.Method.invoke(Method.java:585)
  |         at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
  |         at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
  |         at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
  |         at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
  |         at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
  |         at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
  |         at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:995)
  |         at $Proxy0.start(Unknown Source)
  |         at org.jboss.system.ServiceController.start(ServiceController.java:417)
  |         at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
  |         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  |         at java.lang.reflect.Method.invoke(Method.java:585)
  |         at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
  |         at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
  |         at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
  |         at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
  |         at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
  |         at $Proxy4.start(Unknown Source)
  |         at org.jboss.deployment.SARDeployer.start(SARDeployer.java:302)
  |         at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
  |         at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
  |         at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
  |         at sun.reflect.GeneratedMethodAccessor52.invoke(Unknown Source)
  |         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  |         at java.lang.reflect.Method.invoke(Method.java:585)
  |         at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
  |         at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
  |         at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
  |         at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
  |         at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
  |         at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
  |         at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
  |         at $Proxy8.deploy(Unknown Source)
  |         at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
  |         at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:634)
  |         at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
  |         at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:274)
  |         at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:225)
  | 

I am not sure if the problem is the subcontext but it seams like it is!

You know a posible Solution or do i need to rewrite my Chat Programm?

Ralph

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3985514#3985514

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3985514



More information about the jboss-user mailing list