Return-Path: X-Original-To: apmail-karaf-user-archive@minotaur.apache.org Delivered-To: apmail-karaf-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8C51E70C3 for ; Wed, 20 Jul 2011 08:28:36 +0000 (UTC) Received: (qmail 22140 invoked by uid 500); 20 Jul 2011 08:28:35 -0000 Delivered-To: apmail-karaf-user-archive@karaf.apache.org Received: (qmail 21985 invoked by uid 500); 20 Jul 2011 08:28:20 -0000 Mailing-List: contact user-help@karaf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@karaf.apache.org Delivered-To: mailing list user@karaf.apache.org Received: (qmail 21975 invoked by uid 99); 20 Jul 2011 08:28:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 20 Jul 2011 08:28:15 +0000 X-ASF-Spam-Status: No, hits=2.0 required=5.0 tests=FREEMAIL_FROM,SPF_NEUTRAL,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: 216.139.236.26 is neither permitted nor denied by domain of philipp.hoenisch@gmail.com) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 20 Jul 2011 08:28:09 +0000 Received: from ben.nabble.com ([192.168.236.152]) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1QjS8D-0002gr-9Q for user@karaf.apache.org; Wed, 20 Jul 2011 01:27:49 -0700 Date: Wed, 20 Jul 2011 01:27:49 -0700 (PDT) From: bonomat To: user@karaf.apache.org Message-ID: <1311150469284-3184861.post@n3.nabble.com> Subject: NoClassDefFoundError CommandProcessor/ not found by pax-exam-probe MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hello I would like to extend the karaf console commands. But I have some problems writing integration tests: I have the same setup like the the CoreTest in the package org.apache.karaf.shell.itests, [1] but when I try to get the CommandProcessor via : CommandProcessor cp = getOsgiService(CommandProcessor.class); i get the following error: java.lang.NoClassDefFoundError: org/apache/felix/service/command/CommandProcessor. I have compared the loaded bundles of my karaf instance with an "clean" karaf and as far as I can see are all necessary bundles present. The whole stacktrace is at the end of this post. It must be some kind of ClassLoader Issue and I don't know if I should ask here or at Ops4J, so I made a double post also at the ops4j mailing-list. java.lang.NoClassDefFoundError: org/apache/felix/service/command/CommandProcessor at my.packe.MyTestClass.myTest(MyTestClass.java:34) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.ops4j.pax.exam.junit.extender.impl.internal.CallableTestMethodImpl.injectContextAndInvoke(CallableTestMethodImpl.java:143) at org.ops4j.pax.exam.junit.extender.impl.internal.CallableTestMethodImpl.call(CallableTestMethodImpl.java:105) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.ops4j.pax.exam.rbc.internal.RemoteBundleContextImpl.remoteCall(RemoteBundleContextImpl.java:80) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305) at sun.rmi.transport.Transport$1.run(Transport.java:159) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:155) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.ClassNotFoundException: org.apache.felix.service.command.CommandProcessor not found by pax-exam-probe [153] at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:787) at org.apache.felix.framework.ModuleImpl.access$400(ModuleImpl.java:71) at org.apache.felix.framework.ModuleImpl$ModuleClassLoader.loadClass(ModuleImpl.java:1768) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) ... 26 more thanks for your help kind regards philipp [1]https://svn.apache.org/repos/asf/karaf/trunk/itests/tests/src/test/java/org/apache/karaf/shell/itests/CoreTest.java -- View this message in context: http://karaf.922171.n3.nabble.com/NoClassDefFoundError-CommandProcessor-not-found-by-pax-exam-probe-tp3184861p3184861.html Sent from the Karaf - User mailing list archive at Nabble.com.