• Bug
  • Status: Closed
  • 2 Major
  • Resolution: As Designed
  • Integration Modules
  • amiller
  • Reporter: amiller
  • August 04, 2009
  • 0
  • Watchers: 1
  • July 27, 2012
  • August 04, 2009

Attachments

Description

This comes from this forum post: http://forums.terracotta.org/forums/posts/list/0/2370.page

where a normal use of DistributedCache (there with Glassfish, but reproducible outside any app server) with tim-distributed-cache on the classpath but without tim-concurrent-collections on the classpath yields something like:

Exception in thread “main” java.lang.NoClassDefFoundError: org/terracotta/collections/MapSizeListener at org.terracotta.cache.impl.MutableConfig.newCache(MutableConfig.java:244) at dcachetest.Util.(Util.java:12) at dcachetest.Main.main(Main.java:5) Caused by: java.lang.ClassNotFoundException: org.terracotta.collections.MapSizeListener at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at sun.misc.Launcher$AppClassLoader.findClass(Launcher.java) at java.lang.ClassLoader.loadClass(ClassLoader.java:319) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330) at java.lang.ClassLoader.loadClass(ClassLoader.java:254) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:402) ... 3 more

Originally I was seeing the same error with MutableConfig but using slightly different version of things. To fix the issue, the tim-concurrent-collections library also needs to be on the classpath.

I’m logging here so future searches will find this. Also wondering if we’re making the error more confusing due to our exported tim bundle classes.

Comments

Alex Miller 2009-08-04

Marking this issue as resolved but opened a doc sub-task to update the web site with this info.

Alex Miller 2009-08-04

Attaching my test project - might need some tweaking for you but it’s a start.