Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 315377

Summary: Using a version of AspectJ other than the one dm Server comes bundled with generates ClassNotFoundException upon deployment
Product: [RT] Virgo Reporter: astefan
Component: unknownAssignee: Project Inbox <virgo-inbox>
Status: NEW --- QA Contact:
Severity: enhancement    
Priority: P3 CC: eclipse, glyn.normington
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Whiteboard:
Attachments:
Description Flags
The test sample project
none
repository/usr content none

Description astefan CLA 2010-06-02 07:12:28 EDT
Build Identifier: 2.0.1.RELEASE

The error that is thrown is the following:
Caused by: com.springsource.kernel.osgi.framework.ExtendedClassNotFoundException: org.aspectj.lang.NoAspectBoundException in KernelBundleCla
ssLoader: [bundle=org.springframework.aspects_3.0.0.RELEASE]
        at com.springsource.kernel.userregion.internal.equinox.KernelBundleClassLoader.loadClass(KernelBundleClassLoader.java:149)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
        ... 38 common frames omitted
Caused by: java.lang.ClassNotFoundException: org.aspectj.lang.NoAspectBoundException

Attached it's an Eclipse project that represents a bundle deployable in dm Server 2.0.1. I have, also, attached a print screen containing the list of bundles under /repository/usr.

The jar itself can be generated by running “mvn package” in the root of the project.
I've performed my tests in a clean instance of dm Server 2.0.1 containing under /repository/usr the bundles from the attached print-screen. For these tests I've considered two variables:
- the AspectJ version under /repository/ext
- the Spring version under /repository/ext

The replacement of the old version (of, either Spring or Aspect) has been done by completely removing the old version bundles and copying the new version correspondent bundles.

Here are my tests' results:

1. For a standard instance of dm Server (1.6.6.RELEASE version of AspectJ and 3.0.0.RELEASE of Spring) everything is ok (no ClassNotFoundException is thrown)

2. For version 1.6.8 of AspectJ and 3.0.0 of Spring, the above exception is thrown

3. For version 1.6.8 of AspectJ and 3.0.2 of Spring, the above exception is thrown

4. For version 1.6.6 of AspectJ and 3.0.2 of Spring, the above exception is NOT thrown 

5. For version 1.6.8 of AspectJ under /repository/usr, 1.6.6 under /repository/ext and 3.0.0 of Spring, the above exception is thrown

Reproducible: Always

Steps to Reproduce:
1. run 'mvn package' at the root of the attached project
2. make the appropriate changes to dm Server repository/ext and /usr related to the bundles being used
3. deploy the bundle
Comment 1 astefan CLA 2010-06-02 07:13:44 EDT
Created attachment 170776 [details]
The test sample project
Comment 2 astefan CLA 2010-06-02 07:14:32 EDT
Created attachment 170777 [details]
repository/usr content
Comment 3 Glyn Normington CLA 2010-09-13 05:45:07 EDT
This is unfortunately working as designed, so marking as enhancement.