[savara-commits] savara SVN: r680 - in branches/experimental/2.0.x/bundles: org.savara.bpel/src/test/java/org/savara/bpel/generator and 9 other directories.

do-not-reply at jboss.org do-not-reply at jboss.org
Thu Feb 17 11:44:19 EST 2011


Author: objectiser
Date: 2011-02-17 11:44:18 -0500 (Thu, 17 Feb 2011)
New Revision: 680

Modified:
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/main/java/org/savara/bpel/model/change/InteractionModelChangeRule.java
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/java/org/savara/bpel/generator/ProtocolToBPELGeneratorTest.java
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Broker.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Buyer.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at CreditAgency.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierQuoteEngine.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierTxnProcessor.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PolicyQuote at PolicyQuoteProcessService.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Buyer.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at CreditAgency.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Store.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Buyer.bpel
   branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Seller.bpel
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/ChoiceConverterRuleImpl.java
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/InteractionConverterRuleImpl.java
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ESBBroker.spr
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PolicyQuote.spr
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PurchaseGoods.spr
   branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ReqRespFault.spr
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/main/java/org/savara/protocol/contract/generator/impl/ContractIntrospector.java
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/ContractGeneratorTest.java
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/impl/ContractIntrospectorTest.java
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Broker.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Buyer.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at CreditAgency.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierQuoteEngine.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierTxnProcessor.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at CreditCheckService.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at PolicyQuoteProcessService.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Buyer.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at CreditAgency.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store_CreditAgency.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Buyer.contract
   branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Seller.contract
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/main/java/org/savara/wsdl/generator/impl/WSDLGeneratorImpl.java
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Broker_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Buyer_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_CreditAgency_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierQuoteEngine_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierTxnProcessor_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_CreditCheckService_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_PolicyQuoteProcessService_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Buyer_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_CreditAgency_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Store_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Buyer_rpc_0.wsdl
   branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Seller_rpc_0.wsdl
Log:
Changed to use CDM behaviour name/interface as the basis for a port type, so if a service has more than one interface, this will be reflected through to generated WSDL and BPEL.

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/main/java/org/savara/bpel/model/change/InteractionModelChangeRule.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/main/java/org/savara/bpel/model/change/InteractionModelChangeRule.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/main/java/org/savara/bpel/model/change/InteractionModelChangeRule.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -170,9 +170,8 @@
 			//contract = ModelChangeUtils.getContract(context, roleType);
 
 			if (contract != null) {
-				/*
 				Annotation annotation=null;
-				if ((annotation=AnnotationDefinitions.getAnnotation(interaction.getProperties(),
+				if ((annotation=AnnotationDefinitions.getAnnotation(interaction.getAnnotations(),
 									AnnotationDefinitions.INTERFACE)) != null) {
 					String intfName=(String)annotation.getProperties().get(AnnotationDefinitions.NAME_PROPERTY);
 					intf = contract.getInterface(intfName);
@@ -182,7 +181,7 @@
 						javax.xml.namespace.QName qname=javax.xml.namespace.QName.valueOf(intfName);
 						intf = contract.getInterface(qname.getLocalPart());
 					}
-				} else*/ if (contract.getInterfaces().size() > 0) {
+				} else if (contract.getInterfaces().size() > 0) {
 					intf = contract.getInterfaces().iterator().next();
 				}
 			}

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/java/org/savara/bpel/generator/ProtocolToBPELGeneratorTest.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/java/org/savara/bpel/generator/ProtocolToBPELGeneratorTest.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/java/org/savara/bpel/generator/ProtocolToBPELGeneratorTest.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -50,7 +50,7 @@
         suite.addTest(new ProtocolToBPELTester("ReqRespFault", "Seller"));
         
         suite.addTest(new ProtocolToBPELTester("PolicyQuote", "PolicyQuoteProcessService"));
-        
+
         return suite;
     }
     

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Broker.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Broker.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Broker.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -24,37 +24,37 @@
         <variable messageType="brk:cancelRequest" name="cancelRequestVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_Enquiry" operation="makeEnquiry" partnerLink="BuyerToBroker" portType="brk:Broker" variable="makeEnquiryRequestVar"/>
+        <receive createInstance="yes" name="Receive_Enquiry" operation="makeEnquiry" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="makeEnquiryRequestVar"/>
         <while>
             <sequence>
                 <scope>
                     <sequence>
-                        <invoke inputVariable="getQuoteRequestVar" name="Send_RequestForQuote" operation="getQuote" outputVariable="getQuoteResponseVar" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierQuoteEngine"/>
+                        <invoke inputVariable="getQuoteRequestVar" name="Send_RequestForQuote" operation="getQuote" outputVariable="getQuoteResponseVar" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierBehavior"/>
                     </sequence>
                 </scope>
             </sequence>
         </while>
-        <reply name="Send_QuoteList" operation="makeEnquiry" partnerLink="BuyerToBroker" portType="brk:Broker" variable="makeEnquiryResponseVar"/>
+        <reply name="Send_QuoteList" operation="makeEnquiry" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="makeEnquiryResponseVar"/>
         <pick>
-            <onMessage operation="buy" partnerLink="BuyerToBroker" portType="brk:Broker" variable="buyRequestVar">
+            <onMessage operation="buy" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="buyRequestVar">
                 <sequence>
                     <scope>
                         <faultHandlers>
                             <catch faultMessageType="cay:invalidCreditFault" faultName="cay:invalidCredit" faultVariable="invalidCreditFaultVar">
 <sequence>
-    <reply faultName="brk:rejected" name="Send_OrderRejected" operation="buy" partnerLink="BuyerToBroker" portType="brk:Broker" variable="rejectedFaultVar"/>
+    <reply faultName="brk:rejected" name="Send_OrderRejected" operation="buy" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="rejectedFaultVar"/>
 </sequence>
                             </catch>
                         </faultHandlers>
                         <sequence>
-                            <invoke inputVariable="checkCreditRequestVar" name="Send_CreditInformation" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgency"/>
-                            <invoke inputVariable="confirmRequestVar" name="Send_OrderConfirmed" operation="confirm" outputVariable="confirmResponseVar" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierTxnProcessor"/>
-                            <reply name="Send_BookingReference" operation="buy" partnerLink="BuyerToBroker" portType="brk:Broker" variable="buyResponseVar"/>
+                            <invoke inputVariable="checkCreditRequestVar" name="Send_CreditInformation" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgencyBehavior"/>
+                            <invoke inputVariable="confirmRequestVar" name="Send_OrderConfirmed" operation="confirm" outputVariable="confirmResponseVar" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierBehavior"/>
+                            <reply name="Send_BookingReference" operation="buy" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="buyResponseVar"/>
                         </sequence>
                     </scope>
                 </sequence>
             </onMessage>
-            <onMessage operation="cancel" partnerLink="BuyerToBroker" portType="brk:Broker" variable="cancelRequestVar">
+            <onMessage operation="cancel" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior" variable="cancelRequestVar">
                 <sequence/>
             </onMessage>
         </pick>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Buyer.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Buyer.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at Buyer.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -12,7 +12,7 @@
         <variable messageType="brk:cancelRequest" name="cancelRequestVar"/>
     </variables>
     <sequence>
-        <invoke inputVariable="makeEnquiryRequestVar" name="Send_Enquiry" operation="makeEnquiry" outputVariable="makeEnquiryResponseVar" partnerLink="BuyerToBroker" portType="brk:Broker"/>
+        <invoke inputVariable="makeEnquiryRequestVar" name="Send_Enquiry" operation="makeEnquiry" outputVariable="makeEnquiryResponseVar" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior"/>
         <if>
             <sequence>
                 <scope>
@@ -22,13 +22,13 @@
                         </catch>
                     </faultHandlers>
                     <sequence>
-                        <invoke inputVariable="buyRequestVar" name="Send_Buy" operation="buy" outputVariable="buyResponseVar" partnerLink="BuyerToBroker" portType="brk:Broker"/>
+                        <invoke inputVariable="buyRequestVar" name="Send_Buy" operation="buy" outputVariable="buyResponseVar" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior"/>
                     </sequence>
                 </scope>
             </sequence>
             <else>
                 <sequence>
-                    <invoke inputVariable="cancelRequestVar" name="Send_Cancel" operation="cancel" partnerLink="BuyerToBroker" portType="brk:Broker"/>
+                    <invoke inputVariable="cancelRequestVar" name="Send_Cancel" operation="cancel" partnerLink="BuyerToBroker" portType="brk:BrokerBehavior"/>
                 </sequence>
             </else>
         </if>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at CreditAgency.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at CreditAgency.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at CreditAgency.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -10,14 +10,14 @@
         <variable messageType="cay:invalidCreditFault" name="invalidCreditFaultVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_CreditInformation" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgency" variable="checkCreditRequestVar"/>
+        <receive createInstance="yes" name="Receive_CreditInformation" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgencyBehavior" variable="checkCreditRequestVar"/>
         <if>
             <sequence>
-                <reply name="Send_CreditValid" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgency" variable="checkCreditResponseVar"/>
+                <reply name="Send_CreditValid" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgencyBehavior" variable="checkCreditResponseVar"/>
             </sequence>
             <else>
                 <sequence>
