开发者

Automatic JMS Queue/Factory deployment

开发者 https://www.devze.com 2023-03-17 22:58 出处:网络
We have some strange behaviour with the deployment of our message queues and factories on Glassfish 3.1 . There is one factory and some queues which use that factory. The queues are defined in a file

We have some strange behaviour with the deployment of our message queues and factories on Glassfish 3.1 . There is one factory and some queues which use that factory. The queues are defined in a file named sun-resources.xml . When we deploy our application with netbeans the factory + queues will be automatically created (if not exists) and everything works fine. But when the queues not exists and we deploy the application through glassfish admin console everytime this exception is thrown:

Caused by: com.sun.appserv.connectors.internal.api.ConnectorRuntimeException: No local string defined at com.sun.enterprise.connectors.jms.system.ActiveJmsResourceAdapter.get开发者_JAVA技巧PhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:2061) at com.sun.enterprise.connectors.jms.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1864) at com.sun.enterprise.connectors.inbound.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:186) at com.sun.ejb.containers.MessageBeanContainer.(MessageBeanContainer.java:204) at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:121) at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:234) ... 67 more Caused by: com.sun.appserv.connectors.internal.api.ConnectorRuntimeException: No local string defined at com.sun.enterprise.connectors.jms.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:2055) ... 72 more

This is a known error in glassfish 3.1. The application server gets an exception while deployment and wants to create a description of the error. The stacktrace of a missing resource bundle (in glassfish) hides the original exception which causes the error.

What is the difference between deploying the app through netbeans/console and why does this error happen?


NetBeans reads the sun-resources.xml file when you deploy and 'does the right thing' with the info that it finds in there. The admin gui is using the data that is in your archive... which does not include the sun-resources.xml file... and so, there is a deployment error.

You may want to use the asadmin sub command add-resources to register the resources defined in the sun-resources.xml file and then use the admin gui to deploy your archived application.

0

精彩评论

暂无评论...
验证码 换一张
取 消