[
https://issues.jboss.org/browse/AS7-2138?page=com.atlassian.jira.plugin.s...
]
Darius Schier commented on AS7-2138:
------------------------------------
We've tried it with Thunder (7.1.0) but get exactly the same error message if we try
to contact an external JMX-Server (activemq). In SE environment, it works as expected.
We also tried the workaround (overriding rmiURLContextFactory returning the object
directly and setting it in the properties as suggested), unfortuanately with the same
behaviour.
Would you mind to reopen this issue, please?
{noformat}
javax.naming.NameNotFoundException: rmi://tmq.int.saarstahl.de:1099/jmxrmi -- service
jboss.naming.context.java.rmi:."tmq.int.saarstahl.de:1099".jmxrmi
at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:97)
at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:177)
at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:113)
at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:213)
at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_30]
at javax.management.remote.rmi.RMIConnector.findRMIServerJNDI(RMIConnector.java:1886)
[rt.jar:1.6.0_30]
at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1856)
[rt.jar:1.6.0_30]
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:255)
[rt.jar:1.6.0_30]
... 60 more
{noformat}
javax.naming.NameNotFoundException: rmi://127.0.0.1:1090/jmxrmi
thrown when creating MBeanServerConnection
----------------------------------------------------------------------------------------------------------
Key: AS7-2138
URL:
https://issues.jboss.org/browse/AS7-2138
Project: Application Server 7
Issue Type: Bug
Components: JMX
Affects Versions: 7.0.0.Final, 7.0.1.Final, 7.0.2.Final
Reporter: Stian Thorgersen
Assignee: Bartosz Baranowski
Fix For: 7.1.0.Final
Attachments: jmx-test.jar, JMXConnectionBean.java
When trying to create a MBeanServerConnection from within an EJB a
"javax.naming.NameNotFoundException" is thrown. When executed as a standalone
Java the same code works fine. To verify that it works as a standalone Java process run
"java -cp jmx-test.jar com.example.JMXConnectionBean" (with AS7 running on the
same machine).
Full stack trace:
{code}
Caused by: java.io.IOException: Failed to retrieve RMIServer stub:
javax.naming.NameNotFoundException: rmi://127.0.0.1:1090/jmxrmi -- service
jboss.naming.context.java.rmi:."127.0.0.1:1090".jmxrmi
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:340) [:1.6.0_26]
at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
[:1.6.0_26]
at com.example.JMXConnectionBean.init(JMXConnectionBean.java:28)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_26]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[:1.6.0_26]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[:1.6.0_26]
at java.lang.reflect.Method.invoke(Method.java:597) [:1.6.0_26]
at
org.jboss.as.ee.component.ManagedReferenceLifecycleMethodInterceptor.processInvocation(ManagedReferenceLifecycleMethodInterceptor.java:70)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at
org.jboss.as.ee.component.ManagedReferenceInterceptor.processInvocation(ManagedReferenceInterceptor.java:53)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at
org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:44)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at
org.jboss.as.ejb3.component.session.SessionInvocationContextInterceptor$CustomSessionInvocationContext.proceed(SessionInvocationContextInterceptor.java:126)
at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:211)
at org.jboss.as.ejb3.tx.CMTTxInterceptor.requiresNew(CMTTxInterceptor.java:313)
at
org.jboss.as.ejb3.tx.SingletonLifecycleCMTTxInterceptor.processInvocation(SingletonLifecycleCMTTxInterceptor.java:56)
at
org.jboss.as.ejb3.tx.SingletonLifecycleCMTTxInterceptor.processInvocation(SingletonLifecycleCMTTxInterceptor.java:42)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at
org.jboss.as.ejb3.component.session.SessionInvocationContextInterceptor.processInvocation(SessionInvocationContextInterceptor.java:71)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.as.ee.component.TCCLInterceptor.processInvocation(TCCLInterceptor.java:45)
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:287)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61)
[jboss-invocation-1.1.0.Final.jar:1.1.0.Final]
at
org.jboss.as.ee.component.BasicComponent.constructComponentInstance(BasicComponent.java:152)
... 9 more
Caused by: javax.naming.NameNotFoundException: rmi://127.0.0.1:1090/jmxrmi -- service
jboss.naming.context.java.rmi:."127.0.0.1:1090".jmxrmi
at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:87)
at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:173)
at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:47)
at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:209)
at javax.naming.InitialContext.lookup(InitialContext.java:392) [:1.6.0_26]
at javax.management.remote.rmi.RMIConnector.findRMIServerJNDI(RMIConnector.java:1888)
[:1.6.0_26]
at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1858)
[:1.6.0_26]
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:257) [:1.6.0_26]
... 37 more
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira