You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by Charles Souillard <Ch...@ext.bull.net> on 2006/09/08 09:20:41 UTC

sm-jsr181

Hi all,

I am trying to use sm-jsr181 component as I want to activate a service 
on the bus as a pojo.
What I want to do is to expose only one operation which performs a throw...

public String invokeFault(String input) throws 
bsoap.bpel.InvokeUtil.MyFaultMessage {
        throw new bsoap.bpel.InvokeUtil.MyFaultMessage("my Fault");
    }

As I have not been able to do that I have decided to start with an 
easyer method :

package bsoap.bpel.invokeUtil;
public class InvokeUtilImpl {
    public InvokeUtilImpl() {}
    public String invokeFault(String input) {
        return "in invokeFault operation";
    }
}

I have made a jar containig the compiled class of the one above and I 
have put it on the su.
My su also contains the .class and the .java file.
In addition a wsdl file describing the service is in the su and the 
xbean.xml looks like :
<beans xmlns:jsr181="http://servicemix.apache.org/jsr181/1.0" 
xmlns:tns="urn:invokeUtil:bpel:bsoap">
  <jsr181:endpoint
    service="tns:InvokeUtilServiceBP"
    pojoClass="bsoap.bpel.invokeUtil.InvokeUtilImpl"
    endpoint="invokeUtilPort"
    annotations="none"/>
  <classpath>
    <location>invokeUtil.jar</location>
  </classpath>
</beans>

When I deploy the sa into SM, I get the following exception :

<component-task-result 
xmlns="http://java.sun.com/xml/ns/jbi/management-message">
        <component-name>servicemix-jsr181</component-name>
        <component-task-result-details>
                <task-result-details>
                        <task-id>deploy</task-id>
                        <task-result>FAILED</task-result>
                        <message-type>ERROR</message-type>
                        <task-status-msg>
<msg-loc-info>
<loc-token/>
<loc-message>Could not register endpoint</loc-message>
</msg-loc-info>
</task-status-msg>
                        <exception-info>
                                <nesting-level>1</nesting-level>
                                <msg-loc-info>
                                        <loc-token/>
                                        
<loc-message>bsoap.bpel.invokeUtil.InvokeUtilImpl in classloader 
bsoap.bpel.invokeUtil.InvokeUtilImpl</loc-message>                                        
<stack-trace><![CDATA[java.lang.ClassNotFoundException: 
bsoap.bpel.invokeUtil.InvokeUtilImpl in classloader 
bsoap.bpel.invokeUtil.InvokeUtilImpl
        at 
org.apache.xbean.server.classloader.MultiParentClassLoader.loadClass(MultiParentClassLoader.java:206)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:242)
        at 
org.apache.servicemix.jsr181.Jsr181Endpoint.registerService(Jsr181Endpoint.java:176)
        at 
org.apache.servicemix.jsr181.Jsr181XBeanDeployer.validate(Jsr181XBeanDeployer.java:42)
        at 
org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:101)
        at 
org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:87)
        at 
org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:68)
        at 
org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:527)
        at 
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:295)
        at 
org.apache.servicemix.jbi.framework.AutoDeploymentService$2.run(AutoDeploymentService.java:592)
        at 
org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
        at 
EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Thread.java:595)
]]></stack-trace>
                                </msg-loc-info>
                        </exception-info>
                </task-result-details>
        </component-task-result-details>
</component-task-result>


Can you tell me what I am doing wrong ?

Thanks a lot
Regards
Charles