You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by peppinolusuraio <ua...@libero.it> on 2009/02/25 14:52:43 UTC

Yoko integration

Hi,

there is a plan to integrate Yoko (both as a service engine and as binding
component) into Service mix?
It would be great :-)
-- 
View this message in context: http://www.nabble.com/Yoko-integration-tp22203205p22203205.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: StaxSoure vs DOMSource

Posted by Gert Vanthienen <ge...@gmail.com>.
Mark,

If it works with a DOMSource and not with a StaxSource, that's
probably a bug in our StaxSource handling.  At least it is worth
investigating, so could you raise a JIRA issue for this?  If you could
provide us with a simple SA to test with or some kind of way to
reproduce the issue, that would be awesome!

Regards,

Gert Vanthienen
------------------------
Open Source SOA: http://fusesource.com
Blog: http://gertvanthienen.blogspot.com/



2009/2/25 Ford, Mark <ma...@ll.mit.edu>:
> I was getting intermittent failures on invoking ODE through an http endpoint. The stacktrace indicated problems in parsing the XML message but all of the messages were well formed and valid according to the interface. I verified this on the client side and with tcpmon. There's a sample stacktrace below. The error messages were always about malformed xml and reported problems about encountering the wrong closing tag or other unexpected characters as below.
>
> I didn't see any other traffic on this issue so I was wondering if it was some kind of config issue with ServiceMix 3.3 and ODE 1.2. The code in ODE for parsing this looks good. I was able to work around this issue by adding the soap:dom policy to my consumer endpoint and everything is working fine now.
>
> For example:
>
>      <http:endpoint ...>        <http:policies>                <soap:dom xmlns:soap="http://servicemix.apache.org/soap/1.0"/>          </http:policies>    </http:endpoint>
> Sample stacktrace:
>
> WARN  - ServiceMixMapper               - Unable to parse message:
> org.apache.ode.jbi.msgmap.MessageTranslationException: Message parsing exception
>    at org.apache.ode.jbi.msgmap.BaseXmlMapper.parse(BaseXmlMapper.java:55)
>    at org.apache.ode.jbi.msgmap.ServiceMixMapper.isRecognized(ServiceMixMapper.java:57)
>    at org.apache.ode.jbi.OdeContext.findMapper(OdeContext.java:238)
>    at org.apache.ode.jbi.OdeService.invokeOde(OdeService.java:235)
>    at org.apache.ode.jbi.OdeService.onJbiMessageExchange(OdeService.java:148)
>    at org.apache.ode.jbi.JbiMessageExchangeEventRouter.onJbiMessageExchange(JbiMessageExchangeEventRouter.java:67)
>    at org.apache.ode.jbi.Receiver$1.run(Receiver.java:179)
>    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>    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:619)
> Caused by: java.io.IOException: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '<' (code 60) excepted space, or '>' or "/>"
>  at [row,col {unknown-source}]: [1,4129]
>    at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:501)
>    at org.apache.ode.utils.DOMUtils.sourceToDOM(DOMUtils.java:661)
>    at org.apache.ode.jbi.msgmap.BaseXmlMapper.parse(BaseXmlMapper.java:51)
>    ... 12 more
>
> --
> Mark Ford
> MIT Lincoln Laboratory
> 244 Wood Street
> Lexington MA 02420
> (781) 981-1843
>
>
>

Re: Yoko integration

Posted by Edell Nolan <ed...@gmail.com>.
We should definitely be able to plugin the tools and the binding through the
CXF components.

What are you specifically trying to do ? If you can send a testcase then we
could try and get this implemented.

Edell.

On Wed, Feb 25, 2009 at 2:57 PM, MartinMurphy <mu...@gmail.com>wrote:

