Hi,
Thanks. I had already solved it by serializing and de-serializing the code
myself (only storing byte arrays in the cache).
Regards,
Arjan
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4109827#4109827
Reply to the post :
Okay, I did some extra checks using some (remote) debugging on the JBoss AS.
I added some breakpoints to org.jboss.invocation.MarshalledValueInputStream. It
seems like Thread.currentThread().getContextClassLoader() does return a
different classloader than
Indeed, the Classloader seems to be changed in
org.jboss.mx.server.AbstractMBeanInvoker:
| 252:ClassLoader mbeanTCL = resourceEntry.getClassLoader();
| final ClassLoader ccl = TCLAction.UTIL.getContextClassLoader();
| boolean setCl = ccl != mbeanTCL mbeanTCL != null;
|
... No differerence.
So, let's summarize:
| [li]I have a TreeCache deployed as service
(deploy/treecache-service.xml)[/li]
| [li]I access the TreeCache over JMX/JNDI (makes no differerence)[/li]
| [li]Using the FileCacheLoader fails with ClassNotFoundExceptions[/li]
| [li]Since
This is a workaround -- a hack, but still a workaround:
Let's assume you're getting a ref to the TreeCacheMBean via setter dependency
injection. Write your setter like this:
|
| private TreeCacheMBean treeCache;
|
| public void setTreeCache(TreeCacheMBean cache) {
|
Oh,
The JBossCache version is:
| $ java -jar jboss-cache-jdk50.jar
| Version:1.4.1.SP3
| Codename: Cayenne
| CVS:$Id: Version.java,v 1.18.2.11 2007/03/06 20:12:53 msurtani
Exp $
| History:(see http://jira.jboss.com/jira/browse/JBCACHE for details)
|
I presume the ChartMetadata class is in your webapp lib dir? Have you tried
using a context class loader instead?
| Thread.currentThread().getContextClassLoader()
|
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4106351#4106351
Reply to the post :
Yes, ChartMetadata is part of the webapp.
I checked (I saw the context class loader was used in the
MarshalledValueInputStream) and they're both the same class loader.
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4106394#4106394
Reply to the post :