-                    <reply faultName="cay:invalidCredit" name="Send_CreditInvalid" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgency" variable="invalidCreditFaultVar"/>
+                    <reply faultName="cay:invalidCredit" name="Send_CreditInvalid" operation="checkCredit" partnerLink="BrokerToCreditAgency" portType="cay:CreditAgencyBehavior" variable="invalidCreditFaultVar"/>
                 </sequence>
             </else>
         </if>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierQuoteEngine.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierQuoteEngine.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierQuoteEngine.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -9,7 +9,7 @@
         <variable messageType="spr:getQuoteResponse" name="getQuoteResponseVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_RequestForQuote" operation="getQuote" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierQuoteEngine" variable="getQuoteRequestVar"/>
-        <reply name="Send_Quote" operation="getQuote" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierQuoteEngine" variable="getQuoteResponseVar"/>
+        <receive createInstance="yes" name="Receive_RequestForQuote" operation="getQuote" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierBehavior" variable="getQuoteRequestVar"/>
+        <reply name="Send_Quote" operation="getQuote" partnerLink="BrokerToSupplierQuoteEngine" portType="spr:SupplierBehavior" variable="getQuoteResponseVar"/>
     </sequence>
 </process>
\ No newline at end of file

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierTxnProcessor.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierTxnProcessor.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ESBBroker at SupplierTxnProcessor.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -9,7 +9,7 @@
         <variable messageType="spr:confirmResponse" name="confirmResponseVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_OrderConfirmed" operation="confirm" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierTxnProcessor" variable="confirmRequestVar"/>
-        <reply name="Send_BookingReference" operation="confirm" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierTxnProcessor" variable="confirmResponseVar"/>
+        <receive createInstance="yes" name="Receive_OrderConfirmed" operation="confirm" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierBehavior" variable="confirmRequestVar"/>
+        <reply name="Send_BookingReference" operation="confirm" partnerLink="BrokerToSupplierTxnProcessor" portType="spr:SupplierBehavior" variable="confirmResponseVar"/>
     </sequence>
 </process>
\ No newline at end of file

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PolicyQuote at PolicyQuoteProcessService.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PolicyQuote at PolicyQuoteProcessService.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PolicyQuote at PolicyQuoteProcessService.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -29,7 +29,7 @@
     <sequence>
         <receive createInstance="yes" name="Receive_PolicyQuote" operation="receivePolicyQuote" partnerLink="DriverToPolicyQuoteProcessService" portType="pps:PolicyQuoteProcessService" variable="receivePolicyQuoteRequestVar"/>
         <invoke inputVariable="checkDrivingRecordRequestVar" name="Send_DrivingRecordRequest" operation="checkDrivingRecord" partnerLink="PolicyQuoteProcessServiceToDrivingRecordService" portType="dmv:DrivingRecordService"/>
-        <receive name="Receive_DrivingRecordResponse" operation="receiveDrivingRecord" partnerLink="DrivingRecordServiceToPolicyQuoteProcessService" portType="pps:PolicyQuoteProcessService" variable="receiveDrivingRecordRequestVar"/>
+        <receive name="Receive_DrivingRecordResponse" operation="receiveDrivingRecord" partnerLink="DrivingRecordServiceToPolicyQuoteProcessService" portType="pps:DrivingRecordCallbackService" variable="receiveDrivingRecordRequestVar"/>
         <if>
             <sequence>
                 <invoke inputVariable="checkCreditRequestVar" name="Send_CreditCheckRequest" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="PolicyQuoteProcessServiceToCreditCheckService" portType="ca:CreditCheckService"/>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Buyer.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Buyer.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Buyer.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -16,7 +16,7 @@
                 </catch>
             </faultHandlers>
             <sequence>
-                <invoke inputVariable="buyRequestVar" name="Send_BuyRequest" operation="buy" outputVariable="buyResponseVar" partnerLink="BuyerToStore" portType="sto:Store"/>
+                <invoke inputVariable="buyRequestVar" name="Send_BuyRequest" operation="buy" outputVariable="buyResponseVar" partnerLink="BuyerToStore" portType="sto:StoreInterface"/>
             </sequence>
         </scope>
     </sequence>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at CreditAgency.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at CreditAgency.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at CreditAgency.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -10,14 +10,14 @@
         <variable messageType="pur:CreditCheckFailedFault" name="CreditCheckFailedFaultVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_CreditCheckRequest" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgency" variable="checkCreditRequestVar"/>
+        <receive createInstance="yes" name="Receive_CreditCheckRequest" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgencyInterface" variable="checkCreditRequestVar"/>
         <if>
             <sequence>
-                <reply name="Send_CreditCheckOk" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgency" variable="checkCreditResponseVar"/>
+                <reply name="Send_CreditCheckOk" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgencyInterface" variable="checkCreditResponseVar"/>
             </sequence>
             <else>
                 <sequence>
-                    <reply faultName="pur:CreditCheckFailed" name="Send_CreditCheckInvalid" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgency" variable="CreditCheckFailedFaultVar"/>
+                    <reply faultName="pur:CreditCheckFailed" name="Send_CreditCheckInvalid" operation="checkCredit" partnerLink="StoreToCreditAgency" portType="pur:CreditAgencyInterface" variable="CreditCheckFailedFaultVar"/>
                 </sequence>
             </else>
         </if>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Store.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Store.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/PurchaseGoods at Store.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -14,18 +14,18 @@
         <variable messageType="sto:BuyFailedFault" name="BuyFailedFaultVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_BuyRequest" operation="buy" partnerLink="BuyerToStore" portType="sto:Store" variable="buyRequestVar"/>
+        <receive createInstance="yes" name="Receive_BuyRequest" operation="buy" partnerLink="BuyerToStore" portType="sto:StoreInterface" variable="buyRequestVar"/>
         <scope>
             <faultHandlers>
                 <catch faultMessageType="pur:CreditCheckFailedFault" faultName="pur:CreditCheckFailed" faultVariable="CreditCheckFailedFaultVar">
                     <sequence>
-                        <reply faultName="sto:BuyFailed" name="Send_BuyFailed" operation="buy" partnerLink="BuyerToStore" portType="sto:Store" variable="BuyFailedFaultVar"/>
+                        <reply faultName="sto:BuyFailed" name="Send_BuyFailed" operation="buy" partnerLink="BuyerToStore" portType="sto:StoreInterface" variable="BuyFailedFaultVar"/>
                     </sequence>
                 </catch>
             </faultHandlers>
             <sequence>
-                <invoke inputVariable="checkCreditRequestVar" name="Send_CreditCheckRequest" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="StoreToCreditAgency" portType="pur:CreditAgency"/>
-                <reply name="Send_BuyConfirmed" operation="buy" partnerLink="BuyerToStore" portType="sto:Store" variable="buyResponseVar"/>
+                <invoke inputVariable="checkCreditRequestVar" name="Send_CreditCheckRequest" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="StoreToCreditAgency" portType="pur:CreditAgencyInterface"/>
+                <reply name="Send_BuyConfirmed" operation="buy" partnerLink="BuyerToStore" portType="sto:StoreInterface" variable="buyResponseVar"/>
             </sequence>
         </scope>
     </sequence>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Buyer.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Buyer.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Buyer.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -16,7 +16,7 @@
                 </catch>
             </faultHandlers>
             <sequence>
-                <invoke inputVariable="checkCreditRequestVar" name="Send_CreditInformation" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="BuyerToSeller" portType="slr:Seller"/>
+                <invoke inputVariable="checkCreditRequestVar" name="Send_CreditInformation" operation="checkCredit" outputVariable="checkCreditResponseVar" partnerLink="BuyerToSeller" portType="slr:SellerBehavior"/>
             </sequence>
         </scope>
     </sequence>

Modified: branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Seller.bpel
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Seller.bpel	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.bpel/src/test/resources/results/bpel/ReqRespFault at Seller.bpel	2011-02-17 16:44:18 UTC (rev 680)
@@ -10,14 +10,14 @@
         <variable messageType="slr:insufficientCreditFault" name="insufficientCreditFaultVar"/>
     </variables>
     <sequence>
-        <receive createInstance="yes" name="Receive_CreditInformation" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:Seller" variable="checkCreditRequestVar"/>
+        <receive createInstance="yes" name="Receive_CreditInformation" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:SellerBehavior" variable="checkCreditRequestVar"/>
         <if>
             <sequence>
-                <reply name="Send_CreditValid" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:Seller" variable="checkCreditResponseVar"/>
+                <reply name="Send_CreditValid" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:SellerBehavior" variable="checkCreditResponseVar"/>
             </sequence>
             <else>
                 <sequence>
-                    <reply faultName="slr:insufficientCredit" name="Send_CreditInvalid" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:Seller" variable="insufficientCreditFaultVar"/>
+                    <reply faultName="slr:insufficientCredit" name="Send_CreditInvalid" operation="checkCredit" partnerLink="BuyerToSeller" portType="slr:SellerBehavior" variable="insufficientCreditFaultVar"/>
                 </sequence>
             </else>
         </if>

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/ChoiceConverterRuleImpl.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/ChoiceConverterRuleImpl.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/ChoiceConverterRuleImpl.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -197,6 +197,15 @@
 											CDLTypeUtil.getURIFragment(ed));
 								
 								block.getAnnotations().add(scannotation);
+								
+								// Set interface name
+								if (locator.getInteraction().getToRoleType() != null) {
+									// TODO: Deal with interfaces that have multiple behaviours	
+									Annotation annotation=new Annotation(AnnotationDefinitions.INTERFACE);
+									annotation.getProperties().put(AnnotationDefinitions.NAME_PROPERTY,
+												InteractionConverterRuleImpl.getInterfaceName(locator.getInteraction()));
+									block.getAnnotations().add(annotation);
+								}
 							}
 						}
 						

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/InteractionConverterRuleImpl.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/InteractionConverterRuleImpl.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/main/java/org/savara/pi4soa/cdm/parser/rules/InteractionConverterRuleImpl.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -813,13 +813,34 @@
 	 * @param interaction The interaction
 	 * @return The interface name
 	 */
