PDA

View Full Version : Errore in processo BPEL


Njk00
17-06-2011, 13:47
Salve,
ho il seguente processo bpel
<?xml version="1.0" encoding="UTF-8"?>
<process name="ProviderABCSCAVS"
targetNamespace="http://xmlns.oracle.com/ProviderABCSCAVS"
xmlns="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
xmlns:xp20="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20"
xmlns:tns="urn:Receiver"
xmlns:ns4="http://xmlns.oracle.com/EnterpriseServices/Core/Billing/V1"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns5="urn:oasis:names:tc:xacml:2.0:context:schema:cd:04"
xmlns:ora="http://schemas.oracle.com/xpath/extension"
xmlns:ns9="http://xmlns.oracle.com/ProviderABCSCAVSRef"
xmlns:ns1="http://xmlns.oracle.com/EnterpriseServices/Core/Billing/V1"
xmlns:ns2="http://xmlns.oracle.com/EnterpriseObjects/Core/EBO/FulfillmentOrder/V1"
xmlns:orcl="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc"
xmlns:ns10="urn:Receiver"
xmlns:bpws="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
xmlns:wsa="http://schemas.xmlsoap.org/ws/2003/03/addressing"
xmlns:ns7="http://xmlns.oracle.com/EnterpriseServices/Core/CustomerParty/V2"
xmlns:ids="http://xmlns.oracle.com/bpel/services/IdentityService/xpath"
xmlns:ldap="http://schemas.oracle.com/xpath/extension/ldap"
xmlns:client="http://xmlns.oracle.com/ProviderABCSCAVS"
xmlns:ns6="http://xmlns.oracle.com/ias/pcbpel/NotificationService"
xmlns:xref="http://www.oracle.com/XSL/Transform/java/oracle.tip.xref.xpath.XRefXPathFunctions"
xmlns:ns11="urn:CAVS"
xmlns:hwf="http://xmlns.oracle.com/bpel/workflow/xpath"
xmlns:ehdr="http://www.oracle.com/XSL/Transform/java/oracle.tip.esb.server.headers.ESBHeaderFunctions"
xmlns:ns3="http://xmlns.oracle.com/EnterpriseObjects/Core/Common/V2"
xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
xmlns:sordabcs="http://xmlns.oracle.com/ProviderABCSCAVS"
xmlns:ns8="http://xmlns.oracle.com/BRM/schemas/BusinessOpcodes"
xmlns:urn="urn:Receiver">
<!--
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
PARTNERLINKS
List of services participating in this BPEL process
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-->
<!--
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
VARIABLES
List of messages and XML documents used within this BPEL process
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-->
<partnerLinks>
<partnerLink name="EBS_Sender" myRole="ReceiverPartenerLinkType_Role"
partnerLinkType="urn:ReceiverPartenerLinkType"/>
<partnerLink name="CAVS" partnerLinkType="ns11:CAVSType"
myRole="InvokeCAVS_Role"/>
</partnerLinks>
<variables>
<!-- Reference to the message passed as input during initiation -->
<variable name="CommunicationsBillingInputVar"
messageType="tns:ProcessFulfillmentOrderBillingEBM"/>
<variable name="SyncCustomerPartyListReqMsg"
messageType="tns:SyncCustomerPartyListEBM"/>
<variable name="EndpointReference" element="wsa:EndpointReference"/>
</variables>
<!--
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
ORCHESTRATION LOGIC
Set of activities coordinating the flow of messages across the
services integrated within this business process
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-->
<sequence name="main">
<!-- Receive input from requestor. (Note: This maps to operation defined in ProviderABCSCAVS.wsdl) -->
<pick name="Pick_1" createInstance="yes">
<onMessage portType="tns:ReceivePortType"
operation="CommunicationsBillingEBSV1"
variable="CommunicationsBillingInputVar" partnerLink="EBS_Sender">
<sequence name="Sequence_2">
<scope name="Scope_1">
<variables>
<variable name="ServiceName" type="xsd:string"/>
<variable name="TargetEndpointLocation" type="xsd:string"/>
</variables>
<sequence name="Sequence_3">
<assign name="GetServiceName">
<copy>
<from expression="'{http://xmlns.oracle.com/ProviderABCSCAVS}ProviderABCSCAVS'"/>
<to variable="ServiceName"/>
</copy>
</assign>
<bpelx:exec name="GetTargetEndPointLocation" language="java"
version="1.5">
<![CDATA[java.lang.String routeToCavsPropertyName = "Routing.CAVS.RouteToCAVS";
java.lang.String targetEndpointLocation = null;
java.lang.String targetID = null;
java.lang.String serviceName = (java.lang.String)getVariableData("ServiceName");
java.lang.String cavsEndpointPropertyName ="Routing.CAVS.EndpointURI" ;
java.lang.String targetEndpointLocationBpelVariableName = "TargetEndpointLocation";

try
{
java.lang.System.out.println("serviceName = " + serviceName);
java.lang.System.out.println("routeToCavsPropertyName = " + routeToCavsPropertyName);
boolean routeToCAVS = java.lang.Boolean.parseBoolean(oracle.apps.aia.core.config.Configuration.getServiceProperty(serviceName, routeToCavsPropertyName));
//boolean routeToCAVS = true;
if(routeToCAVS)
{
targetEndpointLocation = oracle.apps.aia.core.config.Configuration.getServiceProperty(serviceName,cavsEndpointPropertyName);

setVariableData(targetEndpointLocationBpelVariableName, targetEndpointLocation);
}
}
catch(oracle.apps.aia.core.config.PropertyNotFoundException e)
{
java.lang.System.out.println("In catch block");
}]]>
</bpelx:exec>
<assign name="AssignPartnerlinkEndpointReference">
<copy>
<from>
<wsa:EndpointReference xmlns:wsa="http://schemas.xmlsoap.org/ws/2003/03/addressing">
<wsa:Address/>
<wsa:ServiceName xmlns:cavs="http://xmlns.oracle.com/ProviderABCSCAVS"/>
</wsa:EndpointReference>
</from>
<to variable="EndpointReference"/>
</copy>
<copy>
<from variable="TargetEndpointLocation"/>
<to variable="EndpointReference"
query="/wsa:EndpointReference/wsa:Address"/>
</copy>
<copy>
<from expression="'cavs:CAVSAnyService'"/>
<to variable="EndpointReference"/>
</copy>
<copy>
<from variable="EndpointReference"/>
<to partnerLink="CAVS"/>
</copy>
</assign>
</sequence>
</scope>
</sequence>
</onMessage>
</pick>
</sequence>
</process>

