3 Replies Latest reply: May 29, 2012 5:59 AM by Peter Müller RSS

Problem with Mule und JBoss AS 7 (HornetQ)

Peter Müller Newbie

can somebody help me ??

Thanks. I have problem with the server in JBoss As 7. 

 

the class in Eclipse:

 

@MessageDriven(activationConfig = { @ActivationConfigProperty( propertyName = "destinationType", propertyValue = "javax.jms.Queue"), 
@ActivationConfigProperty( propertyName = "destination", propertyValue = "queue/MyQueue") }) 
public class BankMDB implements MessageListener { 
     public void onMessage(Message message) {
           .... 
     }
 }

  

 

the connector in Mule

<jms:connector name="jmsConnector"
connectionFactoryJndiName="ConnectionFactory"
jndiInitialFactory="org.jnp.interfaces.NamingContextFactory"
jndiProviderUrl="jnp://localhost:5445"
jndiDestinations="true"
forceJndiDestinations="true"
specification="1.1"/>

 

second try:

    <spring:bean name="soitoolkit-jms-connection-factory" class="org.hornetq.jms.client.HornetQJMSConnectionFactory">
        <spring:constructor-arg type="boolean" value="false"/>
        <spring:constructor-arg>
            <spring:bean name="transportConfiguration" class="org.hornetq.api.core.TransportConfiguration">
                <spring:constructor-arg value="org.hornetq.core.remoting.impl.netty.NettyConnectorFactory"/>
                <spring:constructor-arg>
                    <spring:map key-type="java.lang.String" value-type="java.lang.Object">
                        <spring:entry key="host" value="127.0.0.1"/>
                        <spring:entry key="port" value="5445"/>
                    </spring:map>
                </spring:constructor-arg>
            </spring:bean>
        </spring:constructor-arg>
    </spring:bean>

    <jms:connector name="soitoolkit-jms-connector" username="guest" password="guest" specification="1.1" connectionFactory-ref="soitoolkit-jms-connection-factory" 
        maxRedelivery="-1"/>

 

Error in Java:

WARN [org.hornetq.core.protocol.core.impl.RemotingConnectionImpl] (hornetq-failure-check-thread) Connection failure has been detected: Did not receive data from /127.0.0.1:60502. It is likely the client has exited or crashed without closing its connection, or the network between the server and client has failed. You also might have configured connection-ttl and client-failure-check-period incorrectly. Please check user manual for more information. The connection will now be closed. [code=3]

 

Error in Mule: 

ERROR 2012-05-26 21:51:12,801 [main] org.mule.tooling.server.application.ApplicationDeployer: null java.io.EOFException at java.io.ObjectInputStream$PeekInputStream.readFully(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown Source) at java.io.ObjectInputStream.readStreamHeader(Unknown Source) at java.io.ObjectInputStream.(Unknown Source) at org.jnp.interfaces.NamingContext.getServer(NamingContext.java:312) at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1734) at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:693) at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686) at javax.naming.InitialContext.lookup(Unknown Source) at org.mule.transport.jms.jndi.SimpleJndiNameResolver.lookup(SimpleJndiNameResolver.java:31) at org.mule.transport.jms.JmsConnector.createConnectionFactory(JmsConnector.java:294) at org.mule.transport.jms.JmsConnector.doInitialise(JmsConnector.java:205) at org.mule.transport.AbstractConnector$1.onTransition(AbstractConnector.java:378) at org.mule.transport.AbstractConnector$1.onTransition(AbstractConnector.java:353) at org.mule.lifecycle.AbstractLifecycleManager.invokePhase(AbstractLifecycleManager.java:141) at org.mule.transport.ConnectorLifecycleManager.fireInitialisePhase(ConnectorLifecycleManager.java:48) at org.mule.transport.AbstractConnector.initialise(AbstractConnector.java:352) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1536) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1477) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1409) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:574) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425) at org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:89) at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:109) at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:116) at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:73) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46) at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78) at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:101) at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:57) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46) at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78) at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:80) at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:203) at org.mule.module.launcher.application.ApplicationWrapper.init(ApplicationWrapper.java:64) at org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java:45) Exception in thread "main" org.mule.module.launcher.DeploymentInitException: EOFException: at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:215) at org.mule.module.launcher.application.ApplicationWrapper.init(ApplicationWrapper.java:64) at org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java:45) Caused by: org.mule.api.config.ConfigurationException: Error creating bean with name 'jmsConnector': Invocation of init method failed; nested exception is org.mule.api.lifecycle.InitialisationException: Error creating the connection factory (org.mule.api.lifecycle.InitialisationException)