骡子与JBOSS 5.1主题

时间:2014-04-15 19:39:05

标签: jboss dependencies mule jms-topic

我需要订阅Mule的JBOSS 5.1主题。 这是我正在使用的配置。

<jms:connector name="jMSConnector"    jndiInitialFactory="org.jnp.interfaces.NamingContextFactory"    connectionFactoryJndiName="/ClusteredConnectionFactory"   jndiProviderUrl="jnp://localhost:1099"
jndiDestinations="true" forceJndiDestinations="true" specification="1.1"   doc:name="JMS"/>
<flow name="testFlow1" doc:name="testFlow1">
   <jms:inbound-endpoint doc:name="JMS" connector-ref="jMSConnector" topic="jms/topic/testtopic"/>
   <logger message="#[message.payload]" level="INFO" doc:name="Logger"/>
</flow>

我在classpath中包含了以下jar:     concurrent.jar     的jboss-AOP-client.jar中     JBoss的常见-core.jar添加     JBoss的日志记录,spi.jar     的jboss-mdr.jar     JBoss的消息传递-client.jar中     的jboss-remoting.jar     JNP-client.jar中     trove.jar

我在尝试运行应用时遇到以下错误。有人能告诉我我应该使用的确切依赖罐吗?

java.lang.NoSuchMethodError: org.jboss.logging.Logger.getLoggerPlugin()Lorg/jboss/logging/LoggerPlugin;
at org.jboss.aop.util.logging.AOPLogger.<init>(AOPLogger.java:63)
at org.jboss.aop.util.logging.AOPLogger.getLogger(AOPLogger.java:44)
at org.jboss.aop.AspectManager.<clinit>(AspectManager.java:109)
at org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate.<clinit>(ClientClusteredConnectionFactoryDelegate.java)
at sun.misc.Unsafe.ensureClassInitialized(Native Method)
at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
at java.lang.reflect.Field.getLong(Field.java:591)
at java.io.ObjectStreamClass.getDeclaredSUID(ObjectStreamClass.java:1663)
at java.io.ObjectStreamClass.access$700(ObjectStreamClass.java:72)
at java.io.ObjectStreamClass$2.run(ObjectStreamClass.java:480)
at java.io.ObjectStreamClass$2.run(ObjectStreamClass.java:468)
at java.security.AccessController.doPrivileged(Native Method)
at java.io.ObjectStreamClass.<init>(ObjectStreamClass.java:468)
at java.io.ObjectStreamClass.lookup(ObjectStreamClass.java:365)
at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:602)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1622)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1517)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1771)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1350)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1990)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1915)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1798)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1350)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:370)
at java.rmi.MarshalledObject.get(MarshalledObject.java:159)
at org.jnp.interfaces.MarshalledValuePair.get(MarshalledValuePair.java:72)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:769)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
at javax.naming.InitialContext.lookup(InitialContext.java:411)
at org.mule.transport.jms.jndi.SimpleJndiNameResolver.lookup(SimpleJndiNameResolver.java:31)
at org.mule.transport.jms.JmsConnector.createConnectionFactory(JmsConnector.java:282)
at org.mule.transport.jms.JmsConnector.createConnection(JmsConnector.java:404)
at org.mule.transport.jms.JmsConnector.doConnect(JmsConnector.java:515)
at org.mule.transport.AbstractConnector$5.doWork(AbstractConnector.java:1556)
at org.mule.retry.policies.AbstractPolicyTemplate.execute(AbstractPolicyTemplate.java:67)
at org.mule.transport.AbstractConnector.connect(AbstractConnector.java:1616)
at org.mule.transport.jms.JmsConnector.connect(JmsConnector.java:458)
at org.mule.transport.AbstractConnector.start(AbstractConnector.java:428)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.mule.lifecycle.phases.DefaultLifecyclePhase.applyLifecycle(DefaultLifecyclePhase.java:225)
at org.mule.lifecycle.RegistryLifecycleManager$RegistryLifecycleCallback.onTransition(RegistryLifecycleManager.java:276)
at org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:155)
at org.mule.lifecycle.RegistryLifecycleManager.fireLifecycle(RegistryLifecycleManager.java:126)
at org.mule.registry.AbstractRegistryBroker.fireLifecycle(AbstractRegistryBroker.java:80)
at org.mule.registry.MuleRegistryHelper.fireLifecycle(MuleRegistryHelper.java:120)
at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:94)
at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:90)
at org.mule.lifecycle.MuleContextLifecycleManager.invokePhase(MuleContextLifecycleManager.java:72)
at org.mule.lifecycle.MuleContextLifecycleManager.fireLifecycle(MuleContextLifecycleManager.java:64)
at org.mule.DefaultMuleContext.start(DefaultMuleContext.java:255)
at org.mule.module.launcher.application.DefaultMuleApplication.start(DefaultMuleApplication.java:147)
at org.mule.module.launcher.application.ApplicationWrapper.start(ApplicationWrapper.java:107)
at org.mule.module.launcher.DefaultMuleDeployer.deploy(DefaultMuleDeployer.java:48)
at org.mule.tooling.server.application.ApplicationDeployer.run(ApplicationDeployer.java:58)
at org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java:91)

2 个答案:

答案 0 :(得分:0)

如果您使用的是Maven,之前我刚刚使用了以下依赖项:

    <dependency>
        <groupId>org.jboss.jbossas</groupId>
        <artifactId>jboss-as-client</artifactId>
        <type>pom</type>
        <version>5.1.0.GA</version>
    </dependency>

修改 添加以下存储库:

<repositories>
        <repository>
            <id>jboss-maven2</id>
            <url>http://repository.jboss.org/nexus/content/groups/public-jboss/</url>
        </repository>
        <repository>
                    <id>jboss-deprecated-repository</id>
                    <name>JBoss Deprecated Maven Repository</name>
                    <url>https://repository.jboss.org/nexus/content/repositories/deprecated/</url>
                    <layout>default</layout>
                    <releases>
                        <enabled>true</enabled>
                        <updatePolicy>never</updatePolicy>
                    </releases>
                    <snapshots>
                        <enabled>false</enabled>
                        <updatePolicy>never</updatePolicy>
                    </snapshots>
                </repository>
    </repositories>

答案 1 :(得分:0)

当我从Mule CE 3.4.0运行时删除jboss-logging-3.0.0.Beta5.jar时,此问题得到解决。但我不知道是否会引起其他问题。然而要弄清楚。