-	protected String getInterfaceName(org.pi4soa.cdl.Interaction interaction) {
+	protected static String getInterfaceName(org.pi4soa.cdl.Interaction interaction) {
 		String ret=null;
 		
 		if (interaction != null) {
 			String intfName=getInterface(interaction);
 			
-			String ns=CDLTypeUtil.getNamespace(intfName, interaction, true);
+			String ns=CDLTypeUtil.getNamespace(intfName, interaction, false);
+			
+			if (ns == null) {
+				ParticipantType ptype=null;
+				
+				// Check if interaction is associated with a 'to' participant/type
+				// from which a service namespace could be derived
+				if (interaction.getToRoleType() != null &&
+						(ptype = PackageUtil.getParticipantForRoleType(
+								interaction.getToRoleType())) != null) {
+					ns=CDLTypeUtil.getNamespace(ptype.getName(), interaction, false);
+					
+					logger.fine("Deriving namespace from interactions 'to' participant type="+ns);
+				}
+				
+				// If no other namespace is available, then use target namespace
+				if (ns == null) {
+					ns = interaction.getPackage().getTargetNamespace();
+					logger.fine("Using CDL package targetNamespace="+ns);
+				}
+			}
+			
 			String lp=XMLUtils.getLocalname(intfName);
 			
 			ret = NameSpaceUtil.getFullyQualifiedName(ns, lp);
@@ -834,7 +855,7 @@
 	 * @param interaction The interaction
 	 * @return The interface
 	 */
-	protected String getInterface(Interaction interaction) {
+	protected static String getInterface(Interaction interaction) {
 		String ret=null;
 			
 		if (interaction != null &&

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ESBBroker.spr
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ESBBroker.spr	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ESBBroker.spr	2011-02-17 16:44:18 UTC (rev 680)
@@ -16,7 +16,7 @@
 protocol ESBBrokerProcess {
 	role Broker, Buyer, CreditAgency, Supplier;
 	[[ SourceComponent(id=//@choreographies.0/@activities.0/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+	[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 	[[ Correlation(request=makeEnquiry) ]]
 	makeEnquiry(Enquiry) from Buyer to Broker;
 	[[ SourceComponent(id=//@choreographies.0/@activities.1) ]]
@@ -25,50 +25,54 @@
 		run RequestForQuote(Broker);
 	}
 	[[ SourceComponent(id=//@choreographies.0/@activities.2/@activities.0/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+	[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 	[[ Correlation(replyTo=makeEnquiry) ]]
 	makeEnquiry(QuoteList) from Broker to Buyer;
 	[[ SourceComponent(id=//@choreographies.0/@activities.3) ]]
 	choice from Buyer to Broker {
 		[[ Correlation(request=buy) ]]
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 		buy(Buy):
 			role SupplierTxnProcessor;
 			[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.1/@exchangeDetails.0) ]]
-			[[ Interface(name={http://www.pi4soa.org/ESBBroker}CreditAgencyBehavior) ]]
+			[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 			[[ Correlation(request=checkCredit) ]]
 			checkCredit(CreditInformation) from Broker to CreditAgency;
 			[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2) ]]
 			choice from CreditAgency to Broker {
 				[[ Correlation(replyTo=checkCredit) ]]
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.0/@exchangeDetails.0) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 				checkCredit(CreditValid):
 					[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.1/@exchangeDetails.0) ]]
-					[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+					[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 					[[ Correlation(request=confirm) ]]
 					confirm(OrderConfirmed) from Broker to SupplierTxnProcessor;
 					[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.1/@exchangeDetails.1) ]]
-					[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+					[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 					[[ Correlation(replyTo=confirm) ]]
 					confirm(BookingReference) from SupplierTxnProcessor to Broker;
 					[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.2/@exchangeDetails.0) ]]
-					[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+					[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 					[[ Correlation(replyTo=buy) ]]
 					buy(BookingReference) from Broker to Buyer;
 
 				[[ Fault(name=invalidCredit) ]]
 				[[ Correlation(replyTo=checkCredit) ]]
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.1/@activities.0/@exchangeDetails.0) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 				checkCredit(CreditInvalid):
 					[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.1/@activities.1/@exchangeDetails.0) ]]
 					[[ Fault(name=rejected) ]]
-					[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+					[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 					[[ Correlation(replyTo=buy) ]]
 					buy(OrderRejected) from Broker to Buyer;
 
 			}
 
 		[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.1/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 		cancel(Cancel):
 
 	}
@@ -77,38 +81,40 @@
 	protocol CompleteTransaction(role Buyer, role Broker, role CreditAgency) {
 		role SupplierTxnProcessor;
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.0/@exchangeDetails.0) ]]
-		[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 		[[ Correlation(request=buy) ]]
 		buy(Buy) from Buyer to Broker;
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.1/@exchangeDetails.0) ]]
-		[[ Interface(name={http://www.pi4soa.org/ESBBroker}CreditAgencyBehavior) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 		[[ Correlation(request=checkCredit) ]]
 		checkCredit(CreditInformation) from Broker to CreditAgency;
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2) ]]
 		choice from CreditAgency to Broker {
 			[[ Correlation(replyTo=checkCredit) ]]
 			[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.0/@exchangeDetails.0) ]]
+			[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 			checkCredit(CreditValid):
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.1/@exchangeDetails.0) ]]
-				[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 				[[ Correlation(request=confirm) ]]
 				confirm(OrderConfirmed) from Broker to SupplierTxnProcessor;
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.1/@exchangeDetails.1) ]]
-				[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 				[[ Correlation(replyTo=confirm) ]]
 				confirm(BookingReference) from SupplierTxnProcessor to Broker;
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.0/@activities.2/@exchangeDetails.0) ]]
-				[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 				[[ Correlation(replyTo=buy) ]]
 				buy(BookingReference) from Broker to Buyer;
 
 			[[ Fault(name=invalidCredit) ]]
 			[[ Correlation(replyTo=checkCredit) ]]
 			[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.1/@activities.0/@exchangeDetails.0) ]]
+			[[ Interface(name={http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior) ]]
 			checkCredit(CreditInvalid):
 				[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.0/@activities.2/@activities.1/@activities.1/@exchangeDetails.0) ]]
 				[[ Fault(name=rejected) ]]
-				[[ Interface(name={http://www.pi4soa.org/ESBBroker}BrokerBehavior) ]]
+				[[ Interface(name={http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior) ]]
 				[[ Correlation(replyTo=buy) ]]
 				buy(OrderRejected) from Broker to Buyer;
 
@@ -119,11 +125,11 @@
 	protocol RequestForQuote(role Broker) {
 		role SupplierQuoteEngine;
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.1/@activities.0/@exchangeDetails.0) ]]
-		[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 		[[ Correlation(request=getQuote) ]]
 		getQuote(RequestForQuote) from Broker to SupplierQuoteEngine;
 		[[ SourceComponent(id=//@choreographies.0/@enclosedChoreographies.1/@activities.0/@exchangeDetails.1) ]]
-		[[ Interface(name={http://www.pi4soa.org/ESBBroker}SupplierBehavior) ]]
+		[[ Interface(name={http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior) ]]
 		[[ Correlation(replyTo=getQuote) ]]
 		getQuote(Quote) from SupplierQuoteEngine to Broker;
 	}

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PolicyQuote.spr
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PolicyQuote.spr	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PolicyQuote.spr	2011-02-17 16:44:18 UTC (rev 680)
@@ -28,14 +28,14 @@
 protocol PolicyQuoteProcess {
 	role Driver, CreditCheckService, DrivingRecordService, PolicyQuoteCalculationService, PolicyQuoteEntityService, PolicyQuoteProcessService;
 	[[ SourceComponent(id=//@choreographies.0/@activities.0/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteProcessService) ]]
+	[[ Interface(name={http://www.example.org/policyQuoteProcessService}PolicyQuoteProcessService) ]]
 	[[ Correlation(request=receivePolicyQuote) ]]
 	receivePolicyQuote(PolicyQuote) from Driver to PolicyQuoteProcessService;
 	[[ SourceComponent(id=//@choreographies.0/@activities.1/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/PolicyQuote}DrivingRecordService) ]]
+	[[ Interface(name={http://dmv.com/drivingRecordService}DrivingRecordService) ]]
 	checkDrivingRecord(DrivingRecordRequest) from PolicyQuoteProcessService to DrivingRecordService;
 	[[ SourceComponent(id=//@choreographies.0/@activities.2/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/PolicyQuote}DrivingRecordCallbackService) ]]
+	[[ Interface(name={http://www.example.org/policyQuoteProcessService}DrivingRecordCallbackService) ]]
 	receiveDrivingRecord(DrivingRecordResponse) from DrivingRecordService to PolicyQuoteProcessService;
 	[[ SourceComponent(id=//@choreographies.0/@activities.3) ]]
 	choice {
@@ -43,27 +43,27 @@
 			[[ Correlation(request=checkCredit) ]]
 			checkCredit(CreditCheckRequest) from PolicyQuoteProcessService to CreditCheckService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.0/@exchangeDetails.1) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}CreditCheckService) ]]
+			[[ Interface(name={http://creditagency.com/creditCheckService}CreditCheckService) ]]
 			[[ Correlation(replyTo=checkCredit) ]]
 			checkCredit(CreditCheckResponse) from CreditCheckService to PolicyQuoteProcessService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.1/@exchangeDetails.0) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteCalculationService) ]]
+			[[ Interface(name={http://www.example.org/policyQuoteCalculationService}PolicyQuoteCalculationService) ]]
 			[[ Correlation(request=calculatePolicyQuote) ]]
 			calculatePolicyQuote(PolicyQuote) from PolicyQuoteProcessService to PolicyQuoteCalculationService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.1/@exchangeDetails.1) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteCalculationService) ]]
+			[[ Interface(name={http://www.example.org/policyQuoteCalculationService}PolicyQuoteCalculationService) ]]
 			[[ Correlation(replyTo=calculatePolicyQuote) ]]
 			calculatePolicyQuote(PolicyQuoteReply) from PolicyQuoteCalculationService to PolicyQuoteProcessService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.2/@exchangeDetails.0) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteEntityService) ]]
+			[[ Interface(name={http://www.example.org/policyQuoteEntityService}PolicyQuoteEntityService) ]]
 			[[ Correlation(request=createPolicyQuote) ]]
 			createPolicyQuote(PolicyQuote) from PolicyQuoteProcessService to PolicyQuoteEntityService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.2/@exchangeDetails.1) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteEntityService) ]]
+			[[ Interface(name={http://www.example.org/policyQuoteEntityService}PolicyQuoteEntityService) ]]
 			[[ Correlation(replyTo=createPolicyQuote) ]]
 			createPolicyQuote(PolicyQuoteReply) from PolicyQuoteEntityService to PolicyQuoteProcessService;
 			[[ SourceComponent(id=//@choreographies.0/@activities.3/@activities.0/@activities.0/@activities.3/@exchangeDetails.0) ]]
-			[[ Interface(name={http://www.pi4soa.org/PolicyQuote}PolicyQuoteProcessService) ]]
+			[[ Interface(name={http://www.example.org/policyQuoteProcessService}PolicyQuoteProcessService) ]]
 			[[ Correlation(replyTo=receivePolicyQuote) ]]
 			receivePolicyQuote(PolicyQuoteReply) from PolicyQuoteProcessService to Driver;
 

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PurchaseGoods.spr
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PurchaseGoods.spr	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/PurchaseGoods.spr	2011-02-17 16:44:18 UTC (rev 680)
@@ -26,6 +26,7 @@
 	choice from CreditAgency to Store {
 		[[ Correlation(replyTo=checkCredit) ]]
 		[[ SourceComponent(id=//@choreographies.0/@activities.2/@activities.0/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={java:org.jboss.savara.examples.purchasing}CreditAgencyInterface) ]]
 		checkCredit(CreditCheckOk):
 			[[ SourceComponent(id=//@choreographies.0/@activities.2/@activities.0/@activities.1/@exchangeDetails.0) ]]
 			[[ Interface(name={http://www.jboss.org/examples/store}StoreInterface) ]]
@@ -35,6 +36,7 @@
 		[[ Fault(name=CreditCheckFailed) ]]
 		[[ Correlation(replyTo=checkCredit) ]]
 		[[ SourceComponent(id=//@choreographies.0/@activities.2/@activities.1/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={java:org.jboss.savara.examples.purchasing}CreditAgencyInterface) ]]
 		checkCredit(CreditCheckInvalid):
 			[[ SourceComponent(id=//@choreographies.0/@activities.2/@activities.1/@activities.1/@exchangeDetails.0) ]]
 			[[ Fault(name=BuyFailed) ]]

Modified: branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ReqRespFault.spr
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ReqRespFault.spr	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.pi4soa.cdm/src/test/resources/results/protocol/ReqRespFault.spr	2011-02-17 16:44:18 UTC (rev 680)
@@ -10,18 +10,20 @@
 protocol ReqRespFaultProcess {
 	role Buyer, Seller;
 	[[ SourceComponent(id=//@choreographies.0/@activities.0/@exchangeDetails.0) ]]
-	[[ Interface(name={http://www.pi4soa.org/ReqRespFault}SellerBehavior) ]]
+	[[ Interface(name={http://www.pi4soa.org/ReqRespFault/Seller}SellerBehavior) ]]
 	[[ Correlation(request=checkCredit) ]]
 	checkCredit(CreditInformation) from Buyer to Seller;
 	[[ SourceComponent(id=//@choreographies.0/@activities.1) ]]
 	choice from Seller to Buyer {
 		[[ Correlation(replyTo=checkCredit) ]]
 		[[ SourceComponent(id=//@choreographies.0/@activities.1/@activities.0/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={http://www.pi4soa.org/ReqRespFault/Seller}SellerBehavior) ]]
 		checkCredit(CreditValid):
 
 		[[ Fault(name=insufficientCredit) ]]
 		[[ Correlation(replyTo=checkCredit) ]]
 		[[ SourceComponent(id=//@choreographies.0/@activities.1/@activities.1/@activities.0/@exchangeDetails.0) ]]
+		[[ Interface(name={http://www.pi4soa.org/ReqRespFault/Seller}SellerBehavior) ]]
 		checkCredit(CreditInvalid):
 
 	}

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/main/java/org/savara/protocol/contract/generator/impl/ContractIntrospector.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/main/java/org/savara/protocol/contract/generator/impl/ContractIntrospector.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/main/java/org/savara/protocol/contract/generator/impl/ContractIntrospector.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -24,6 +24,8 @@
 import java.text.MessageFormat;
 import java.util.logging.Logger;
 
+import javax.xml.namespace.QName;
+
 import org.savara.protocol.model.util.InteractionUtil;
 import org.savara.protocol.model.util.TypeSystem;
 import org.savara.common.model.annotation.Annotation;
@@ -42,6 +44,7 @@
 import org.scribble.protocol.model.DefaultVisitor;
 import org.scribble.protocol.model.Protocol;
 import org.scribble.protocol.model.Interaction;
+import org.scribble.protocol.model.ProtocolModel;
 import org.scribble.protocol.model.Run;
 import org.scribble.protocol.model.Role;
 import org.scribble.protocol.model.TypeImport;
@@ -147,32 +150,27 @@
 	 * 
 	 * @return The interface
 	 */
-	public Interface getInterface() {
-		Interface ret=getContract().getInterface(m_serverRole.getName());
+	public Interface getInterface(ProtocolModel model, String intfName) {
+		QName qname=null;
 		
+		// TODO: Check Contract/Interface - whether should have separate name/namespace?
+		
+		if (intfName == null || intfName.trim().length() == 0) {
+			qname = new QName(m_contract.getNamespace(), m_serverRole.getName());
+		} else {
+			qname = QName.valueOf(intfName);
+		}
+		
+		Interface ret=getContract().getInterface(qname.getLocalPart());
+		
 		if (ret == null) {
 			// Create interface for the role
 			ret = new Interface();
-			ret.setName(m_serverRole.getName());
+			ret.setName(qname.getLocalPart());
 			
-			// TODO: Need to consider how to manage different interfaces,
-			// in case the choreography has multiple interfaces. Each
-			// interaction could have an 'INTERFACE_NAME' property which
-			// could determine the interface - and if not defined default
-			// to using an interface named after the role
+			ret.setNamespace(qname.getNamespaceURI());
 			
-			/*
-			Annotation annotation=AnnotationDefinitions.getAnnotation(m_role.getProperties(),
-								AnnotationDefinitions.NAMESPACE);
-			if (annotation != null) {
-				String namespace=(String)annotation.getProperties().get(AnnotationDefinitions.NAME_PROPERTY);
-				
-				if (namespace != null) {
-					ret.setNamespace(namespace);
-				}
-			}
-			*/
-			ret.setNamespace(m_contract.getNamespace());
+			addNamespace(model, qname.getNamespaceURI());
 			
 			getContract().getInterfaces().add(ret);
 		}
@@ -206,6 +204,17 @@
 		}
 		
 		m_protocol.visit(this);
+		
+		// Ensure only interfaces with atleast one operation remain
+		java.util.Iterator<Interface> iter=getContract().getInterfaces().iterator();
+		
+		while (iter.hasNext()) {
+			Interface intf=iter.next();
+			
+			if (intf.getMessageExchangePatterns().size() == 0) {
+				iter.remove();
+			}
+		}
 	}
 	
 
@@ -313,20 +322,17 @@
 			return;		
 		}
 		
+		// Check if interface has been specified
+		String intfName=null;
+		
+		Annotation intfAnn=AnnotationDefinitions.getAnnotation(interaction.getAnnotations(), AnnotationDefinitions.INTERFACE);
+		if (intfAnn != null) {
+			intfName = (String)intfAnn.getProperties().get(AnnotationDefinitions.NAME_PROPERTY);
+		}
+		
 		// Receiving a request - so record this in the contract
-		Interface intf=getInterface();
+		Interface intf=getInterface(interaction.getModel(), intfName);
 
-		/*
-		// Check if the interacton is being received
-		if (interaction.getFromRole() != null &&
-				interaction.getFromRole().equals(m_role) == false) {
-			
-			// Received by the role, but need to check if its replyTo
-			// has been set, indicating it is receiving a response
-			if (InteractionUtil.getReplyToLabel(interaction) == null ||
-					InteractionUtil.getReplyToLabel(interaction).trim().length() == 0) {
-		*/
-		
 		// Check if receiving a request
 		if (InteractionUtil.isRequest(interaction) && !InteractionUtil.isSend(interaction, m_serverRole)) {
 				
@@ -412,8 +418,16 @@
 			return(true);		
 		}
 		
+		// Check if interface has been specified
+		String intfName=null;
+		
+		Annotation intfAnn=AnnotationDefinitions.getAnnotation(when.getAnnotations(), AnnotationDefinitions.INTERFACE);
+		if (intfAnn != null) {
+			intfName = (String)intfAnn.getProperties().get(AnnotationDefinitions.NAME_PROPERTY);
+		}
+		
 		// Receiving a request - so record this in the contract
-		Interface intf=getInterface();
+		Interface intf=getInterface(when.getModel(), intfName);
 
 		// Check if receiving a request
 		if (InteractionUtil.isRequest(when) && !InteractionUtil.isSend(when, m_serverRole)) {
@@ -558,7 +572,12 @@
 					td.setTypeSystem(til.getFormat());
 					
 					if (til.getFormat() != null && TypeSystem.XSD.equals(til.getFormat()) &&
-							til.getLocation() != null &&
+								til.getLocation() != null) {
+						
+						addNamespace(tref.getModel(), til.getLocation());
+					}
+					
+					/*
 							getContract().getNamespaceForURI(til.getLocation()) == null) {
 						
 						// Check if namespace has been defined for location
@@ -581,6 +600,7 @@
 							}
 						}
 					}
+					*/
 				}
 			}
 			
@@ -598,4 +618,27 @@
 		
 		return(ret);
 	}
+	
+	protected void addNamespace(ProtocolModel model, String namespace) {
+		// Check if namespace has been defined for location
+		if (getContract().getNamespaceForURI(namespace) == null && model != null) {
+			java.util.List<Annotation> annotations=
+				AnnotationDefinitions.getAnnotations(model.getProtocol().getAnnotations(),
+							AnnotationDefinitions.TYPE);
+			
+			for (Annotation ann : annotations) {
+				String nstxt=(String)ann.getProperties().get(AnnotationDefinitions.NAMESPACE_PROPERTY);
+				
+				if (nstxt != null && nstxt.equals(namespace)) {
+					Namespace ns=new Namespace();
+					ns.setURI(namespace);
+					ns.setPrefix((String)ann.getProperties().get(AnnotationDefinitions.PREFIX_PROPERTY));
+					ns.setSchemaLocation((String)ann.getProperties().get(AnnotationDefinitions.LOCATION_PROPERTY));
+					getContract().getNamespaces().add(ns);
+					
+					break;
+				}
+			}
+		}
+	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/ContractGeneratorTest.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/ContractGeneratorTest.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/ContractGeneratorTest.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -2,16 +2,12 @@
 
 import static org.junit.Assert.*;
 
-import org.savara.contract.model.Contract;
 import org.savara.protocol.contract.generator.ContractGenerator;
 import org.savara.protocol.contract.generator.ContractGeneratorFactory;
 import org.scribble.common.logging.CachedJournal;
 import org.scribble.common.logging.Journal;
-import org.scribble.protocol.model.Interaction;
-import org.scribble.protocol.model.MessageSignature;
 import org.scribble.protocol.model.Protocol;
 import org.scribble.protocol.model.Role;
-import org.scribble.protocol.model.TypeReference;
 
 public class ContractGeneratorTest {
 
@@ -73,52 +69,4 @@
 		}
 	}
 
-	@org.junit.Test
-	public void testGenerateOneWayRequestSend() {
-		
-		ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
-		
-		try {
-			Role fromRole=new Role();
-			fromRole.setName("from");
-			
-			Role toRole=new Role();
-			toRole.setName("to");
-			
-			Protocol conv=new Protocol();
-			conv.setRole(fromRole);
-			conv.setName("LocatedProtocol");
-			
-			Interaction interaction=new Interaction();
-			interaction.getToRoles().add(toRole);
-			
-			MessageSignature ms=new MessageSignature();			
-			ms.setOperation("op");
-			
-			interaction.setMessageSignature(ms);
-			
-			TypeReference tref1=new TypeReference();
-			tref1.setName("type");
-			ms.getTypeReferences().add(tref1);
-			
-			conv.getBlock().add(interaction);
-			
-			Journal journal=new CachedJournal();
-			
-			Contract c=generator.generate(conv, journal);
-					
-			if (c == null) {
-				fail("Contract is null");
-			}
-			
-			if (c.getInterfaces().size() != 1) {
-				fail("Only one interface expected");
-			}
-			
-			
-			
-		} catch(IllegalArgumentException iae) {			
-			fail("Should NOT have thrown IllegalArgumentException");
-		}
-	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/impl/ContractIntrospectorTest.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/impl/ContractIntrospectorTest.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/java/org/savara/protocol/contract/generator/impl/ContractIntrospectorTest.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -160,7 +160,7 @@
 			fail("Should be 0 interfaces: "+introspector.getContract().getInterfaces().size());
 		}
 		
-		Interface intf=introspector.getInterface();
+		Interface intf=introspector.getInterface(null, null);
 		
 		if (intf == null) {
 			fail("Interface not created");
@@ -170,7 +170,7 @@
 			fail("Should be 1 interface: "+introspector.getContract().getInterfaces().size());
 		}
 		
-		Interface intf2=introspector.getInterface();
+		Interface intf2=introspector.getInterface(null, null);
 		
 		if (intf2 != intf) {
 			fail("Interfaces are different");

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Broker.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Broker.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Broker.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,4 +1,7 @@
 Contract {http://www.pi4soa.org/ESBBroker/Broker}Broker {
+	Namespace prefix=brk uri=http://www.pi4soa.org/ESBBroker/Broker schemaLocation=null
+	Namespace prefix=cay uri=http://www.pi4soa.org/ESBBroker/CreditAgency schemaLocation=null
+	Namespace prefix=spr uri=http://www.pi4soa.org/ESBBroker/Supplier schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef BookingReference type=bookingReference location=null typeSystem=xsd
 	[[ XSDElement ]]
@@ -11,7 +14,7 @@
 	TypeDef OrderRejected type=orderRejected location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef QuoteList type=quoteList location=null typeSystem=xsd
-	Interface {http://www.pi4soa.org/ESBBroker/Broker}Broker {
+	Interface {http://www.pi4soa.org/ESBBroker/Broker}BrokerBehavior {
 		RequestResponseMEP makeEnquiry( Enquiry ) : QuoteList 
 		RequestResponseMEP buy( Buy ) : BookingReference Fault rejected( OrderRejected ) 
 		OneWayRequestMEP cancel( Cancel )

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Buyer.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Buyer.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at Buyer.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,4 +1,3 @@
 Contract {http://www.pi4soa.org/ESBBroker/Buyer}Buyer {
-	Interface {http://www.pi4soa.org/ESBBroker/Buyer}Buyer {
-	}
+	Namespace prefix=brk uri=http://www.pi4soa.org/ESBBroker/Broker schemaLocation=null
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at CreditAgency.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at CreditAgency.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at CreditAgency.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,11 +1,12 @@
 Contract {http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgency {
+	Namespace prefix=cay uri=http://www.pi4soa.org/ESBBroker/CreditAgency schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef CreditInformation type=CreditCheckRequest location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef CreditInvalid type=CreditCheckInvalid location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef CreditValid type=CreditCheckOk location=null typeSystem=xsd
-	Interface {http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgency {
+	Interface {http://www.pi4soa.org/ESBBroker/CreditAgency}CreditAgencyBehavior {
 		RequestResponseMEP checkCredit( CreditInformation ) : CreditValid Fault invalidCredit( CreditInvalid ) 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierQuoteEngine.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierQuoteEngine.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierQuoteEngine.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,9 +1,10 @@
 Contract {http://www.pi4soa.org/ESBBroker/Supplier}SupplierQuoteEngine {
+	Namespace prefix=spr uri=http://www.pi4soa.org/ESBBroker/Supplier schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef Quote type=quote location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef RequestForQuote type=requestForQuote location=null typeSystem=xsd
-	Interface {http://www.pi4soa.org/ESBBroker/Supplier}SupplierQuoteEngine {
+	Interface {http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior {
 		RequestResponseMEP getQuote( RequestForQuote ) : Quote 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierTxnProcessor.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierTxnProcessor.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ESBBroker at SupplierTxnProcessor.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,9 +1,10 @@
 Contract {http://www.pi4soa.org/ESBBroker/Supplier}SupplierTxnProcessor {
+	Namespace prefix=spr uri=http://www.pi4soa.org/ESBBroker/Supplier schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef BookingReference type=bookingReference location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef OrderConfirmed type=orderConfirmed location=null typeSystem=xsd
-	Interface {http://www.pi4soa.org/ESBBroker/Supplier}SupplierTxnProcessor {
+	Interface {http://www.pi4soa.org/ESBBroker/Supplier}SupplierBehavior {
 		RequestResponseMEP confirm( OrderConfirmed ) : BookingReference 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at CreditCheckService.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at CreditCheckService.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at CreditCheckService.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,6 @@
 Contract {http://creditagency.com/creditCheckService}CreditCheckService {
 	Namespace prefix=cred uri=http://creditagency.com/creditCheck schemaLocation=schema/creditCheck.xsd
+	Namespace prefix=ca uri=http://creditagency.com/creditCheckService schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef CreditCheckRequest type={http://creditagency.com/creditCheck}creditCheckRequest location=null typeSystem=xsd
 	[[ XSDElement ]]

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at PolicyQuoteProcessService.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at PolicyQuoteProcessService.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PolicyQuote at PolicyQuoteProcessService.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,6 +1,11 @@
 Contract {http://www.example.org/policyQuoteProcessService}PolicyQuoteProcessService {
+	Namespace prefix=ca uri=http://creditagency.com/creditCheckService schemaLocation=null
 	Namespace prefix=drv uri=http://dmv.com/drivingRecord schemaLocation=schema/drivingRecord.xsd
+	Namespace prefix=dmv uri=http://dmv.com/drivingRecordService schemaLocation=null
 	Namespace prefix=pol uri=http://www.example.org/policyQuote schemaLocation=schema/policyQuote.xsd
+	Namespace prefix=pcs uri=http://www.example.org/policyQuoteCalculationService schemaLocation=null
+	Namespace prefix=pes uri=http://www.example.org/policyQuoteEntityService schemaLocation=null
+	Namespace prefix=pps uri=http://www.example.org/policyQuoteProcessService schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef DrivingRecordResponse type={http://dmv.com/drivingRecord}drivingRecordResponse location=null typeSystem=xsd
 	[[ XSDElement ]]
@@ -9,8 +14,10 @@
 	TypeDef PolicyQuoteFault type={http://www.example.org/policyQuote}policyQuoteFault location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef PolicyQuoteReply type={http://www.example.org/policyQuote}policyQuoteReply location=null typeSystem=xsd
+	Interface {http://www.example.org/policyQuoteProcessService}DrivingRecordCallbackService {
+		OneWayRequestMEP receiveDrivingRecord( DrivingRecordResponse )
+	}
 	Interface {http://www.example.org/policyQuoteProcessService}PolicyQuoteProcessService {
 		RequestResponseMEP receivePolicyQuote( PolicyQuote ) : PolicyQuoteReply Fault policyQuoteFault( PolicyQuoteFault ) 
-		OneWayRequestMEP receiveDrivingRecord( DrivingRecordResponse )
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Buyer.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Buyer.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Buyer.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,4 +1,3 @@
 Contract {http://www.jboss.org/savara/examples}Buyer {
-	Interface {http://www.jboss.org/savara/examples}Buyer {
-	}
+	Namespace prefix=sto uri=http://www.jboss.org/examples/store schemaLocation=null
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at CreditAgency.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at CreditAgency.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at CreditAgency.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -6,7 +6,7 @@
 	TypeDef CreditCheckOk type={java:org.jboss.savara.examples.purchasing}CreditCheckOk location=null typeSystem=xsd
 	[[ XSDType ]]
 	TypeDef CreditCheckRequest type={java:org.jboss.savara.examples.purchasing}CreditCheckRequest location=null typeSystem=xsd
-	Interface {java:org.jboss.savara.examples.purchasing}CreditAgency {
+	Interface {java:org.jboss.savara.examples.purchasing}CreditAgencyInterface {
 		RequestResponseMEP checkCredit( CreditCheckRequest ) : CreditCheckOk Fault CreditCheckFailed( CreditCheckInvalid ) 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,12 +1,13 @@
 Contract {http://www.jboss.org/examples/store}Store {
 	Namespace prefix=sto uri=http://www.jboss.org/examples/store schemaLocation=null
+	Namespace prefix=pur uri=java:org.jboss.savara.examples.purchasing schemaLocation=null
 	[[ XSDType ]]
 	TypeDef BuyConfirmed type={http://www.jboss.org/examples/store}BuyConfirmed location=null typeSystem=xsd
 	[[ XSDType ]]
 	TypeDef BuyFailed type={http://www.jboss.org/examples/store}BuyFailed location=null typeSystem=xsd
 	[[ XSDType ]]
 	TypeDef BuyRequest type={http://www.jboss.org/examples/store}BuyRequest location=null typeSystem=xsd
-	Interface {http://www.jboss.org/examples/store}Store {
+	Interface {http://www.jboss.org/examples/store}StoreInterface {
 		RequestResponseMEP buy( BuyRequest ) : BuyConfirmed Fault BuyFailed( BuyFailed ) 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store_CreditAgency.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store_CreditAgency.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/PurchaseGoods at Store_CreditAgency.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,4 +1,3 @@
 Contract {http://www.jboss.org/examples/store}Store {
-	Interface {http://www.jboss.org/examples/store}Store {
-	}
+	Namespace prefix=pur uri=java:org.jboss.savara.examples.purchasing schemaLocation=null
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Buyer.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Buyer.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Buyer.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,4 +1,3 @@
 Contract {http://www.pi4soa.org/ReqRespFault/Buyer}Buyer {
-	Interface {http://www.pi4soa.org/ReqRespFault/Buyer}Buyer {
-	}
+	Namespace prefix=slr uri=http://www.pi4soa.org/ReqRespFault/Seller schemaLocation=null
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Seller.contract
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Seller.contract	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.protocol/src/test/resources/results/contract/ReqRespFault at Seller.contract	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,11 +1,12 @@
 Contract {http://www.pi4soa.org/ReqRespFault/Seller}Seller {
+	Namespace prefix=slr uri=http://www.pi4soa.org/ReqRespFault/Seller schemaLocation=null
 	[[ XSDElement ]]
 	TypeDef CreditInformation type=CreditCheckRequest location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef CreditInvalid type=CreditCheckInvalid location=null typeSystem=xsd
 	[[ XSDElement ]]
 	TypeDef CreditValid type=CreditCheckOk location=null typeSystem=xsd
-	Interface {http://www.pi4soa.org/ReqRespFault/Seller}Seller {
+	Interface {http://www.pi4soa.org/ReqRespFault/Seller}SellerBehavior {
 		RequestResponseMEP checkCredit( CreditInformation ) : CreditValid Fault insufficientCredit( CreditInvalid ) 
 	}
 }

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/main/java/org/savara/wsdl/generator/impl/WSDLGeneratorImpl.java
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/main/java/org/savara/wsdl/generator/impl/WSDLGeneratorImpl.java	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/main/java/org/savara/wsdl/generator/impl/WSDLGeneratorImpl.java	2011-02-17 16:44:18 UTC (rev 680)
@@ -17,6 +17,9 @@
  */
 package org.savara.wsdl.generator.impl;
 
+import java.util.Collections;
+import java.util.Comparator;
+
 import javax.wsdl.Part;
 import javax.xml.namespace.QName;
 
@@ -172,14 +175,18 @@
 				ret.setQName(new javax.xml.namespace.QName(contract.getName()));
 			}
 			ret.setTargetNamespace(targetNamespace);
-			ret.addNamespace("tns", targetNamespace);
+			//ret.addNamespace("tns", targetNamespace);
 			
 			// Set up namespace mappings
-			java.util.Iterator<Namespace> iter=contract.getNamespaces().iterator();
+			java.util.List<Namespace> nss=new java.util.Vector<Namespace>(contract.getNamespaces());
 			
-			while (iter.hasNext()) {
-				Namespace ns=iter.next();
-				
+			Collections.sort(nss, new Comparator<Namespace>() {
+				public int compare(Namespace o1, Namespace o2) {
+					return o2.getPrefix().compareTo(o1.getPrefix());
+				}				
+			});
+			
+			for (Namespace ns : nss) {
 				ret.addNamespace(ns.getPrefix(), ns.getURI());
 			}
 

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Broker_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Broker_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Broker_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Broker" targetNamespace="http://www.pi4soa.org/ESBBroker/Broker" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ESBBroker/Broker" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Broker" targetNamespace="http://www.pi4soa.org/ESBBroker/Broker" xmlns:brk="http://www.pi4soa.org/ESBBroker/Broker" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:cay="http://www.pi4soa.org/ESBBroker/CreditAgency" xmlns:spr="http://www.pi4soa.org/ESBBroker/Supplier">
   <wsdl:message name="rejectedFault">
     <wsdl:part name="content" element="orderRejected">
     </wsdl:part>
@@ -24,27 +24,27 @@
     <wsdl:part name="content" element="cancel">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="Broker">
+  <wsdl:portType name="BrokerBehavior">
     <wsdl:operation name="makeEnquiry">
-      <wsdl:input message="tns:makeEnquiryRequest">
+      <wsdl:input message="brk:makeEnquiryRequest">
     </wsdl:input>
-      <wsdl:output message="tns:makeEnquiryResponse">
+      <wsdl:output message="brk:makeEnquiryResponse">
     </wsdl:output>
     </wsdl:operation>
     <wsdl:operation name="buy">
-      <wsdl:input message="tns:buyRequest">
+      <wsdl:input message="brk:buyRequest">
     </wsdl:input>
-      <wsdl:output message="tns:buyResponse">
+      <wsdl:output message="brk:buyResponse">
     </wsdl:output>
-      <wsdl:fault name="rejected" message="tns:rejectedFault">
+      <wsdl:fault name="rejected" message="brk:rejectedFault">
     </wsdl:fault>
     </wsdl:operation>
     <wsdl:operation name="cancel">
-      <wsdl:input message="tns:cancelRequest">
+      <wsdl:input message="brk:cancelRequest">
     </wsdl:input>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="BrokerBinding" type="tns:Broker">
+  <wsdl:binding name="BrokerBehaviorBinding" type="brk:BrokerBehavior">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="makeEnquiry">
       <soap:operation soapAction="" style="rpc"/>
@@ -75,8 +75,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="BrokerService">
-    <wsdl:port name="BrokerPort" binding="tns:BrokerBinding">
-      <soap:address location="http://localhost:8080/BrokerService/BrokerPort"/>
+    <wsdl:port name="BrokerBehaviorPort" binding="brk:BrokerBehaviorBinding">
+      <soap:address location="http://localhost:8080/BrokerService/BrokerBehaviorPort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Buyer_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Buyer_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_Buyer_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,8 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Buyer" targetNamespace="http://www.pi4soa.org/ESBBroker/Buyer" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ESBBroker/Buyer" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Buyer" targetNamespace="http://www.pi4soa.org/ESBBroker/Buyer" xmlns:brk="http://www.pi4soa.org/ESBBroker/Broker" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:service name="BuyerService">
-    <wsdl:port name="BuyerPort" binding="tns:BuyerBinding">
-      <soap:address location="http://localhost:8080/BuyerService/BuyerPort"/>
-    </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_CreditAgency_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_CreditAgency_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_CreditAgency_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="CreditAgency" targetNamespace="http://www.pi4soa.org/ESBBroker/CreditAgency" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ESBBroker/CreditAgency" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="CreditAgency" targetNamespace="http://www.pi4soa.org/ESBBroker/CreditAgency" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:cay="http://www.pi4soa.org/ESBBroker/CreditAgency">
   <wsdl:message name="checkCreditResponse">
     <wsdl:part name="content" element="CreditCheckOk">
     </wsdl:part>
@@ -12,17 +12,17 @@
     <wsdl:part name="content" element="CreditCheckInvalid">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="CreditAgency">
+  <wsdl:portType name="CreditAgencyBehavior">
     <wsdl:operation name="checkCredit">
-      <wsdl:input message="tns:checkCreditRequest">
+      <wsdl:input message="cay:checkCreditRequest">
     </wsdl:input>
-      <wsdl:output message="tns:checkCreditResponse">
+      <wsdl:output message="cay:checkCreditResponse">
     </wsdl:output>
-      <wsdl:fault name="invalidCredit" message="tns:invalidCreditFault">
+      <wsdl:fault name="invalidCredit" message="cay:invalidCreditFault">
     </wsdl:fault>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="CreditAgencyBinding" type="tns:CreditAgency">
+  <wsdl:binding name="CreditAgencyBehaviorBinding" type="cay:CreditAgencyBehavior">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="checkCredit">
       <soap:operation soapAction="" style="rpc"/>
@@ -38,8 +38,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="CreditAgencyService">
-    <wsdl:port name="CreditAgencyPort" binding="tns:CreditAgencyBinding">
-      <soap:address location="http://localhost:8080/CreditAgencyService/CreditAgencyPort"/>
+    <wsdl:port name="CreditAgencyBehaviorPort" binding="cay:CreditAgencyBehaviorBinding">
+      <soap:address location="http://localhost:8080/CreditAgencyService/CreditAgencyBehaviorPort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierQuoteEngine_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierQuoteEngine_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierQuoteEngine_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="SupplierQuoteEngine" targetNamespace="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="SupplierQuoteEngine" targetNamespace="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:spr="http://www.pi4soa.org/ESBBroker/Supplier">
   <wsdl:message name="getQuoteResponse">
     <wsdl:part name="content" element="quote">
     </wsdl:part>
@@ -8,15 +8,15 @@
     <wsdl:part name="content" element="requestForQuote">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="SupplierQuoteEngine">
+  <wsdl:portType name="SupplierBehavior">
     <wsdl:operation name="getQuote">
-      <wsdl:input message="tns:getQuoteRequest">
+      <wsdl:input message="spr:getQuoteRequest">
     </wsdl:input>
-      <wsdl:output message="tns:getQuoteResponse">
+      <wsdl:output message="spr:getQuoteResponse">
     </wsdl:output>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="SupplierQuoteEngineBinding" type="tns:SupplierQuoteEngine">
+  <wsdl:binding name="SupplierBehaviorBinding" type="spr:SupplierBehavior">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="getQuote">
       <soap:operation soapAction="" style="rpc"/>
@@ -29,8 +29,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="SupplierQuoteEngineService">
-    <wsdl:port name="SupplierQuoteEnginePort" binding="tns:SupplierQuoteEngineBinding">
-      <soap:address location="http://localhost:8080/SupplierQuoteEngineService/SupplierQuoteEnginePort"/>
+    <wsdl:port name="SupplierBehaviorPort" binding="spr:SupplierBehaviorBinding">
+      <soap:address location="http://localhost:8080/SupplierQuoteEngineService/SupplierBehaviorPort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierTxnProcessor_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierTxnProcessor_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ESBBroker_SupplierTxnProcessor_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="SupplierTxnProcessor" targetNamespace="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="SupplierTxnProcessor" targetNamespace="http://www.pi4soa.org/ESBBroker/Supplier" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:spr="http://www.pi4soa.org/ESBBroker/Supplier">
   <wsdl:message name="confirmRequest">
     <wsdl:part name="content" element="orderConfirmed">
     </wsdl:part>
@@ -8,15 +8,15 @@
     <wsdl:part name="content" element="bookingReference">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="SupplierTxnProcessor">
+  <wsdl:portType name="SupplierBehavior">
     <wsdl:operation name="confirm">
-      <wsdl:input message="tns:confirmRequest">
+      <wsdl:input message="spr:confirmRequest">
     </wsdl:input>
-      <wsdl:output message="tns:confirmResponse">
+      <wsdl:output message="spr:confirmResponse">
     </wsdl:output>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="SupplierTxnProcessorBinding" type="tns:SupplierTxnProcessor">
+  <wsdl:binding name="SupplierBehaviorBinding" type="spr:SupplierBehavior">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="confirm">
       <soap:operation soapAction="" style="rpc"/>
@@ -29,8 +29,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="SupplierTxnProcessorService">
-    <wsdl:port name="SupplierTxnProcessorPort" binding="tns:SupplierTxnProcessorBinding">
-      <soap:address location="http://localhost:8080/SupplierTxnProcessorService/SupplierTxnProcessorPort"/>
+    <wsdl:port name="SupplierBehaviorPort" binding="spr:SupplierBehaviorBinding">
+      <soap:address location="http://localhost:8080/SupplierTxnProcessorService/SupplierBehaviorPort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_CreditCheckService_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_CreditCheckService_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_CreditCheckService_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="CreditCheckService" targetNamespace="http://creditagency.com/creditCheckService" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://creditagency.com/creditCheckService" xmlns:cred="http://creditagency.com/creditCheck" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="CreditCheckService" targetNamespace="http://creditagency.com/creditCheckService" xmlns:ca="http://creditagency.com/creditCheckService" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:cred="http://creditagency.com/creditCheck" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:message name="checkCreditRequest">
     <wsdl:part name="content" element="cred:creditCheckRequest">
     </wsdl:part>
@@ -10,13 +10,13 @@
   </wsdl:message>
   <wsdl:portType name="CreditCheckService">
     <wsdl:operation name="checkCredit">
-      <wsdl:input message="tns:checkCreditRequest">
+      <wsdl:input message="ca:checkCreditRequest">
     </wsdl:input>
-      <wsdl:output message="tns:checkCreditResponse">
+      <wsdl:output message="ca:checkCreditResponse">
     </wsdl:output>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="CreditCheckServiceBinding" type="tns:CreditCheckService">
+  <wsdl:binding name="CreditCheckServiceBinding" type="ca:CreditCheckService">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="checkCredit">
       <soap:operation soapAction="" style="rpc"/>
@@ -29,7 +29,7 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="CreditCheckServiceService">
-    <wsdl:port name="CreditCheckServicePort" binding="tns:CreditCheckServiceBinding">
+    <wsdl:port name="CreditCheckServicePort" binding="ca:CreditCheckServiceBinding">
       <soap:address location="http://localhost:8080/CreditCheckServiceService/CreditCheckServicePort"/>
     </wsdl:port>
   </wsdl:service>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_PolicyQuoteProcessService_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_PolicyQuoteProcessService_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PolicyQuote_PolicyQuoteProcessService_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="PolicyQuoteProcessService" targetNamespace="http://www.example.org/policyQuoteProcessService" xmlns:drv="http://dmv.com/drivingRecord" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.example.org/policyQuoteProcessService" xmlns:pol="http://www.example.org/policyQuote" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="PolicyQuoteProcessService" targetNamespace="http://www.example.org/policyQuoteProcessService" xmlns:drv="http://dmv.com/drivingRecord" xmlns:ca="http://creditagency.com/creditCheckService" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:pcs="http://www.example.org/policyQuoteCalculationService" xmlns:pes="http://www.example.org/policyQuoteEntityService" xmlns:pol="http://www.example.org/policyQuote" xmlns:pps="http://www.example.org/policyQuoteProcessService" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:dmv="http://dmv.com/drivingRecordService">
   <wsdl:message name="policyQuoteFaultFault">
     <wsdl:part name="content" element="pol:policyQuoteFault">
     </wsdl:part>
@@ -18,19 +18,21 @@
   </wsdl:message>
   <wsdl:portType name="PolicyQuoteProcessService">
     <wsdl:operation name="receivePolicyQuote">
-      <wsdl:input message="tns:receivePolicyQuoteRequest">
+      <wsdl:input message="pps:receivePolicyQuoteRequest">
     </wsdl:input>
-      <wsdl:output message="tns:receivePolicyQuoteResponse">
+      <wsdl:output message="pps:receivePolicyQuoteResponse">
     </wsdl:output>
-      <wsdl:fault name="policyQuoteFault" message="tns:policyQuoteFaultFault">
+      <wsdl:fault name="policyQuoteFault" message="pps:policyQuoteFaultFault">
     </wsdl:fault>
     </wsdl:operation>
+  </wsdl:portType>
+  <wsdl:portType name="DrivingRecordCallbackService">
     <wsdl:operation name="receiveDrivingRecord">
-      <wsdl:input message="tns:receiveDrivingRecordRequest">
+      <wsdl:input message="pps:receiveDrivingRecordRequest">
     </wsdl:input>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="PolicyQuoteProcessServiceBinding" type="tns:PolicyQuoteProcessService">
+  <wsdl:binding name="PolicyQuoteProcessServiceBinding" type="pps:PolicyQuoteProcessService">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="receivePolicyQuote">
       <soap:operation soapAction="" style="rpc"/>
@@ -44,6 +46,9 @@
         <soap:fault name="policyQuoteFault" use="literal" namespace="http://www.example.org/policyQuoteProcessService"/>
       </wsdl:fault>
     </wsdl:operation>
+  </wsdl:binding>
+  <wsdl:binding name="DrivingRecordCallbackServiceBinding" type="pps:DrivingRecordCallbackService">
+    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="receiveDrivingRecord">
       <soap:operation soapAction="" style="rpc"/>
       <wsdl:input>
@@ -52,8 +57,11 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="PolicyQuoteProcessServiceService">
-    <wsdl:port name="PolicyQuoteProcessServicePort" binding="tns:PolicyQuoteProcessServiceBinding">
+    <wsdl:port name="PolicyQuoteProcessServicePort" binding="pps:PolicyQuoteProcessServiceBinding">
       <soap:address location="http://localhost:8080/PolicyQuoteProcessServiceService/PolicyQuoteProcessServicePort"/>
     </wsdl:port>
+    <wsdl:port name="DrivingRecordCallbackServicePort" binding="pps:DrivingRecordCallbackServiceBinding">
+      <soap:address location="http://localhost:8080/PolicyQuoteProcessServiceService/DrivingRecordCallbackServicePort"/>
+    </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Buyer_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Buyer_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Buyer_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,8 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Buyer" targetNamespace="http://www.jboss.org/savara/examples" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.jboss.org/savara/examples" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Buyer" targetNamespace="http://www.jboss.org/savara/examples" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:sto="http://www.jboss.org/examples/store" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:service name="BuyerService">
-    <wsdl:port name="BuyerPort" binding="tns:BuyerBinding">
-      <soap:address location="http://localhost:8080/BuyerService/BuyerPort"/>
-    </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_CreditAgency_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_CreditAgency_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_CreditAgency_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="CreditAgency" targetNamespace="java:org.jboss.savara.examples.purchasing" xmlns:pur="java:org.jboss.savara.examples.purchasing" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="java:org.jboss.savara.examples.purchasing" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="CreditAgency" targetNamespace="java:org.jboss.savara.examples.purchasing" xmlns:pur="java:org.jboss.savara.examples.purchasing" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:message name="checkCreditRequest">
     <wsdl:part name="content" type="pur:CreditCheckRequest">
     </wsdl:part>
@@ -12,7 +12,7 @@
     <wsdl:part name="content" type="pur:CreditCheckOk">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="CreditAgency">
+  <wsdl:portType name="CreditAgencyInterface">
     <wsdl:operation name="checkCredit">
       <wsdl:input message="pur:checkCreditRequest">
     </wsdl:input>
@@ -22,7 +22,7 @@
     </wsdl:fault>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="CreditAgencyBinding" type="pur:CreditAgency">
+  <wsdl:binding name="CreditAgencyInterfaceBinding" type="pur:CreditAgencyInterface">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="checkCredit">
       <soap:operation soapAction="" style="rpc"/>
@@ -38,8 +38,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="CreditAgencyService">
-    <wsdl:port name="CreditAgencyPort" binding="pur:CreditAgencyBinding">
-      <soap:address location="http://localhost:8080/CreditAgencyService/CreditAgencyPort"/>
+    <wsdl:port name="CreditAgencyInterfacePort" binding="pur:CreditAgencyInterfaceBinding">
+      <soap:address location="http://localhost:8080/CreditAgencyService/CreditAgencyInterfacePort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Store_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Store_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/PurchaseGoods_Store_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,28 +1,28 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Store" targetNamespace="http://www.jboss.org/examples/store" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.jboss.org/examples/store" xmlns:sto="http://www.jboss.org/examples/store" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Store" targetNamespace="http://www.jboss.org/examples/store" xmlns:pur="java:org.jboss.savara.examples.purchasing" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:sto="http://www.jboss.org/examples/store" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:message name="BuyFailedFault">
-    <wsdl:part name="content" type="tns:BuyFailed">
+    <wsdl:part name="content" type="sto:BuyFailed">
     </wsdl:part>
   </wsdl:message>
   <wsdl:message name="buyRequest">
-    <wsdl:part name="content" type="tns:BuyRequest">
+    <wsdl:part name="content" type="sto:BuyRequest">
     </wsdl:part>
   </wsdl:message>
   <wsdl:message name="buyResponse">
-    <wsdl:part name="content" type="tns:BuyConfirmed">
+    <wsdl:part name="content" type="sto:BuyConfirmed">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="Store">
+  <wsdl:portType name="StoreInterface">
     <wsdl:operation name="buy">
-      <wsdl:input message="tns:buyRequest">
+      <wsdl:input message="sto:buyRequest">
     </wsdl:input>
-      <wsdl:output message="tns:buyResponse">
+      <wsdl:output message="sto:buyResponse">
     </wsdl:output>
-      <wsdl:fault name="BuyFailed" message="tns:BuyFailedFault">
+      <wsdl:fault name="BuyFailed" message="sto:BuyFailedFault">
     </wsdl:fault>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="StoreBinding" type="tns:Store">
+  <wsdl:binding name="StoreInterfaceBinding" type="sto:StoreInterface">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="buy">
       <soap:operation soapAction="" style="rpc"/>
@@ -38,8 +38,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="StoreService">
-    <wsdl:port name="StorePort" binding="tns:StoreBinding">
-      <soap:address location="http://localhost:8080/StoreService/StorePort"/>
+    <wsdl:port name="StoreInterfacePort" binding="sto:StoreInterfaceBinding">
+      <soap:address location="http://localhost:8080/StoreService/StoreInterfacePort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Buyer_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Buyer_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Buyer_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,8 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Buyer" targetNamespace="http://www.pi4soa.org/ReqRespFault/Buyer" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ReqRespFault/Buyer" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Buyer" targetNamespace="http://www.pi4soa.org/ReqRespFault/Buyer" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:slr="http://www.pi4soa.org/ReqRespFault/Seller" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:service name="BuyerService">
-    <wsdl:port name="BuyerPort" binding="tns:BuyerBinding">
-      <soap:address location="http://localhost:8080/BuyerService/BuyerPort"/>
-    </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>

Modified: branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Seller_rpc_0.wsdl
===================================================================
--- branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Seller_rpc_0.wsdl	2011-02-16 21:16:53 UTC (rev 679)
+++ branches/experimental/2.0.x/bundles/org.savara.wsdl/src/test/resources/results/wsdl/ReqRespFault_Seller_rpc_0.wsdl	2011-02-17 16:44:18 UTC (rev 680)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="Seller" targetNamespace="http://www.pi4soa.org/ReqRespFault/Seller" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.pi4soa.org/ReqRespFault/Seller" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+<wsdl:definitions name="Seller" targetNamespace="http://www.pi4soa.org/ReqRespFault/Seller" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:slr="http://www.pi4soa.org/ReqRespFault/Seller" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
   <wsdl:message name="checkCreditRequest">
     <wsdl:part name="content" element="CreditCheckRequest">
     </wsdl:part>
@@ -12,17 +12,17 @@
     <wsdl:part name="content" element="CreditCheckInvalid">
     </wsdl:part>
   </wsdl:message>
-  <wsdl:portType name="Seller">
+  <wsdl:portType name="SellerBehavior">
     <wsdl:operation name="checkCredit">
-      <wsdl:input message="tns:checkCreditRequest">
+      <wsdl:input message="slr:checkCreditRequest">
     </wsdl:input>
-      <wsdl:output message="tns:checkCreditResponse">
+      <wsdl:output message="slr:checkCreditResponse">
     </wsdl:output>
-      <wsdl:fault name="insufficientCredit" message="tns:insufficientCreditFault">
+      <wsdl:fault name="insufficientCredit" message="slr:insufficientCreditFault">
     </wsdl:fault>
     </wsdl:operation>
   </wsdl:portType>
-  <wsdl:binding name="SellerBinding" type="tns:Seller">
+  <wsdl:binding name="SellerBehaviorBinding" type="slr:SellerBehavior">
     <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <wsdl:operation name="checkCredit">
       <soap:operation soapAction="" style="rpc"/>
@@ -38,8 +38,8 @@
     </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="SellerService">
-    <wsdl:port name="SellerPort" binding="tns:SellerBinding">
-      <soap:address location="http://localhost:8080/SellerService/SellerPort"/>
+    <wsdl:port name="SellerBehaviorPort" binding="slr:SellerBehaviorBinding">
+      <soap:address location="http://localhost:8080/SellerService/SellerBehaviorPort"/>
     </wsdl:port>
   </wsdl:service>
 </wsdl:definitions>



More information about the savara-commits mailing list