JSR181 Orchestration sample doesn't work (Current state not START_ELEMENT, 
END_ELEMENT or ENTITY_REFERENCE )
------------------------------------------------------------------------------------------------------------

                 Key: SM-960
                 URL: https://issues.apache.org/activemq/browse/SM-960
             Project: ServiceMix
          Issue Type: Bug
          Components: servicemix-jsr181
            Reporter: Sangwoo Han
            Priority: Minor


The jsr181 orchestration sample doesn't work.

In the sample of jsr181 orchestration's  CityTimeImpl.java class file
[...] 
  public GetCityTimeResponse getCityTime(GetCityTimeRequest GetCityTimeRequest) 
{ 
            
            GetInfoByCity GetInfoByCity = new GetInfoByCity(); 
            GetInfoByCity.setUSCity(GetCityTimeRequest.getCity()); 
            
            GetInfoByCityResponse r = usZip.getInfoByCity(GetInfoByCity); 
            Element e = (Element) 
r.getGetInfoByCityResult().getContent().get(0); 
            e = (Element) e.getElementsByTagName("Table").item(0); 
            e = (Element) e.getElementsByTagName("ZIP").item(0); 
            String ZipCode = e.getTextContent(); 
            
            //String lt = localTime.localTimeByZipCode(ZipCode); // at this 
part it errored  

            GetCityTimeResponse rep = new GetCityTimeResponse(); 
            rep.getString().add("23:23"); 
            //rep.setTime(lt);  // wsgen didn't generate "setTime" function 
            return rep; 
        } 
[...] 

and the error output is below:
--------
[...]
DEBUG - header                         - << "Content-Length: 426[\r][\n]" 
DEBUG - content                        - << "<?xml version="1.0" 
encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlso 
ap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema";><soap:Bo 
dy><LocalTimeByZipCodeResponse 
xmlns="http://ripedev.com/xsd/ZipCodeResults.xsd";><LocalTimeByZipCodeResult>5/30/2007
 8:51:44 PM</L 
ocalTimeByZipCodeResult></LocalTimeByZipCodeResponse></soap:Body></soap:Envelope>"
 
DEBUG - Client                         - Received message to 
urn:xfire:transport:jbi:11805763005154-996237611 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase pre-dispatch 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase dispatch 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase dispatch 
DEBUG - HandlerPipeline                - Invoking phase transport 
DEBUG - HandlerPipeline                - Invoking phase parse 
DEBUG - HandlerPipeline                - Invoking phase pre-dispatch 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.client.CorrelatorHandler in phase pre-dispatch 
DEBUG - Client                         - Correlating context with ID 
118057630051551778993400 
DEBUG - Client                         - Found correlated context with ID 
118057630051551778993400 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase service 
DEBUG - HandlerPipeline                - Invoking phase dispatch 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.handler.LocateBindingHandler in phase dispatch 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.soap.handler.SoapBodyHandler in phase dispatch 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase user 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase pre-dispatch 
DEBUG - HandlerPipeline                - Invoking phase transport 
DEBUG - HandlerPipeline                - Invoking phase parse 
DEBUG - HandlerPipeline                - Invoking phase pre-dispatch 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.client.CorrelatorHandler in phase pre-dispatch 
DEBUG - Client                         - Correlating context with ID 
118057630051551778993400 
DEBUG - Client                         - Found correlated context with ID 
118057630051551778993400 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase service 
DEBUG - HandlerPipeline                - Invoking phase dispatch 
DEBUG - HandlerPipeline                - Invoking phase policy 
DEBUG - HandlerPipeline                - Invoking phase user 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.client.ClientFaultConverter in phase user 
DEBUG - HandlerPipeline                - Invoking phase pre-invoke 
DEBUG - HandlerPipeline                - Invoking phase service 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.client.ClientReceiveHandler in phase service 
ERROR - DefaultFaultHandler            - Fault occurred! 
org.codehaus.xfire.XFireRuntimeException: Could not invoke service.. Nested 
exception is org.codehaus.xfire.fault.XFireFault: The 
current event is not START_ELEMENT 
 but 7 
org.codehaus.xfire.fault.XFireFault: The current event is not START_ELEMENT 
 but 7 
        at org.codehaus.xfire.fault.XFireFault.createFault(XFireFault.java:89) 
        at org.codehaus.xfire.client.Client.onReceive(Client.java:391) 
        at 