>
>
> jb-58 wrote:
> >
> > Hi,
> >
> > I haven't tested but I think that you can integrate Yoko using CXF-SE
> > component.
> >
> > Refer to http://cwiki.apache.org/YOKO/binding-runtime-configuration.html
> >
> > Regards
> > JB
> >
> >
>
> I think it would only make sense to integrate Yoko with the CXF-BC, since
> it
> deals with the transport level and this is where we could plug a CORBA
> endpoint
> in?
>
> That said I haven't tested this either.
>
> - M
> --
> View this message in context:
> http://www.nabble.com/Yoko-integration-tp22203205p22204454.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>

StaxSoure vs DOMSource

Posted by "Ford, Mark" <ma...@ll.mit.edu>.
I was getting intermittent failures on invoking ODE through an http endpoint. The stacktrace indicated problems in parsing the XML message but all of the messages were well formed and valid according to the interface. I verified this on the client side and with tcpmon. There's a sample stacktrace below. The error messages were always about malformed xml and reported problems about encountering the wrong closing tag or other unexpected characters as below.

I didn't see any other traffic on this issue so I was wondering if it was some kind of config issue with ServiceMix 3.3 and ODE 1.2. The code in ODE for parsing this looks good. I was able to work around this issue by adding the soap:dom policy to my consumer endpoint and everything is working fine now.

For example:

      <http:endpoint ...>        <http:policies>                <soap:dom xmlns:soap="http://servicemix.apache.org/soap/1.0"/>          </http:policies>    </http:endpoint>
Sample stacktrace:

WARN  - ServiceMixMapper               - Unable to parse message:
org.apache.ode.jbi.msgmap.MessageTranslationException: Message parsing exception
    at org.apache.ode.jbi.msgmap.BaseXmlMapper.parse(BaseXmlMapper.java:55)
    at org.apache.ode.jbi.msgmap.ServiceMixMapper.isRecognized(ServiceMixMapper.java:57)
    at org.apache.ode.jbi.OdeContext.findMapper(OdeContext.java:238)
    at org.apache.ode.jbi.OdeService.invokeOde(OdeService.java:235)
    at org.apache.ode.jbi.OdeService.onJbiMessageExchange(OdeService.java:148)
    at org.apache.ode.jbi.JbiMessageExchangeEventRouter.onJbiMessageExchange(JbiMessageExchangeEventRouter.java:67)
    at org.apache.ode.jbi.Receiver$1.run(Receiver.java:179)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    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:619)
Caused by: java.io.IOException: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '<' (code 60) excepted space, or '>' or "/>"
 at [row,col {unknown-source}]: [1,4129]
    at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:501)
    at org.apache.ode.utils.DOMUtils.sourceToDOM(DOMUtils.java:661)
    at org.apache.ode.jbi.msgmap.BaseXmlMapper.parse(BaseXmlMapper.java:51)
    ... 12 more

--
Mark Ford
MIT Lincoln Laboratory
244 Wood Street
Lexington MA 02420
(781) 981-1843



Re: Yoko integration

Posted by MartinMurphy <mu...@gmail.com>.

jb-58 wrote:
> 
> Hi,
> 
> I haven't tested but I think that you can integrate Yoko using CXF-SE
> component.
> 
> Refer to http://cwiki.apache.org/YOKO/binding-runtime-configuration.html
> 
> Regards
> JB
> 
> 

I think it would only make sense to integrate Yoko with the CXF-BC, since it
deals with the transport level and this is where we could plug a CORBA
endpoint
in?

That said I haven't tested this either.

- M
-- 
View this message in context: http://www.nabble.com/Yoko-integration-tp22203205p22204454.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: Yoko integration

Posted by jb...@nanthrax.net.
Hi,

I haven't tested but I think that you can integrate Yoko using CXF-SE component.

Refer to http://cwiki.apache.org/YOKO/binding-runtime-configuration.html

Regards
JB

On Wednesday 25 February 2009 - 05:52, peppinolusuraio wrote:
> 
> Hi,
> 
> there is a plan to integrate Yoko (both as a service engine and as binding
> component) into Service mix?
> It would be great :-)
> -- 
> View this message in context: http://www.nabble.com/Yoko-integration-tp22203205p22203205.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
> 

