Author: cziegeler
Date: Sat Jul 26 11:09:23 2008
New Revision: 680024

URL: http://svn.apache.org/viewvc?rev=680024&view=rev
Log:
FELIX-644 : Throw exception with better message.

Modified:
    
felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/tags/cl/ClassLoaderJavaClassDescription.java

Modified: 
felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/tags/cl/ClassLoaderJavaClassDescription.java
URL: 
http://svn.apache.org/viewvc/felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/tags/cl/ClassLoaderJavaClassDescription.java?rev=680024&r1=680023&r2=680024&view=diff
==============================================================================
--- 
felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/tags/cl/ClassLoaderJavaClassDescription.java
 (original)
+++ 
felix/trunk/scrplugin/src/main/java/org/apache/felix/scrplugin/tags/cl/ClassLoaderJavaClassDescription.java
 Sat Jul 26 11:09:23 2008
@@ -130,6 +130,12 @@
         Method m = null;
         try {
             m = this.clazz.getDeclaredMethod(name, classParameters);
+        } catch (NoClassDefFoundError ncdfe) {
+            // if this occurs it usually means that a problem with the maven
+            // scopes exists.
+            throw new MojoExecutionException("Class loading error. This error 
usually occurs if you have a " +
+                    "service inheriting from a class coming from another 
bundle and that class using a " +
+                    "third library and all dependencies are specified with 
scope 'provided'.", ncdfe);
         } catch (NoSuchMethodException e) {
             // ignore this
         }


Reply via email to