Hello,
here is what I got: installed and configured SOA Suite 11g, (weblogic server 10.3, repository creation utility, soa suite, jdeveloper studio, Oracle XE database 10g).
SOA infrastructure
Service engines (BPEL, Mediator, Business rules, Himan workflow
Metadastore (MDS)
Enterprise manager, web service manager, B2B, Adapterframework (JCA)
Oracle Business Activity monitoring (BAM)
All set up and running. tutorial project Purchase Order Processing set up and running as well (its' from book "Getting started with Oracle SOA suite 11g R1 A hands on tutorial").
Tests are executing fine, all passed (several types of credit cards, small, medium and large orders, automatic and manual approval, several types on shipping automatically chosen on size of order etc.)

What I want now is to connect - consume - that service from palin JAVA application.
Following this tutorial (http://theopentutorials.com/examples/java-ee/jax-ws/create-and-consume-web-service-using-jax-ws/)
I managed use JAX-WS tool called ‘wsimport’ for generating the artifacts required for creating and consuming a web service.
‘wsimport’ takes a wsdl file as input.
It compiled well besides one warning for what I think is not critical (or maybe it is?)
C:\Users\Nenad\eclipseJunoSESR2\GettingStartedWithEclipseJuno\SOAConsume02>wsimport -s src -d bin ht tp://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL
parsing WSDL...
[WARNING] R2716 WSI-BasicProfile ver. 1.0, namespace attribute not allowed in doc/lit for soapbind:body: "execute"
line 31 of http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL
generating code...
compiling code...
C:\Users\Nenad\eclipseJunoSESR2\GettingStartedWithEclipseJuno\SOAConsume02>
So the classes are there:

And now I am stuck, because I have no idea how to send "order" i.e. how to populate input arguments:
request PurchaseOrderType
* CustID string Value
* ID string Value
productName string
itemType string
price decimal
quantity decimal
status string
ccType string
ccNumber
In eclipse I created SOAClient class such as:
package com.oracle.client;
import java.math.BigDecimal;
import com.oracle.sca.soapservice.poprocessing.poprocessing.receivepo.ReceivePO;
import com.oracle.xmlns.ns.order.PurchaseOrderType;
public class SOAClient {
public static void main(String[] args) {
ReceivePO receivePO = new ReceivePO();
PurchaseOrderType pot = new PurchaseOrderType();
pot.setCustID("1111");
pot.setID("2121");
pot.setProductName("Bluetooth Headset");
pot.setItemType("Electronics");
BigDecimal bd_p = new BigDecimal("49.99");
pot.setPrice(bd_p);
BigDecimal bd_q = new BigDecimal("1000");
pot.setQuantity(bd_q);
pot.setStatus("initial");
pot.setCcType("Mastercard");
pot.setCcNumber("8765-8765-8765-8765");
}
}
auto generated class ExecutePtt looks like:
package com.oracle.sca.soapservice.poprocessing.poprocessing.receivepo;
import javax.jws.Oneway;
import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
import javax.xml.bind.annotation.XmlSeeAlso;
import com.oracle.xmlns.ns.order.ObjectFactory;
import com.oracle.xmlns.ns.order.PurchaseOrderType;
/**
* This class was generated by the JAX-WS RI.
* JAX-WS RI 2.1.6 in JDK 6
* Generated source version: 2.1
*
*/
@WebService(name = "execute_ptt", targetNamespace = "http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO")
@SOAPBinding(parameterStyle = SOAPBinding.ParameterStyle.BARE)
@XmlSeeAlso({
_ObjectFactory.class_
})
public interface ExecutePtt {
_/\*\*_
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) request_
_\*/_
_@WebMethod(action = "execute")_
_@Oneway_
_public void execute(_
_@WebParam(name = "PurchaseOrder", targetNamespace = "[http://xmlns.oracle.com/ns/order](http://xmlns.oracle.com/ns/order)", partName = "request")_
_PurchaseOrderType request);_
}
ReceivePO class is:
package com.oracle.sca.soapservice.poprocessing.poprocessing.receivepo;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.logging.Logger;
import javax.xml.namespace.QName;
import javax.xml.ws.Service;
import javax.xml.ws.WebEndpoint;
import javax.xml.ws.WebServiceClient;
import javax.xml.ws.WebServiceFeature;
/**
* This class was generated by the JAX-WS RI.
* JAX-WS RI 2.1.6 in JDK 6
* Generated source version: 2.1
*
*/
@WebServiceClient(name = "receivePO", targetNamespace = "http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO", wsdlLocation = "http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL")
public class ReceivePO
_extends Service_
{
_private final static URL RECEIVEPO\_WSDL\_LOCATION;_
_private final static Logger logger = Logger.getLogger(com.oracle.sca.soapservice.poprocessing.poprocessing.receivepo.ReceivePO.class.getName());_
_static {_
_URL url = null;_
_try {_
_URL baseUrl;_
_baseUrl = com.oracle.sca.soapservice.poprocessing.poprocessing.receivepo.ReceivePO.class.getResource(".");_
_url = new URL(baseUrl, "[http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL](http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL)");_
_} catch (MalformedURLException e) {_
_logger.warning("Failed to create URL for the wsdl Location: '[http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL](http://i3770k.mshome.net:8001/soa-infra/services/default/POProcessing/receivePO?WSDL)', retrying as a local file");_
_logger.warning(e.getMessage());_
_}_
_RECEIVEPO\_WSDL\_LOCATION = url;_
_}_
_public ReceivePO(URL wsdlLocation, QName serviceName) {_
_super(wsdlLocation, serviceName);_
_}_
_public ReceivePO() {_
_super(RECEIVEPO\_WSDL\_LOCATION, new QName("[http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO](http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO)", "receivePO"));_
_}_
_/\*\*_
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* returns ExecutePtt_
_\*/_
_@WebEndpoint(name = "execute\_pt")_
_public ExecutePtt getExecutePt() {_
_return super.getPort(new QName("[http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO](http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO)", "execute\_pt"), ExecutePtt.class);_
_}_
_/\*\*_
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) features_
_\* A list of {@link javax.xml.ws.WebServiceFeature} to configure on the proxy. Supported features not in the \<code>features\</code> parameter will have their default values._
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* returns ExecutePtt_
_\*/_
_@WebEndpoint(name = "execute\_pt")_
_public ExecutePtt getExecutePt(WebServiceFeature... features) {_
_return super.getPort(new QName("[http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO](http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO)", "execute\_pt"), ExecutePtt.class, features);_
_}_
}
ObjectFactory class is:
package com.oracle.xmlns.ns.order;
import javax.xml.bind.JAXBElement;
import javax.xml.bind.annotation.XmlElementDecl;
import javax.xml.bind.annotation.XmlRegistry;
import javax.xml.namespace.QName;
/**
* This object contains factory methods for each
* Java content interface and Java element interface
* generated in the com.oracle.xmlns.ns.order package.
* <p>An ObjectFactory allows you to programatically
* construct new instances of the Java representation
* for XML content. The Java representation of XML
* content can consist of schema derived interfaces
* and classes representing the binding of schema
* type definitions, element declarations and model
* groups. Factory methods for each of these are
* provided in this class.
*
*/
@XmlRegistry
public class ObjectFactory {
_private final static QName \_PurchaseOrder\_QNAME = new QName("[http://xmlns.oracle.com/ns/order](http://xmlns.oracle.com/ns/order)", "PurchaseOrder");_
_/\*\*_
_\* Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: com.oracle.xmlns.ns.order_
_\*_
_\*/_
_public ObjectFactory() {_
_}_
/**
_\* Create an instance of {@link PurchaseOrderType }_
_\*_
_\*/_
_public PurchaseOrderType createPurchaseOrderType() {_
_return new PurchaseOrderType();_
_}_
_/\*\*_
_\* Create an instance of {@link JAXBElement }{@code \<}{@link PurchaseOrderType }{@code >}}_
_\*_
_\*/_
_@XmlElementDecl(namespace = "[http://xmlns.oracle.com/ns/order](http://xmlns.oracle.com/ns/order)", name = "PurchaseOrder")_
_public JAXBElement\<PurchaseOrderType> createPurchaseOrder(PurchaseOrderType value) {_
_return new JAXBElement\<PurchaseOrderType>(\_PurchaseOrder\_QNAME, PurchaseOrderType.class, null, value);_
_}_
}
package-info is
@javax.xml.bind.annotation.XmlSchema(namespace = "http://xmlns.oracle.com/ns/order", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
package com.oracle.xmlns.ns.order;
and
PurchaseOrderType class is
package com.oracle.xmlns.ns.order;
import java.math.BigDecimal;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
/**
* <p>Java class for PurchaseOrderType complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType name="PurchaseOrderType">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="CustID" type="{http://www.w3.org/2001/XMLSchema}string"/>
* <element name="ID" type="{http://www.w3.org/2001/XMLSchema}string"/>
* <element name="productName" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="itemType" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="price" type="{http://www.w3.org/2001/XMLSchema}decimal" minOccurs="0"/>
* <element name="quantity" type="{http://www.w3.org/2001/XMLSchema}decimal" minOccurs="0"/>
* <element name="status" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="ccType" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="ccNumber" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "PurchaseOrderType", propOrder = {
_"custID",_
_"id",_
_"productName",_
_"itemType",_
_"price",_
_"quantity",_
_"status",_
_"ccType",_
_"ccNumber"_
})
public class PurchaseOrderType {
_@XmlElement(name = "CustID", required = true)_
_protected String custID;_
_@XmlElement(name = "ID", required = true)_
_protected String id;_
_protected String productName;_
_protected String itemType;_
_protected BigDecimal price;_
_protected BigDecimal quantity;_
_protected String status;_
_protected String ccType;_
_protected String ccNumber;_
/\*\*
_\* Gets the value of the custID property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getCustID() {_
_return custID;_
_}_
_/\*\*_
_\* Sets the value of the custID property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setCustID(String value) {_
_this.custID = value;_
_}_
_/\*\*_
_\* Gets the value of the id property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getID() {_
_return id;_
_}_
_/\*\*_
_\* Sets the value of the id property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setID(String value) {_
_this.id = value;_
_}_
_/\*\*_
_\* Gets the value of the productName property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getProductName() {_
_return productName;_
_}_
_/\*\*_
_\* Sets the value of the productName property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setProductName(String value) {_
_this.productName = value;_
_}_
_/\*\*_
_\* Gets the value of the itemType property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getItemType() {_
_return itemType;_
_}_
_/\*\*_
_\* Sets the value of the itemType property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setItemType(String value) {_
_this.itemType = value;_
_}_
_/\*\*_
_\* Gets the value of the price property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link BigDecimal }_
_\*_
_\*/_
_public BigDecimal getPrice() {_
_return price;_
_}_
_/\*\*_
_\* Sets the value of the price property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link BigDecimal }_
_\*_
_\*/_
_public void setPrice(BigDecimal value) {_
_this.price = value;_
_}_
/**
_\* Gets the value of the quantity property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link BigDecimal }_
_\*_
_\*/_
_public BigDecimal getQuantity() {_
_return quantity;_
_}_
_/\*\*_
_\* Sets the value of the quantity property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link BigDecimal }_
_\*_
_\*/_
_public void setQuantity(BigDecimal value) {_
_this.quantity = value;_
_}_
_/\*\*_
_\* Gets the value of the status property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getStatus() {_
_return status;_
_}_
_/\*\*_
_\* Sets the value of the status property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setStatus(String value) {_
_this.status = value;_
_}_
_/\*\*_
_\* Gets the value of the ccType property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getCcType() {_
_return ccType;_
_}_
_/\*\*_
_\* Sets the value of the ccType property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setCcType(String value) {_
_this.ccType = value;_
_}_
_/\*\*_
_\* Gets the value of the ccNumber property._
_\*_
_\* [@return](https://forums.oracle.com/ords/apexds/user/return)_
_\* possible object is_
_\* {@link String }_
_\*_
_\*/_
_public String getCcNumber() {_
_return ccNumber;_
_}_
_/\*\*_
_\* Sets the value of the ccNumber property._
_\*_
_\* [@param](https://forums.oracle.com/ords/apexds/user/param) value_
_\* allowed object is_
_\* {@link String }_
_\*_
_\*/_
_public void setCcNumber(String value) {_
_this.ccNumber = value;_
_}_
}
Therefore my questions are:
1. What should I add in my class SOAClient to make this work (set the parameters and execute test - place order)
2. Should I use JAX-WS at all? I ask because i saw some tutorials without it but i haven't still studied them.
Thank you very much for any idea, suggestion or giving me right direction.