Re: Yoko integration

Posted by peppinolusuraio <ua...@libero.it>.
I've a legacy C++ application exposing a CORBA interface and I need to access
it from the ESB.

In general I think a clean integration with CORBA would be a great
feature....anyway in my case I would use:

1) a jbi4corba binding component in provider mode, but I 'm getting some
errors.
2) a CXF-BC-SU in provider mode with the corba binding

I think the second chance is more coherent with an architecture based on
YOKO/CXF/SERVICE MIX, as jbi4corba seems better integrated on OPEN ESB.
YOKO corba binding works great on CXF.

AFAIK YOKO is integrated with the CXF 2.1X releases, not on the 2.0X.

I tried with SMIX 3.3 (based on CXF 2.2) craeting a CXF-SU-BC in provider
mode, starting from the CXF corba example.

This is the idl:

module cxf {
    
	//change this to an interface once we support corba:object & wsa
references.
    struct Account {	    
		string name;
		long balance;
	};

    exception AccountNotFoundException {
	    string name;
	};

	exception AccountAlreadyExistsException {
	    string name;
	};

    interface Bank {
        Account
        getAccount(
            in string name
        ) raises (AccountNotFoundException);

		boolean
		createAccount(
		    in string name, out Account account
		) raises (AccountAlreadyExistsException);
    };
};


xmlns:corba="http://cxf.apache.org/bindings/corba"


this is the generated WSDL

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions
targetNamespace="http://cxf.apache.org/schemas/cxf/idl/HelloWorld"
xmlns:corba="http://cxf.apache.org/bindings/corba"
xmlns:ns1="http://cxf.apache.org/schemas/cxf/idl/HelloWorld/corba/typemap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:tns="http://cxf.apache.org/schemas/cxf/idl/HelloWorld"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
  <corba:typeMapping
targetNamespace="http://cxf.apache.org/schemas/cxf/idl/HelloWorld/corba/typemap/"
/>
  <wsdl:types>
    <xs:schema attributeFormDefault="unqualified"
elementFormDefault="unqualified"
targetNamespace="http://cxf.apache.org/schemas/cxf/idl/HelloWorld"
xmlns="http://cxf.apache.org/schemas/cxf/idl/HelloWorld"
xmlns:ns1="http://cxf.apache.org/schemas/cxf/idl/HelloWorld/corba/typemap/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://cxf.apache.org/schemas/cxf/idl/HelloWorld"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <xs:element name="greetMeResponse" type="xs:string">
      </xs:element>
      <xs:element name="greetMe" type="xs:string">
      </xs:element>
    </xs:schema>
  </wsdl:types>
  <wsdl:message name="greetMe">
    <wsdl:part name="inparameter" element="tns:greetMe">
    </wsdl:part>
  </wsdl:message>
  <wsdl:message name="greetMeResponse">
    <wsdl:part name="outparameter" element="tns:greetMeResponse">
    </wsdl:part>
  </wsdl:message>
  <wsdl:portType name="HelloWorld">
    <wsdl:operation name="greetMe">
      <wsdl:input name="greetMeRequest" message="tns:greetMe">
    </wsdl:input>
      <wsdl:output name="greetMeResponse" message="tns:greetMeResponse">
    </wsdl:output>
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:binding name="HelloWorldCORBABinding" type="tns:HelloWorld">
    <corba:binding repositoryID="IDL:HelloWorld:1.0" />
    <wsdl:operation name="greetMe">
      <corba:operation name="greetMe">
        <corba:param mode="in" idltype="corba:string" name="inparameter" />
        <corba:return idltype="corba:string" name="outparameter" />
      </corba:operation>
      <wsdl:input name="greetMeRequest">
      </wsdl:input>
      <wsdl:output name="greetMeResponse">
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:service name="HelloWorldCORBAService">
    <wsdl:port name="HelloWorldCORBAPort"
