Hello,

I need to add a custom service (MBean). This MBean must be able to access 
(instanciate) the EJBs which are hosted on JBoss server itself.
My MBean service starts correctly, but when attempting to instanciate an EJB 
(the example "interest" bean) it fails with exception:

javax.naming.CommunicationException.  Root exception is [Default] 
java.lang.ClassNotFoundException: com.web_tomorrow.interest.InterestHome
[Default]       at javax.management.loading.MLet.findClass(MLet.java:800


Instanciating a bean from a "normal" Java client works perfectly.
Also, when I add the interest EJB to JBOSS_CLASSPATH in run.bat, the bean 
can be accessed from the service. However, in this case, the server must be 
restarted when I deploy new beans  and want them to be accessible from the 
service.(no "hot deploy").

My questions are:
1) Is it possible to access the hosted EJBs from a service (MBean)
without putting it explicitly on the classpath and losing "hot deploy"?
2) If yes, how should I do it?

Any help is greatly appreciated.
Thank you,

Victor.

The full exception message:

javax.naming.CommunicationException.  Root exception is [Default] 
java.lang.ClassNotFoundException: com.web_tomorrow.interest.InterestHome
[Default]       at javax.management.loading.MLet.findClass(MLet.java:800)
[Default]       at java.lang.ClassLoader.loadClass(Unknown Source)
[Default]       at java.lang.ClassLoader.loadClass(Unknown Source)
[Default]       at java.lang.ClassLoader.loadClassInternal(Unknown Source)
[Default]       at java.lang.Class.forName0(Native Method)
[Default]       at java.lang.Class.forName(Unknown Source)
[Default]       at 
sun.rmi.server.MarshalInputStream.resolveProxyClass(Unknown S
ource)
[Default]       at 
java.io.ObjectInputStream.inputProxyClassDescriptor(Unknown S
ource)
[Default]       at java.io.ObjectInputStream.readObject(Unknown Source)
[Default]       at java.io.ObjectInputStream.readObject(Unknown Source)
[Default]       at java.io.ObjectInputStream.inputObject(Unknown Source)
[Default]       at java.io.ObjectInputStream.readObject(Unknown Source)
[Default]       at java.io.ObjectInputStream.readObject(Unknown Source)
[Default]       at java.rmi.MarshalledObject.get(Unknown Source)
[Default]       at 
org.jnp.interfaces.NamingContext.lookup(NamingContext.java:29
9)
[Default]       at 
org.jnp.interfaces.NamingContext.lookup(NamingContext.java:27
9)
[Default]       at javax.naming.InitialContext.lookup(Unknown Source)
[Default]       at JintegraService.start(JintegraService.java:45)
[Default]       at java.lang.reflect.Method.invoke(Native Method)
[Default]       at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1628)
[Default]       at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1523)
[Default]       at 
org.jboss.util.ServiceControl.start(ServiceControl.java:97)
[Default]       at java.lang.reflect.Method.invoke(Native Method)
[Default]       at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1628)
[Default]       at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1523)
[Default]       at org.jboss.Main.<init>(Main.java:203)
[Default]       at org.jboss.Main$1.run(Main.java:107)
[Default]       at java.security.AccessController.doPrivileged(Native 
Method)
[Default]       at org.jboss.Main.main(Main.java:103)

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to