Check it out:
| System.out.println("Say hello: " + gale.sayHello() );
| server.registerMBean( gale, galeName );
| server.invoke(galeName, "sayHello", null, null);
|
produces this output:
| 15:10:05,037 INFO [STDOUT] Say hello: Hello World!
| 15:10:05,037 INFO [STDOUT] Exception registering GaleMBean:
| 15:10:05,037 INFO [STDOUT] javax.management.ReflectionException
| 15:10:05,037 INFO [STDOUT] at
org.jboss.mx.interceptor.ReflectedDispatcher.handleInvocationExceptions(ReflectedDispatcher.java:171)
| 15:10:05,037 INFO [STDOUT] at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:149)
| 15:10:05,037 INFO [STDOUT] at
org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
| 15:10:05,037 INFO [STDOUT] at
org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
| 15:10:05,037 INFO [STDOUT] at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
| 15:10:05,053 INFO [STDOUT] at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
| 15:10:05,053 INFO [STDOUT] at
com.sun.jini.example.hello.GaleServiceMonitor.serviceAdded(GaleServiceMonitor.java:115)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl.serviceNotifyDo(ServiceDiscoveryManager.java:2130)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl.serviceNotifyDo(ServiceDiscoveryManager.java:2117)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl.addServiceNotify(ServiceDiscoveryManager.java:2077)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl.access$2500(ServiceDiscoveryManager.java:821)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl$NewOldServiceTask.run(ServiceDiscoveryManager.java:1393)
| 15:10:05,053 INFO [STDOUT] at
net.jini.lookup.ServiceDiscoveryManager$LookupCacheImpl$NotifyEventTask.run(ServiceDiscoveryManager.java:1132)
| 15:10:05,053 INFO [STDOUT] at
com.sun.jini.thread.TaskManager$TaskThread.run(TaskManager.java:331)
| 15:10:05,053 INFO [STDOUT] Caused by: java.lang.IllegalAccessException:
Class org.jboss.mx.interceptor.ReflectedDispatcher can not access a member of
class com.sun.jini.example.hello.Proxy with modifiers "public"
| 15:10:05,053 INFO [STDOUT] at
sun.reflect.Reflection.ensureMemberAccess(Reflection.java:65)
| 15:10:05,053 INFO [STDOUT] at
java.lang.reflect.Method.invoke(Method.java:578)
| 15:10:05,053 INFO [STDOUT] at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
| 15:10:05,053 INFO [STDOUT] ... 12 more
|
gale is a proxy object for an MBean running on another JVM.
System.out.println("Say hello: " + gale.sayHello() ); runs on the other JVM and
then returns "Hello World!". I am at a loss to why I am getting the
ReflectionException.
Thanks for any insight, Will
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3936373#3936373
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3936373
-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user