binding="tns:HelloWorldCORBABinding">
      <corba:address location="corbaname::localhost:1050#HelloWorld" />
    </wsdl:port>
  </wsdl:service>
</wsdl:definitions>

when a deploy my sample service assembly I get the following exception:


<stack-trace><![CDATA[javax.jbi.management.DeploymentException:
org.apache.cxf.endpoint.EndpointException
        at
org.apache.servicemix.cxfbc.CxfBcProvider.validate(CxfBcProvider.java:475)
        at
org.apache.servicemix.common.AbstractDeployer.validate(AbstractDeployer.java:58)
        at
org.apache.servicemix.common.xbean.BaseXBeanDeployer.validate(BaseXBeanDeployer.java:55)
        at
org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:96)
        at
org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:88)
        at
org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:69)
        at
org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:508)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:353)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:256)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateExternalArchive(AutoDeploymentService.java:204)
        at
org.apache.servicemix.jbi.container.JBIContainer.updateExternalArchive(JBIContainer.java:494)
        at
org.apache.servicemix.jbi.container.JBIContainer.updateExternalArchive(JBIContainer.java:504)
        at
org.apache.servicemix.jbi.framework.AdminCommandsService.deployServiceAssembly(AdminCommandsService.java:209)
        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.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:216)
        at
org.apache.servicemix.jbi.management.BaseStandardMBean.invoke(BaseStandardMBean.java:323)
        at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
        at
com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
        at
javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1426)
        at
javax.management.remote.rmi.RMIConnectionImpl.access$200(RMIConnectionImpl.java:72)
        at
javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1264)
        at java.security.AccessController.doPrivileged(Native Method)
        at
javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1366)
        at
javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:788)
        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:619)
Caused by: org.apache.cxf.endpoint.EndpointException
        at
org.apache.cxf.endpoint.EndpointImpl.createBinding(EndpointImpl.java:132)
        at org.apache.cxf.endpoint.EndpointImpl.<init>(EndpointImpl.java:81)
        at
org.apache.servicemix.cxfbc.CxfBcProvider.validate(CxfBcProvider.java:456)
        ... 40 more
Caused by: org.apache.cxf.BusException: No binding factory for namespace
http://cxf.apache.org/bindings/corba registered.
        at
org.apache.cxf.binding.BindingFactoryManagerImpl.getBindingFactory(BindingFactoryManagerImpl.java:91)
        at
org.apache.cxf.endpoint.EndpointImpl.createBinding(EndpointImpl.java:129)
        ... 42 more
]]></stack-trace>
</exception-info>
</task-result-details>
</component-task-result-details>
</component-task-result>
</jbi-task-result>
</jbi-task>

        at
org.apache.servicemix.jbi.framework.ManagementSupport.failure(ManagementSupport.java:125)
        at
org.apache.servicemix.jbi.framework.ManagementSupport.failure(ManagementSupport.java:111)
        at
org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:543)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:353)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:256)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateExternalArchive(AutoDeploymentService.java:204)
        at
org.apache.servicemix.jbi.container.JBIContainer.updateExternalArchive(JBIContainer.java:494)
        at
org.apache.servicemix.jbi.container.JBIContainer.updateExternalArchive(JBIContainer.java:504)
        at
org.apache.servicemix.jbi.framework.AdminCommandsService.deployServiceAssembly(AdminCommandsService.java:209)
        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.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:216)
        at
org.apache.servicemix.jbi.management.BaseStandardMBean.invoke(BaseStandardMBean.java:323)
        at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
        at
com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
        at
javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1426)
        at
javax.management.remote.rmi.RMIConnectionImpl.access$200(RMIConnectionImpl.java:72)
        at
javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1264)
        at java.security.AccessController.doPrivileged(Native Method)
        at
javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1366)
        at
javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:788)
        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:619)


Seems the binding corba does not work.
Am I missing something or is it a missing feature?


-- 
View this message in context: http://www.nabble.com/Yoko-integration-tp22203205p22224625.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.