Friday, August 22, 2014

JCA-11622 using the DbAdapter with OSB 11g

Problem:

If you are using the DbAdapter with OSB 11g (specifically 11.1.1.7), you may experience the following Java exception in the osb_server1.out log file:
jca-transport-application-error xmlns="http://www.bea.com/wli/sb/transports/jca" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><jca-transport-error-message>Invoke JCA outbound service failed with application error</jca-transport-error-message><jca-runtime-fault-detail><eis-error-code xsi:nil="true"/><eis-error-message xsi:nil="true"/><exception>com.bea.wli.sb.transports.jca.JCATransportException: oracle.tip.adapter.sa.api.JCABindingException: oracle.tip.adapter.sa.impl.fw.ext.org.collaxa.thirdparty.apache.wsif.WSIFException: servicebus:/WSDL/CreateOrderProvABCSImpl/WSDL/ShipmentOrder [ Order_ptt::insert(OmOrderCollection) ] - WSIF JCA Execute of operation 'insert' failed due to: Could not create/access the TopLink Session.This session is used to connect to the datastore.Caused by java.lang.NullPointerException.; nested exception is:BINDING.JCA-11622Could not create/access the TopLink Session.This session is used to connect to the datastore.Caused by java.lang.NullPointerException.You may need to configure the connection settings in the deployment descriptor (i.e. DbAdapter.rar#META-INF/weblogic-ra.xml) and restart the server. This exception is considered not retriable, likely due to a modelling mistake.at com.bea.wli.sb.transports.jca.binding.JCATransportOutboundOperationBindingServiceImpl.invokeOneWay(JCATransportOutboundOperationBindingServiceImpl.java:114)at com.bea.wli.sb.transports.jca.JCATransportEndpoint.sendOneWay(JCATransportEndpoint.java:191)

Solution:

Even though the references in the OSB project were correct, the references in the actual .JCA file were not. I’m not sure why the original developer had incorrect references in the actual .JCA file, but OSB 11.1.1.4 was more tolerant and did not seem to care. OSB 11.1.1.7 does care.

1. Ensure that the highlighted references below are valid and correct in your .JCA file:
<?xml version="1.0" encoding="UTF-8"?><con:jcaEntry xmlns:con="http://www.bea.com/wli/sb/resources/config">    WRONG: <con:jca><![CDATA[<adapter-config name="Order" adapter="Database Adapter" wsdlLocation="Order.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">
    RIGHT: <con:jca><![CDATA[<adapter-config name="Order" adapter="Database Adapter" wsdlLocation="ShipmentOrder.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">

  <connection-factory location="eis/DB/EBS" UIConnectionName="InstanceDetails" adapterRef=""/>  <endpoint-interaction portType="Order_ptt" operation="insert">    <interaction-spec className="oracle.tip.adapter.db.DBWriteInteractionSpec">      <property name="DescriptorName" value="Order.OmOrder"/>      <property name="DmlType" value="insert"/>      WRONG: <property name="MappingsMetaDataURL" value="Order-or-mappings.xml"/>
      RIGHT: <property name="MappingsMetaDataURL" value="ShipOrderToplink.xml"/>
      <property name="DetectOmissions" value="true"/>      <property name="GetActiveUnitOfWork" value="false"/>    </interaction-spec>  </endpoint-interaction> </adapter-config>]]></con:jca>    <con:jcaDependency>        WRONG: <con:wsdlRef wsdlLocation="ShipOrder.wsdl" ref="OrderConfirmProvABCSImpl/WSDL/ShipmentOrder"/>
        RIGHT: <con:wsdlRef wsdlLocation="ShipmentOrder.wsdl" ref="OrderConfirmProvABCSImpl/WSDL/ShipmentOrder"/>
        WRONG: <con:toplinkRef toplinkFile="ShipOrder-or-mappings.xml" ref="OrderConfirmProvABCSImpl/Toplink/ShipOrderToplink"/>
        RIGHT: <con:toplinkRef toplinkFile="ShipOrderToplink.xml" ref="OrderConfirmProvABCSImpl/Toplink/ShipOrderToplink"/>
    </con:jcaDependency></con:jcaEntry>


Applicable Versions:

  • Oracle Service Bus (OSB) 11g (11.1.1.7) 

 

3 comments:

Anonymous said...

hi, i cant understand how change my .jca follow the example. I understand that property "MappingsMetaDataURL" has a wrong value but i dont know whats the correct value for it.

I post my .jca below:

















Anonymous said...

Sorry:














Ahmed Aboulnaga said...

1. Send the code back to the developer and let the developer fix it.

-or-

2. Unzip the OSB JAR file and locate all the .xml files in it, and you will have to do some analysis to figure out what needs changing. After you correct your .jca file, re-jar the OSB project and you should be good to go.

Obviously, without a little understanding of the code, it's going to be difficult.