Dopo averlo deployato con successo attraverso la console di ORACLE EM 10g provo ad invocarlo tramite soapui; purtroppo il messaggio che ottengo è questo: Cannot find partnerLinkType 2.
PartnerLinkType "{urn:Receiver}ReceiverPartenerLinkType" is not found in WSDL at "file:/FS/oracle/product/soa/bpel/domains/default/tmp/.bpel_ProviderABCSCAVS_1.0_f6f47a5fe3fcc1b621c2de1b581b08df.tmp/_ProviderABCSCAVS.wsdl".
Please make sure the partnerLinkType is defined in the WSDL

Ma nel wsdl compare la definizione del partner link
<definitions targetNamespace="urn:Receiver"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:tns="urn:Receiver"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:sordebo="http://xmlns.oracle.com/EnterpriseObjects/Core/EBO/FulfillmentOrder/V1"
xmlns:custebo="http://xmlns.oracle.com/EnterpriseObjects/Core/EBO/CustomerParty/V2"
xmlns:plnk="http://schemas.xmlsoap.org/ws/2003/05/partner-link/"
>

<types>
<xsd:schema>
<xsd:import namespace="http://xmlns.oracle.com/EnterpriseObjects/Core/EBO/FulfillmentOrder/V1"
schemaLocation="Blablabla/V1/FulfillmentOrderEBM.xsd"/>
<xsd:import namespace="http://xmlns.oracle.com/EnterpriseObjects/Core/EBO/CustomerParty/V2"
schemaLocation="Blablabla/V2/CustomerPartyEBM.xsd" />
</xsd:schema>
</types>

<message name="ProcessFulfillmentOrderBillingEBM">
<part name="payload" element="sordebo:ProcessFulfillmentOrderBillingEBM"/>
</message>

<message name="SyncCustomerPartyListEBM">
<part name="SyncCustomerPartyListEBM" element="custebo:SyncCustomerPartyListEBM"/>
</message>

<portType name="ReceivePortType">
<operation name="CommunicationsBillingEBSV1">
<input message="tns:ProcessFulfillmentOrderBillingEBM"/>
</operation>
<operation name="CommunicationsCustomerPartyEBSV2">
<input message="tns:SyncCustomerPartyListEBM"/>
</operation>
</portType>

<binding name="ReceiveSoapBinding" type="tns:ReceivePortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="CommunicationsBillingEBSV1">
<soap:operation soapAction="http://example.com/CommunicationsBillingEBSV1"/>
<input>
<soap:body use="literal"/>
</input>
</operation>
<operation name="CommunicationsCustomerPartyEBSV2">
<soap:operation soapAction="http://example.com/CommunicationsCustomerPartyEBSV2"/>
<input>
<soap:body use="literal"/>
</input>
</operation>
</binding>

<service name="Receive">
<documentation>Reciever service</documentation>
<port name="ReceivePort" binding="tns:ReceiveSoapBinding">
<soap:address location="http://example.com/Receive"/>
</port>
</service>

<plnk:partnerLinkType name="ReceiverPartenerLinkType">
<plnk:role name="ReceiverPartenerLinkType_Role">
<plnk:portType name="tns:ReceivePort"/>
</plnk:role>
</plnk:partnerLinkType>

</definitions>

Qualcuno ha qualche idea?

Mixmar
19-06-2011, 16:53
Boh? Sembra un problema di namespace XML: prova a sostituire


<plnk:partnerLinkType name="ReceiverPartenerLinkType">


con


<plnk:partnerLinkType name="tns:ReceiverPartenerLinkType">


nel file WSDL.