I think there might be a problem with using javassist to build proxies. jsr299 allows proxying default or package access classes.
A very definite although hard-to-find-the-documentation-for requirement of classloaders is that all the default access classes and subclasses of default access classes in a package have to be loaded from the same classloader (not just be in the same package). (this has nothing to do with osgi and split packages). javassist proxies require access to some javassist classes. Therefore any default access classes that need to be proxied need to be loaded in a classloader that can also load javassist classes. This certainly prevents isolating application classes from server libraries and may be difficult to arrange in some circumstances. I think there are a couple of solutions available that use asm to construct class proxies that only use normal jdk classes. Is there any good reason to use javassist rather than something else? thanks david jencks
