Hi,
I was getting "No ClassLoaders found" exception during replication when
TreeCache is deployed as an MBean and -service.xml is included within my ear. This
problem doesn't occur if I keep -service.xml out side the ear and deploy directly into
<JBOSS_HOME>/server//deploy directory
I'm using JBoss 4.0.4.
Here is my jboss-app.xml
| <jboss-app>
| ...
| <module>
| <service>MyCachTree-service.xml</service>
| </module>
| ...
|
Here is my ear
| META-INF/
| META-INF/MANIFEST.MF
| mywar.war
| lib/
| lib/classes12.jar
| META-INF/jboss-app.xml
| MyCachTree-service.xml
| META-INF/application.xml
|
The offending class is inside mywar.war.
I tried setting up TreeCacheMarshaller. Now the cache is not getting replicated.
Here is the code registering the region. This class has reference to the cache and does
putting and getting to/from cache.
| MBeanServer server = MBeanServerLocator.locateJBoss();
| ObjectName objName = new ObjectName(getTreeCacheName());
| cache = (TreeCacheMBean) MBeanProxy.get(
| TreeCacheMBean.class,
| objName,
| server);
| cache.registerClassLoader("test", this.getClass().getClassLoader());
| cache.activateRegion("test");
|
MyCachTree-service.xml
| <attribute name="UseMarshalling">true</attribute>
| <attribute name="InactiveOnStartup">true</attribute>
|
What am I doing wrong?
Thanks for your help,
Jennifer
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3983129#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...