org.apache.servicemix.jsr181.xfire.JbiChannel.send(JbiChannel.java:147) 
        at 
org.codehaus.xfire.handler.OutMessageSender.invoke(OutMessageSender.java:26) 
        at 
org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131) 
        at org.codehaus.xfire.client.Invocation.invoke(Invocation.java:75) 
        at org.codehaus.xfire.client.Client.invoke(Client.java:335) 
        at 
org.apache.servicemix.jsr181.xfire.JbiProxy$JAXWSJBIClient.invoke(JbiProxy.java:232)
 
        at 
org.codehaus.xfire.client.XFireProxy.handleRequest(XFireProxy.java:77) 
        at org.codehaus.xfire.client.XFireProxy.invoke(XFireProxy.java:57) 
        at 
org.apache.servicemix.jsr181.xfire.JbiProxyFactoryBean$1.invoke(JbiProxyFactoryBean.java:73)
 
        at $Proxy28.localTimeByZipCode(Unknown Source) 
        at 
org.apache.servicemix.samples.citytime.CityTimeImpl.getCityTime(CityTimeImpl.java:35)
 
        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.codehaus.xfire.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:54)
 
        at 
org.codehaus.xfire.service.binding.ServiceInvocationHandler.sendMessage(ServiceInvocationHandler.java:322)
 
        at 
org.codehaus.xfire.service.binding.ServiceInvocationHandler$1.run(ServiceInvocationHandler.java:86)
 
        at 
org.codehaus.xfire.service.binding.ServiceInvocationHandler.execute(ServiceInvocationHandler.java:134)
 
        at 
org.codehaus.xfire.service.binding.ServiceInvocationHandler.invoke(ServiceInvocationHandler.java:109)
 
        at 
org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131) 
        at 
org.codehaus.xfire.transport.DefaultEndpoint.onReceive(DefaultEndpoint.java:64) 
        at 
org.codehaus.xfire.transport.AbstractChannel.receive(AbstractChannel.java:38) 
        at 
org.apache.servicemix.jsr181.Jsr181ExchangeProcessor.process(Jsr181ExchangeProcessor.java:113)
 
        at 
org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:538)
 
        at 
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:490)
 
        at 
org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:46)
 
        at 
org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:593)
 
        at 
org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:174)
 
        at 
org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:171) 
        at 
org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134) 
        at 
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
 
        at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907) 
        at java.lang.Thread.run(Thread.java:619) 
Caused by: java.lang.IllegalStateException: The current event is not 
START_ELEMENT 
 but 7 
        at 
com.sun.xml.bind.v2.runtime.unmarshaller.StAXStreamConnector.bridge(StAXStreamConnector.java:124)
 
        at 
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:337)
 
        at 
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:309)
 
        at org.codehaus.xfire.jaxb2.JaxbType.readObject(JaxbType.java:200) 
        at 
org.codehaus.xfire.jaxws.JAXWSOperationBinding.readMessage(JAXWSOperationBinding.java:129)
 
        at 
org.codehaus.xfire.soap.handler.SoapBodyHandler.invoke(SoapBodyHandler.java:42) 
        at 
org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131) 
        at org.codehaus.xfire.client.Client.onReceive(Client.java:387) 
        ... 34 more 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase send 
DEBUG - HandlerPipeline                - adding handler [EMAIL PROTECTED] to 
phase user 
DEBUG - HandlerPipeline                - Invoking phase post-invoke 
DEBUG - HandlerPipeline                - Invoking phase policy 
DEBUG - HandlerPipeline                - Invoking phase user 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.jaxws.handler.WebFaultHandler in phase user 
DEBUG - HandlerPipeline                - Invoking phase transport 
DEBUG - HandlerPipeline                - Invoking phase send 
DEBUG - HandlerPipeline                - Invoking handler 
org.codehaus.xfire.fault.FaultSender in phase send 
DEBUG - jetty                          - resume continuation [EMAIL PROTECTED] 

DEBUG - jetty                          - REQUEST /citytime/ on [EMAIL 
PROTECTED] 
DEBUG - jetty                          - servlet=jbiServlet 
DEBUG - jetty                          - chain=null 
DEBUG - jetty                          - servelet holder=jbiServlet 
DEBUG - jetty                          - RESPONSE /citytime/  400 
DEBUG - jetty                          - continuation [EMAIL PROTECTED] 




-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to