-
1. Re: Deployment related Issue
peterj Oct 22, 2009 11:48 AM (in response to rasa)Earlier in the console log there should be an exception and stack trace, please post that. (What you posted is the deployment report which rarely says what went wrong.)
-
2. Re: Deployment related Issue
rasa Oct 23, 2009 12:28 AM (in response to rasa)"PeterJ" wrote:
Earlier in the console log there should be an exception and stack trace, please post that. (What you posted is the deployment report which rarely says what went wrong.)
No Such exception.[EjbModule] Deploying MessageMDB 18:45:04,841 INFO [BaseLocalProxyFactory] Bound EJB LocalHome 'AccountCache' to jndi 'local/AccountCache@9059727' 18:45:04,880 INFO [ProxyFactory] Bound EJB Home 'AccountCache' to jndi 'AccountCache' 18:45:04,892 INFO [BaseLocalProxyFactory] Bound EJB LocalHome 'SecurityFacade' to jndi 'local/SecurityFacade@30506753' 18:45:04,902 INFO [ProxyFactory] Bound EJB Home 'SecurityFacade' to jndi 'SecurityFacade' 18:45:05,214 INFO [EJBDeployer] Deployed: file:/usr1/jboss-4.2.3.GA/server/default/deploy/application.ear/application.jar/ 18:45:05,862 INFO [TomcatDeployer] deploy, ctxPath=/jrap, warUrl=.../deploy/application.ear/application.war/ 18:45:06,765 ERROR [STDERR] ********************************************************* 18:45:06,766 ERROR [STDERR] Initializing Salmon Framework Property files 18:45:06,766 ERROR [STDERR] Salmon Server Properties File Directory:/usr1/jboss-4.2.3.GA/server/default/deploy/jboss-web.deployer/salmonprops 18:45:06,766 ERROR [STDERR] Absolute path is:/usr1/jboss-4.2.3.GA/server/default/deploy/jboss-web.deployer/salmonprops 18:45:06,766 ERROR [STDERR] To change the property file location, set the VM System property "salmon.props.path" via the -D runtime switch. 18:45:06,766 ERROR [STDERR] ********************************************************* 18:45:07,293 INFO [EARDeployer] Started J2EE application: file:/usr1/jboss-4.2.3.GA/server/default/deploy/jrap.ear/ 18:45:07,297 ERROR [URLDeploymentScanner] Incomplete Deployment listing: --- MBeans waiting for other MBeans ---
And one more error i found in server.log.2009-10-22 16:55:22,032 DEBUG [org.jboss.ejb.MessageDrivenContainer] End java:comp/env for EJB: MessageMDB 2009-10-22 16:55:22,032 DEBUG [org.jboss.ejb.plugins.local.BaseLocalProxyFactory] MessageMDB cannot be Bound, doesn't have local and local home interfaces
In our dd for MDB there is no local attribute. Actually it is not necessary. But BaseLocalProxyFactory is handling all the ejb classes in that way. May i know is there any different configuration available to disable such checking ?
Regards
Rasa. -
3. Re: Deployment related Issue
peterj Oct 23, 2009 11:21 AM (in response to rasa)Is your message-driven bean based on EJB 3 or 2.x? If 2.x, please post the descriptor file. If 3, please post the source code (you can remove the contents of the methods).
-
4. Re: Deployment related Issue
rasa Oct 26, 2009 12:51 AM (in response to rasa)"PeterJ" wrote:
Is your message-driven bean based on EJB 3 or 2.x? If 2.x, please post the descriptor file. If 3, please post the source code (you can remove the contents of the methods).
I am using ejb 2.0 see my entry for MessageMDB.java<message-driven> <ejb-name>MessageMDB</ejb-name> <ejb-class>com.apps.ejb.message.MessageMDB</ejb-class> <transaction-type>Container</transaction-type> <acknowledge-mode>AUTO_ACKNOWLEDGE</acknowledge-mode> <message-driven-destination> <destination-type>javax.jms.Queue</destination-type> </message-driven-destination> </message-driven>
-
5. Re: Deployment related Issue
peterj Oct 26, 2009 10:27 AM (in response to rasa)Looks like you are missing the queue to which the MDB will listen.
-
6. Re: Deployment related Issue
rasa Oct 26, 2009 11:55 PM (in response to rasa)"PeterJ" wrote:
Looks like you are missing the queue to which the MDB will listen.
The given dd is perfectly working with jboss 3.2.5. -
7. Re: Deployment related Issue
peterj Oct 27, 2009 11:21 AM (in response to rasa)I have no idea what 3.2.5 did if you did not specify a queue name (or how one could be specified outside the ejb-jar.xml file), but apparently 4.2.3 wants one. I'll leave it to you to look up the config settings.
-
8. Re: Deployment related Issue
rasa Oct 28, 2009 1:00 AM (in response to rasa)"PeterJ" wrote:
I have no idea what 3.2.5 did if you did not specify a queue name (or how one could be specified outside the ejb-jar.xml file), but apparently 4.2.3 wants one. I'll leave it to you to look up the config settings.
No actually what we are doing is we are creating queue througha class which is deployed as a sar file and it is bounded with jboss. So no need of queue name in dd. and our standardjboss.xml file is<message-driven> <ejb-name>first_queue</ejb-name> <configuration-name>Sending Message Driven Bean</configuration-name> <destination-jndi-name>first_queue</destination-jndi-name> <depends>jboss.j2ee:jndiName=local/MessageMDB,service=EJB,plugin=invoker,binding=Receiving-message-driven-bean </depends> </message-driven>
I feel the issue is with the depends tag. -
9. Re: Deployment related Issue
jaikiran Oct 28, 2009 1:45 AM (in response to rasa)jboss.j2ee:jndiName=local/MessageMDB,service=EJB,plugin=invoker,binding=Receiving-message-driven-bean
Who sets up that MBean? Looking at the name, it isn't setup by JBoss by default. So something in your application is expected to setup/configure an MBean with that name. -
10. Re: Deployment related Issue
peterj Oct 28, 2009 10:42 AM (in response to rasa)I suspect that the mbean you are depending on probably existed in 3.2.5 but no longer exists in 4.2.x. I recommend that you use JndiView to determine what mbeans are available in 4.2.x and choose one of those to depend on.
I guess I should have looked at the deployment report you posted earlier a little closer because in this case it did provide enough info to point out the problem. -
11. Re: Deployment related Issue
rasa Dec 3, 2009 8:30 AM (in response to rasa)I didnt't made nay changes but it started working. Let me observe it in production env.
-
12. Re: Deployment related Issue
rasa Mar 12, 2010 6:10 AM (in response to peterj)Looks like you are missing the queue to which the MDB will listen.
Hope you are talking about Jndi Name. But i hae checked sun's document http://docs.sun.com/app/docs/doc/819-4721/6n6rrfqsk?a=view
In that they have given ejb-jar entry like this
<enterprise-beans>
<message-driven>
<ejb-name>MessageBean</ejb-name>
<ejb-class>samples.mdb.ejb.MessageBean</ejb-class>
<transaction-type>Container</transaction-type>
<message-driven-destination>
<destination-type>javax.jms.Queue</destination-type>
</message-driven-destination>
<resource-ref>
<res-ref-name>jms/QueueConnectionFactory</res-ref-name>
<res-type>javax.jms.QueueConnectionFactory</res-type>
<res-auth>Container</res-auth>
</resource-ref>
</message-driven>
</enterprise-beans>in this jndiname is missing , but the same is given just below in that document. But it is <sun-ejb-jar> i am really confused.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sun-ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Application
Server 8.1 EJB 2.1//EN'
'http://www.sun.com/software/appserver/dtds/sun-ejb-jar_2_1-1.dtd'>
<sun-ejb-jar>
<enterprise-beans>
<ejb>
<ejb-name>MessageBean</ejb-name>
<jndi-name>jms/sample/Queue</jndi-name>
<resource-ref>
<res-ref-name>jms/QueueConnectionFactory</res-ref-name>
<jndi-name>jms/sample/QueueConnectionFactory</jndi-name>
<default-resource-principal>
<name>guest</name>
<password>guest</password>
</default-resource-principal>
</resource-ref>
<mdb-connection-factory>
<jndi-name>jms/sample/QueueConnectionFactory</jndi-name>
<default-resource-principal>
<name>guest</name>
<password>guest</password>
</default-resource-principal>
</mdb-connection-factory>
</ejb>
</enterprise-beans>
</sun-ejb-jar>In my casei am getting some sort of warningpasting that too here
10:49:22,638 INFO [JMSContainerInvoker] Trying to reconnect to JMS provider for test_mdb_stn
10:49:22,643 WARN [JMSContainerInvoker] Could not find the queue destination-jndi-name=test_mdb_stn10:49:22,645 WARN [JMSContainerInvoker] destination not found: queue/test_mdb_stn: javax.naming.NameNotFoundException
10:49:22,645 WARN [JMSContainerInvoker] creating a new temporary destination: queue/test_mdb_stn
10:49:22,647 INFO [test_mdb_stn] Registration is not done -> stop
10:49:22,648 ERROR [JMSContainerInvoker] Reconnect failed: JMS provider failure detected for test_mdb_stnThis is coming from createDestination method JMSContainerInvoker class
protected Destination createDestination(final Class type,
final Context ctx,
final String jndiName,
final String jndiSuffix)
throws Exception
{
try
{
// first try to look it up
return (Destination) ctx.lookup(jndiName);
}
catch (NamingException e)
{
// if the lookup failes, the try to create it
log.warn("destination not found: " + jndiName + " reason: " + e);
log.warn("creating a new temporary destination: " + jndiName);
//
// jason: we should do away with this...
//
// attempt to create the destination (note, this is very
// very, very unportable).
//
MBeanServer server = org.jboss.mx.util.MBeanServerLocator.locateJBoss();
String methodName;
if (type == Topic.class)
{
methodName = "createTopic";
}
else if (type == Queue.class)
{
methodName = "createQueue";
}
else
{
// type was not a Topic or Queue, bad user
throw new IllegalArgumentException
("Expected javax.jms.Queue or javax.jms.Topic: " + type);
}
// invoke the server to create the destination
server.invoke(new ObjectName("jboss.mq:service=DestinationManager"),
methodName,
new Object[]{jndiSuffix},
new String[]{"java.lang.String"});
// try to look it up again
return (Destination) ctx.lookup(jndiName);
}
}If i will give my jndi name then i can create my own rt ????
After the above warning the following exceptions are getting printed in console
org.jboss.deployment.DeploymentException: Error during queue setup; - nested throwable: (javax.management.MBeanException)
at org.jboss.deployment.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:53)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:916)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker$ExceptionListenerImpl$ExceptionListenerRunnable.run(JMSContainerInvoker.java:1533)
at java.lang.Thread.run(Thread.java:595)
Caused by: javax.management.MBeanException
at org.jboss.mx.interceptor.ReflectedDispatcher.handleInvocationExceptions(ReflectedDispatcher.java:180)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:163)
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.ejb.plugins.jms.JMSContainerInvoker.createDestination(JMSContainerInvoker.java:1218)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:882)
... 2 more
Caused by: javax.management.InstanceAlreadyExistsException: jboss.mq.destination:service=Queue,name=test_mdb_stn already registered.
at org.jboss.mx.server.registry.BasicMBeanRegistry.add(BasicMBeanRegistry.java:761)
at org.jboss.mx.server.registry.BasicMBeanRegistry.registerMBean(BasicMBeanRegistry.java:225)
at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:592)
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.server.MBeanServerImpl$3.run(MBeanServerImpl.java:1422)
at java.security.AccessController.doPrivileged(Native Method)
at org.jboss.mx.server.MBeanServerImpl.registerMBean(MBeanServerImpl.java:1417)
at org.jboss.mx.server.MBeanServerImpl.createMBean(MBeanServerImpl.java:295)
at org.jboss.mq.server.jmx.DestinationManager.createDestination(DestinationManager.java:327)
at org.jboss.mq.server.jmx.DestinationManager.createQueue(DestinationManager.java:293)
at sun.reflect.GeneratedMethodAccessor91.invoke(Unknown Source)Since the jboss is started as a different instance on different ip( single NIC) but same machine so i can't check the jmx console and confirm the jndi registration.
-
13. Re: Deployment related Issue
rasa Mar 12, 2010 2:09 AM (in response to rasa)In standard-jboss.xml i have given the entry as follows
<message-driven>
<ejb-name>test_mdb_stn</ejb-name>
<configuration-name>My Message Driven Bean</configuration-name>
<destination-jndi-name>test_mdb_stn</destination-jndi-name>
</message-driven>This is based on 3.2.5 jboss here what is meant by <destination-jndi-name>. Hope this is not same as
<jndi-name>jms/sample/Queue</jndi-name>