Description of problem: When creating JMS bridge on EAP6, I need to create a custom module with client jars for the external JMS broker (unless it's HornetQ). When I use client jars for JBoss Messaging from EAP 5.2.0, JMS bridge fails to load with "class "org.jboss.aop.advice.AbstractAdvice"'s signer information does not match signer information of other classes in the same package" (details below). The weird thing here is, that this was not an issue in EAP 6.3.0 and it's not an issue with EAP 6.4.0 and EAP 5.1.2. Only combination of EAP 6.4.0 and EAP 5.2.0 (and also 5.3.0.ER3) shows this error. It's only issue if the jars are signed, everything works as expected if I unsign the client jars. What is the desired (or supported) behavior here? Do we expect jars in the custom modules always unsigned? Version-Release number of selected component (if applicable): EAP 6.4.0.DR4 (JBoss Modules 1.3.4.Final) Steps to Reproduce: 1. Create test queue on EAP5 and EAP6 2. Create module with EAP5 client jars in EAP6 (eg com.redhat.qa.eap5client.jbm). module.xml will look like this (all the referenced jars need to be copied from $EAP5_HOME/jboss-as/client directory): <?xml version="1.0" encoding="UTF-8"?> <module xmlns="urn:jboss:module:1.1" name="com.redhat.qa.eap5client.jbm"> <resources> <resource-root path="jboss-messaging-client.jar" /> <resource-root path="jboss-aop-client.jar" /> <resource-root path="jnp-client.jar" /> <resource-root path="jboss-remoting.jar" /> <resource-root path="jboss-common-core.jar" /> <resource-root path="jbosssx-client.jar" /> <resource-root path="jboss-mdr.jar" /> <resource-root path="trove.jar" /> <resource-root path="javassist.jar" /> <resource-root path="concurrent.jar" /> <resource-root path="jboss-logging-spi.jar" /> <resource-root path="jboss-logging-log4j.jar" /> <resource-root path="log4j.jar" /> </resources> <dependencies> <module name="javax.api" /> <module name="javax.jms.api" /> <module name="javax.transaction.api" /> </dependencies> </module> 3. Configure the bridge on EAP6 in standalone-full.xml: <subsystem xmlns="urn:jboss:domain:messaging:1.4"> ... <jms-bridge name="jms-bridge-queue" module="com.redhat.qa.eap5client.jbm"> <!-- remote source destination on EAP5 --> <source> <connection-factory name="ConnectionFactory"/> <destination name="/queue/SenderQueue"/> <context> <property key="java.naming.provider.url" value="jnp://localhost:1099"/> <property key="java.naming.factory.initial" value="org.jnp.interfaces.NamingContextFactory"/> <property key="java.naming.factory.url.pkgs" value="org.jboss.naming:org.jnp.interfaces"/> </context> </source> <!-- local target destination on EAP6 --> <target> <connection-factory name="ConnectionFactory"/> <destination name="queue/ReceiverQueue"/> </target> <quality-of-service>DUPLICATES_OK</quality-of-service> <failure-retry-interval>5000</failure-retry-interval> <max-retries>50</max-retries> <max-batch-size>1</max-batch-size> <max-batch-time>-1</max-batch-time> <add-messageID-in-header>true</add-messageID-in-header> </jms-bridge> </subsystem> Actual results: 15:40:57,706 WARN [org.hornetq.jms.server] (pool-4-thread-1) HQ122010: Failed to connect JMS Bridge: java.lang.RuntimeException: Failed to download and/or install client side AOP stack at org.jboss.jms.client.JBossConnectionFactory.createConnectionInternal(JBossConnectionFactory.java:199) [jboss-messaging-client.jar:] at org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:87) [jboss-messaging-client.jar:] at org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:82) [jboss-messaging-client.jar:] at org.hornetq.jms.bridge.impl.JMSBridgeImpl.createConnection(JMSBridgeImpl.java:1125) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.setupJMSObjects(JMSBridgeImpl.java:1267) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.setupJMSObjectsWithRetry(JMSBridgeImpl.java:1474) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.access$2200(JMSBridgeImpl.java:79) at org.hornetq.jms.bridge.impl.JMSBridgeImpl$FailureHandler.run(JMSBridgeImpl.java:2082) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_65] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_65] at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_65] Caused by: java.lang.RuntimeException: java.lang.RuntimeException: org.jboss.aop.advice.org.jboss.jms.client.container.StateCreationAspect_z_handleCreateConnectionDelegate_78446179: frozen class (cannot edit) at org.jboss.aop.AspectXmlLoader.deployXML(AspectXmlLoader.java:995) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectXmlLoader.deployXML(AspectXmlLoader.java:981) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.jms.client.container.JmsClientAspectXMLLoader.deployXML(JmsClientAspectXMLLoader.java:93) [jboss-messaging-client.jar:] at org.jboss.jms.client.ClientAOPStackLoader.load(ClientAOPStackLoader.java:77) [jboss-messaging-client.jar:] at org.jboss.jms.client.JBossConnectionFactory.createConnectionInternal(JBossConnectionFactory.java:192) [jboss-messaging-client.jar:] ... 10 more Caused by: java.lang.RuntimeException: org.jboss.aop.advice.org.jboss.jms.client.container.StateCreationAspect_z_handleCreateConnectionDelegate_78446179: frozen class (cannot edit) at javassist.ClassPool.checkNotFrozen(ClassPool.java:568) [javassist.jar:3.12.0.GA_JBPAPP-9257] at javassist.ClassPool.makeClass(ClassPool.java:762) [javassist.jar:3.12.0.GA_JBPAPP-9257] at javassist.ClassPool.makeClass(ClassPool.java:739) [javassist.jar:3.12.0.GA_JBPAPP-9257] at org.jboss.aop.instrument.TransformerCommon.makeClass(TransformerCommon.java:239) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.advice.PerVmAdvice.generateInterceptor(PerVmAdvice.java:145) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.advice.PerVmAdvice.generateOptimized(PerVmAdvice.java:56) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.advice.AdviceFactory.create(AdviceFactory.java:106) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.Advisor.createInterceptorChain(Advisor.java:1328) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.Advisor.pointcutResolved(Advisor.java:1942) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.MethodMatchInfo.applyBinding(MethodMatchInfo.java:152) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.MethodMatchInfo.simplePopulateBindings(MethodMatchInfo.java:113) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.MethodMatchInfo.populateBindings(MethodMatchInfo.java:96) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.Advisor.finalizeMethodChain(Advisor.java:1553) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.ClassAdvisor.finalizeChains(ClassAdvisor.java:741) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.ClassAdvisor.doRebuildInterceptorsForAddedBinding(ClassAdvisor.java:1163) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.ClassAdvisor$RebuildInterceptorsAction$2.rebuildInterceptorsForAddedBinding(ClassAdvisor.java:2367) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.ClassAdvisor.rebuildInterceptorsForAddedBinding(ClassAdvisor.java:1141) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.Advisor.newBindingAdded(Advisor.java:1134) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectManager.updateAdvisorsForAddedBinding(AspectManager.java:1530) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectManager.addBinding(AspectManager.java:1491) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectXmlLoader.deployBinding(AspectXmlLoader.java:292) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectXmlLoader.deployTopElements(AspectXmlLoader.java:1145) [jboss-aop-client.jar:2.1.6.GA_CP06] at org.jboss.aop.AspectXmlLoader.deployXML(AspectXmlLoader.java:990) [jboss-aop-client.jar:2.1.6.GA_CP06] ... 14 more Expected results: The bridge connects to EAP5 properly. Additional info: The issue seems to be caused by JBoss AOP. It tries to instrument some classes in jboss-messaging-client jar and creates class names like org.jboss.aop.advice.org.jboss.messaging... which seems to cause issues with signing info verification (classes in package org.jboss.aop are found in 2 jars which seem to be signed with different key). I marked this as a low priority because there's a workaround - unsign the client jars in the custom module. But considering this worked as expected in the previous version in JBoss Modules, I'd like to discuss what's the desired behavior in this case (and if we expect users to unsign the jars, we need to update the EAP documentation).
One more note: I tried to copy old JBoss Modules 1.3.3 (from EAP 6.3.0.GA) to EAP 6.4.0.DR4 and the issue disappeared (module was loaded even with signed jars). Hence why I believe this is caused by some change between JBoss Modules 1.3.3 and 1.3.4.
My tentative diagnosis is that this is a regression and warrants an upstream (https://issues.jboss.org/browse/MODULES) JIRA issue report.
Martin Švehla <msvehla> updated the status of jira MODULES-202 to Closed
*** This bug has been marked as a duplicate of bug 1155823 ***