Recommended steps to generate a web service using nested complex types

Hello,
I need to generate a web service that uses nested complex types with built in types on the bottom layer. I hve posted an attempt at a WSDL. Please give advice on if I am doing it correctly.
I have the suspicion that I should nest the complex types into the final complex type VendorStockingInterface. Please confirm.
<?xml version="1.0" encoding="utf-8"?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:conv="http://www.openuri.org/2002/04/soap/conversation/"
xmlns:cw="http://www.openuri.org/2002/04/wsdl/conversation/"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:jms="http://www.openuri.org/2002/04/wsdl/jms/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:s0="http://www.openuri.org/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
targetNamespace="http://www.openuri.org/">
<types>
<s:schema targetNamespace="http://www.openuri.org/"
xmlns:s="http://www.w3.org/2001/XMLSchema">
<s:element name="RegisterServiceRequest">
<s:complexType>
<s:sequence>
<s:element name="DeviceCapabilities">
<s:complexType>
<s:sequence>
<s:element name="OSName" type="s:string" nillable="true"/>
     <s:element name="OSVersion" type="s:string" nillable="true"/>
     <s:element name="BRType" type="s:string" nillable="true"/>
     <s:element name="DisplayColors" type="s:string" nillable="true"/>
     <s:element name="DisplayTechnology" type="s:string" nillable="true"/>
     <s:element name="NetworkAccess" type="s:boolean" nillable="true"/>
     <s:element name="DownloadMethod" type="s:string" nillable="true"/>
     <s:element name="DownloadVersion" type="s:string" nillable="true"/>
     <s:element name="Protocols" type="s:string" nillable="true"/>
     </s:sequence>
</s:complexType>
</s:element>
     <s:element name="LicenseType">
<s:complexType>
<s:sequence>
     <s:element name="Licences" type="s:string" nillable="false"/>
</s:sequence>
</s:complexType>
</s:element>
     <s:element name="PriceValue">
<s:complexType>
<s:sequence>
     <s:element name="Value" type="s:float" nillable="false"/>
     <s:element name="CurrencyType" type="s:string" nillable="false"/>
</s:sequence>
</s:complexType>
</s:element>
     <s:element name="RevenueModelType">
<s:complexType>
<s:sequence>
     <s:element name="VSRP" type="RegisterServiceRequest:PriceValue" nillable="true"/>
     <s:element name="WholesalePrice" type="RegisterServiceRequest:PriceValue" nillable="true"/>
     <s:element name="VendorSplitPercentage" type="s:float" nillable="true"/>
     <s:element name="VendorPurchasePrice" type="RegisterServiceRequest:PriceValue" nillable="true"/>
     <s:element name="License" type="RegisterServiceRequest:LicenseType" nillable="false"/>
</s:sequence>
</s:complexType>
</s:element>
     <s:element name="VendorItemIdentifierType">
<s:complexType>
<s:sequence>
     <s:element name="VendorProductDisplay" type="s:string" nillable="false"/>
     <s:element name="VendorProductVersion" type="s:string" nillable="false"/>
     <s:element name="VendorProductCode" type="s:string" nillable="false"/>
</s:sequence>
</s:complexType>
</s:element>     
     <s:element name="VendorBriefType">
<s:complexType>
<s:sequence>
     <s:element name="VendorID" type="s:string" nillable="false"/>
</s:sequence>
</s:complexType>
</s:element>     
     <s:element name="VendorItemBriefType">
<s:complexType>
<s:sequence>
     <s:element name="VendorProductID" type="RegisterServiceRequest:VendorItemIdentifierType" nillable="false"/>
     <s:element name="VendorID" type="RegisterServiceRequest:VendorBriefType" nillable="false"/>
     <s:element name="VendorDescription" type="s:string" nillable="true"/>
     <s:element name="VendorPricing" type="RegisterServiceRequest:RevenueModelType" nillable="false"/>
     <s:element name="DownloadURL" type="s:string" nillable="true"/>
     <s:element name="ShortCode" type="s:string" nillable="true"/>
     <s:element name="ApplicationCode" type="s:string" nillable="true"/>
     <s:element name="DRMMethod" type="s:string" nillable="true"/>
</s:sequence>
</s:complexType>
</s:element>     
     <s:element name="ContentType">
<s:complexType>
<s:sequence>
     <s:element name="Categorization" type="s:string" nillable="false"/>
     <s:element name="MIMEType" type="s:string" nillable="true"/>
</s:sequence>
</s:complexType>
</s:element>     
     <s:element name="VendorStockingInterface">
<s:complexType>
<s:sequence>
     <s:element name="VendorItemInfo" type="RegisterServiceRequest:VendorItemBriefType" nillable="false"/>
     <s:element name="ProductType" type="RegisterServiceRequest:ContentType" nillable="false"/>
     <s:element name="DeviceRequirements" type="RegisterServiceRequest:DeviceCapabilitiesType" nillable="true"/>
     <s:element name="VendorPricing" type="RegisterServiceRequest:RevenueModelType" nillable="false"/>
     <s:element name="ProgramMemory" type="s:int" nillable="true"/>
     <s:element name="DataMemory" type="s:int" nillable="true"/>
     <s:element name="Author" type="s:string" nillable="true"/>
     <s:element name="Language" type="s:string" nillable="true"/>
</s:sequence>
</s:complexType>
</s:element>          
<s:element name="RegisterServiceResponse">
<s:complexType>
<s:sequence>
<s:element name="Message" type="s:string"/>
</s:sequence>
</s:complexType>
</s:element>
</s:sequence>
</s:complexType>
</s:element>
</s:schema>
</types>
<message name="RegisterServiceSoapIn">
<part name="parameters" element="s0:RegisterServiceRequest"/>
</message>
<message name="RegisterServiceSoapOut">
<part name="parameters" element="s0:RegisterServiceResponse"/>
</message>
<portType name="RegisterServiceSoap">
<operation name="RegisterService">
<input message="s0:RegisterServiceSoapIn"/>
<output message="s0:RegisterServiceSoapOut"/>
</operation>
</portType>
<binding name="RegisterServiceSoap" type="s0:RegisterServiceSoap">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
<operation name="RegisterService">
<soap:operation soapAction="http://www.openuri.org/RegisterService" style="document"/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
</binding>
<service name="RegisterService">
<port name="RegisterServiceSoap" binding="s0:RegisterServiceSoap">
<soap:address location="http://localhost:7001/RegisterService.jws"/>
</port>
</service>
</definitions>
I'd like the the consumer of the web service to send it a document with the fields formatted to the VendorInterface complextype which contains the other complextypes. In return the consumer will get another document with some acknowledgement messages.
To make this happen I'd like to generate the web service, creating the complex type classes and XMLBeans. I'd like advice on the steps to take once I get a good WSDL.
There is also the option to go from the other direction. Is it better to attempt to create a schema XSD document instead and use that to work towards the web service and WSDL? If so, could someone give an example of how to format an XSD using my example needs.

I think I have got it all in place, though I have not tested it as of yet. For others who are looking at this, here is my XSD file from which all my complextypes were generated and lastly here is the actual web service file.
?xml version="1.0"?>
<xs:schema targetNamespace="http://openuri.org/RegisterService"
xmlns:rs="http://openuri.org/RegisterService"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
xmlns:tns="http://temp.openuri.org/VerizonBOBO/RegisterServiceRequestDocument.xsd">
<xs:element name="RegisterServiceRequest" type="rs:VendorStockingInterface"/>
<xs:complexType name="DeviceCapabilitiesType">
<xs:sequence>
<xs:element name="OSName" type="xs:string" nillable="true"/>
<xs:element name="OSVersion" type="xs:string" nillable="true"/>
<xs:element name="BRType" type="xs:string" nillable="true"/>
<xs:element name="DisplayColors" type="xs:string" nillable="true"/>
<xs:element name="DisplayTechnology" type="xs:string" nillable="true"/>
<xs:element name="NetworkAccess" type="xs:boolean" nillable="true"/>
<xs:element name="DownloadMethod" type="xs:string" nillable="true"/>
<xs:element name="DownloadVersion" type="xs:string" nillable="true"/>
<xs:element name="Protocols" type="xs:string" nillable="true"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="LicenseType">
<xs:sequence>     
<xs:element name="Licences" type="xs:string" nillable="false"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="PriceValue">
<xs:sequence>
<xs:element name="Value" type="xs:float" nillable="false"/>
<xs:element name="CurrencyType" type="xs:string" nillable="false"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="RevenueModelType">
<xs:sequence>
<xs:element name="VSRP" type="rs:PriceValue" nillable="true"/>
<xs:element name="WholesalePrice" type="rs:PriceValue" nillable="true"/>
<xs:element name="VendorSplitPercentage" type="xs:float" nillable="true"/>
<xs:element name="VendorPurchasePrice" type="rs:PriceValue" nillable="true"/>
<xs:element name="License" type="rs:LicenseType" nillable="false"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="VendorItemIdentifierType">
<xs:sequence>
<xs:element name="VendorProductDisplay" type="xs:string" nillable="false"/>
<xs:element name="VendorProductVersion" type="xs:string" nillable="false"/>
<xs:element name="VendorProductCode" type="xs:string" nillable="false"/>
     </xs:sequence>
</xs:complexType>
<xs:complexType name="VendorBriefType">
<xs:sequence>
<xs:element name="VendorID" type="xs:string" nillable="false"/>
     </xs:sequence>
</xs:complexType>
<xs:complexType name="VendorItemBriefType">
<xs:sequence>
<xs:element name="VendorProductID" type="rs:VendorItemIdentifierType" nillable="false"/>
<xs:element name="VendorID" type="rs:VendorBriefType" nillable="false"/>
<xs:element name="VendorDescription" type="xs:string" nillable="true"/>
<xs:element name="VendorPricing" type="rs:RevenueModelType" nillable="false"/>
<xs:element name="DownloadURL" type="xs:string" nillable="true"/>
<xs:element name="ShortCode" type="xs:string" nillable="true"/>
<xs:element name="ApplicationCode" type="xs:string" nillable="true"/>
<xs:element name="DRMMethod" type="xs:string" nillable="true"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ContentType">
<xs:sequence>
<xs:element name="Categorization" type="xs:string"/>
<xs:element name="MIMEType" type="xs:string"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="VendorStockingInterface">
<xs:sequence>
<xs:element name="VendorItemInfo" type="rs:VendorItemBriefType"/>
<xs:element name="ProductType" type="rs:ContentType"/>
<xs:element name="DeviceRequirements" type="rs:DeviceCapabilitiesType"/>
<xs:element name="VendorPricing" type="rs:RevenueModelType"/>
<xs:element name="ProgramMemory" type="xs:int"/>
<xs:element name="DataMemory" type="xs:int"/>
<xs:element name="Author" type="xs:string"/>
<xs:element name="Language" type="xs:string"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="RegisterServiceResponse">
<xs:sequence>
<xs:element name="Message" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
The Web Service File:
import org.openuri.registerService.RegisterServiceResponse;
import org.openuri.registerService.RegisterServiceRequestDocument;
import com.verizon.hp.registerservice.*;
public class RegisterService implements com.bea.jws.WebService
static final long serialVersionUID = 1L;
* @common:operation
* @jws:protocol form-post="false" form-get="false"
public org.openuri.registerService.RegisterServiceResponse RegisterService(org.openuri.registerService.RegisterServiceRequestDocument RegisterServiceDoc)
VendorStockingInterface vsInterface = (VendorStockingInterface)RegisterServiceDoc.getRegisterServiceRequest();
System.out.println(vsInterface.toString());
com.verizon.hp.registerservice.RegisterServiceResponse serviceResponse = new com.verizon.hp.registerservice.RegisterServiceResponse();
serviceResponse.setMessage("Register New Service Message has been received successfully");
org.openuri.registerService.RegisterServiceResponse response = (org.openuri.registerService.RegisterServiceResponse)serviceResponse;
return response;
}

Similar Messages

  • Web Services and Nested Complex Types

    I am having troubles trying to get coldfusion to use a web
    service function.
    I know that the web service works as I am sending another
    function in a simple variable and receiving a simple variable. I
    know the function exists as I when I dump the object the function
    is there and I have been told by who supplies it that it works in
    other languages.
    The problem I am having is that when I call the function I
    get the following error: Web service operation "[function name]"
    with parameters [parameters] could not be found. I am lead to
    believe that it may have to do with the fact that one of the
    parameters is a complex type with nested complex types, because of
    the amount of trouble it took to get nested complex types to
    (apparently) work.
    Has anyone had this problem before and/or know how to fix
    it?

    You can invoke methods which take complextypes as parameters.
    The idea is to create first a structure which represents the
    complextype. For example; crit = structNew(), crit.paramname1 =
    value1, ctir.paramname2 = value2. After this, you just pass the
    structure
    crit as a parameter value, for example with
    <cfinvokeargument>.
    Always check the wsdl and the possible documentation
    carefully. You'll get always an error if the types of the
    parameters passed didn't match exactly to what was expected.
    Handling complextype responses is also possible, but not very
    elegant with ColdFusion.
    For example, you have <cfinvoke
    returnvariable="wsResult"... >, and you get a java object as a
    response which you can really do nothing about with CF functions,
    you must use Java Reflection API to extract the values.
    <cfset oFields =
    wsresult.getClass().getDeclaredFields()>
    <cfoutput>
    <cfloop from="1" to="#arraylen(oFields)#" index="fi">
    <cfset field = oFields[fi].getName()>
    <cfif isdefined("wsresult." & field) AND field NEQ
    "typedesc">
    #field# = #wsResult[field]#<br>
    </cfif>
    </cfloop>
    </cfoutput>
    The above is just an example, and It might work with only
    some types of complextype responses. But it's a start. :)
    http://www.mail-archive.com/[email protected]/msg00553.html
    is also another example about handling complextype responses. It
    plays "safer", not relying that CF can extract values without
    "getters" automatically, and is more of a complete solution.

  • Generating a Web Service and Oracle DATE type

    Hi,
    I need to generate a Web Service from an EJB model based upon entities generated from the Oracle 11g database that contain DATE types.
    I realize that java.sql.Date may not be a supported JAX-RPC type but I would be VERY grateful for some instructions about the easiest way to solve this problem when generating the web service in JDeveloper 11g.
    The integrated WLS server log looks like this:
    <2009-apr-26 kl 23:13 CEST> <Error> <HTTP> <BEA-101216> <Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/SessionFacadeBean".
    javax.xml.ws.WebServiceException: Unable to create JAXBContext
         at com.sun.xml.ws.model.AbstractSEIModelImpl.createJAXBContext(AbstractSEIModelImpl.java:158)
         at com.sun.xml.ws.model.AbstractSEIModelImpl.postProcess(AbstractSEIModelImpl.java:87)
         at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:264)
         at com.sun.xml.ws.server.EndpointFactory.createSEIModel(EndpointFactory.java:322)
         at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:188)
         Truncated. see log file for complete stacktrace
    java.security.PrivilegedActionException: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
    java.sql.Timestamp does not have a no-arg default constructor.
         this problem is related to the following location:
              at java.sql.Timestamp
              at public java.sql.Timestamp oracle.Lan.getAterlamnadDatum()
              at oracle.Lan
              at public java.util.List ejbmodel.jaxws.QueryLanFindByNrResponse._return
              at ejbmodel.jaxws.QueryLanFindByNrResponse
    ..... and so on
    The entity bean i question looks like this:
    package oracle;
    import java.io.Serializable;
    import java.sql.Timestamp;
    import javax.persistence.Column;
    import javax.persistence.Entity;
    import javax.persistence.Id;
    import javax.persistence.JoinColumn;
    import javax.persistence.ManyToOne;
    import javax.persistence.NamedQueries;
    import javax.persistence.NamedQuery;
    @Entity
    @NamedQueries({
    @NamedQuery(name = "Lan.findAll", query = "select o from Lan o"),
    @NamedQuery(name = "Lan.FindByNr", query = "select o from Lan o where o.lanNr = :p_lanNr")
    public class Lan implements Serializable {
    @Column(name="ATERLAMNAD_DATUM")
    private Timestamp aterlamnadDatum;
    @Column(nullable = false)
    private Long demandcount;
    private Timestamp demanddate;
    @Column(name="EXEMPLAR_NR", nullable = false)
    private Long exemplarNr;
    @Column(nullable = false)
    private String isbn;
    @Id
    @Column(name="LAN_NR", nullable = false)
    private Long lanNr;
    @Column(nullable = false)
    private Long remindercount;
    private Timestamp reminderdate;
    @Column(name="TILLBAKA_DATUM")
    private Timestamp tillbakaDatum;
    @Column(name="UTLANAD_DATUM")
    private Timestamp utlanadDatum;
    @ManyToOne
    @JoinColumn(name = "PERSON_NR")
    private Lantagare lantagare;

    Hi All,
    When i'm developing EJB Webservice i am getting following error .. i think it doesn't support java.sql.Date; and java.sql.timestamp; types
    the error are as show in below please suggest me.
    [Running application oil on Server Instance IntegratedWebLogicServer...]
    [05:04:09 AM] ---- Deployment started. ----
    [05:04:09 AM] Target platform is (Weblogic 10.3).
    [05:04:09 AM] Retrieving existing application information
    [05:04:09 AM] Running dependency analysis...
    [05:04:09 AM] Deploying 2 profiles...
    [05:04:10 AM] Wrote EJB Module to C:\Documents and Settings\Administrator\Application Data\JDeveloper\system11.1.1.4.37.59.23\o.j2ee\drs\oil\oil_webservicesEJB.jar
    [05:04:10 AM] Wrote Enterprise Application Module to C:\Documents and Settings\Administrator\Application Data\JDeveloper\system11.1.1.4.37.59.23\o.j2ee\drs\oil
    [05:04:10 AM] Redeploying Application...
    <Jun 30, 2011 5:04:10 AM EDT> <Warning> <J2EE> <BEA-160195> <The application version lifecycle event listener oracle.security.jps.wls.listeners.JpsAppVersionLifecycleListener is ignored because the application oil is not versioned.>
    <Jun 30, 2011 5:04:10 AM EDT> <Warning> <Munger> <BEA-2156203> <A version attribute was not found in element webservices in the deployment descriptor in C:\Documents and Settings\Administrator\Application Data\JDeveloper\system11.1.1.4.37.59.23\o.j2ee\drs\oil\oil_webservicesEJB.jar/META-INF/webservices.xml. A version attribute is required, but this version of the Weblogic Server will assume that the JEE5 is used. Future versions of the Weblogic Server will reject descriptors that do not specify the JEE version.>
    <Jun 30, 2011 5:04:10 AM EDT> <Error> <HTTP> <BEA-101216> <Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/oil-oil_webservices-webapp".
    javax.xml.ws.WebServiceException: Unable to create JAXBContext
         at com.sun.xml.ws.model.AbstractSEIModelImpl.createJAXBContext(AbstractSEIModelImpl.java:164)
         at com.sun.xml.ws.model.AbstractSEIModelImpl.postProcess(AbstractSEIModelImpl.java:94)
         at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:281)
         at com.sun.xml.ws.server.EndpointFactory.createSEIModel(EndpointFactory.java:363)
         at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:202)
         Truncated. see log file for complete stacktrace
    Caused By: java.security.PrivilegedActionException: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
    java.sql.Timestamp does not have a no-arg default constructor.
         this problem is related to the following location:
              at java.sql.Timestamp
    >
    [05:04:11 AM] #### Deployment incomplete. ####
    #### Cannot run application oil due to error deploying to IntegratedWebLogicServer.
    [05:04:11 AM] Remote deployment failed
    [Application oil stopped and undeployed from Server Instance IntegratedWebLogicServer]
    Thanks in advance..
    Siva
    Edited by: Shankar on Jun 30, 2011 7:02 AM

  • Web Services Data Control - Complex type bindings

    I am calling a web services using the web service data control. The request object is a complex type. I observed that some data managed to bind but some failed to bind (empty value on the outbound SOAP payload). Specifically, all the "scalar" elements within the complex type managed to bind. For example the following element snippet within the overall complex data did not bind the value entered to the SOAP payload:
    <xsd:element minOccurs="0" name="zones">
    <xsd:annotation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element type="xsd:string" maxOccurs="unbounded" minOccurs="1" name="zone"/>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    While the following complex element within the same payload managed to bind value entered:
    <xsd:element minOccurs="0" name="orderBy">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element maxOccurs="unbounded" minOccurs="1" name="orderByItem">
    <xsd:complexType>
    <xsd:all>
    <xsd:element type="xsd:string" name="fieldName"/>
    <xsd:element type="xsd:boolean" name="ascending"/>
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    Any bug report of this?
    Cheers
    Boon

    Hi Frank,
    Thanks for the response. I looked further into the problem. This is what I found.
    This is error message:
    javax.xml.ws.soap.SOAPFaultException: Foundation Engine Error: '' is an Invalid search zone. Valid zones include: 'id_object','name','published.name','comment_text','published.comment_text','note','document_extension','published.document_extension','physical_id','file_title','published.created_by','content'
    I turned on the trace and found the following message:
    [SRC_METHOD: parse] [225] No XML file /ObjectiveSearch/send/params/searchRequest/searchInput/searchInfo/zones/zones.xml for metaobject ObjectiveSearch.send.params.searchRequest.searchInput.searchInfo.zones.zones
    But when I looked into the model directory, I only able to find:
    H:\JDeveloper\AdvancedSearch\Model\adfmsrc\ObjectiveSearch\send\params\searchRequest\searchInput\searchInfo\zones\zone.xml
    It seems that WS data controller adapter is looking for zones/zones.xml. The wsdl specify zones with sub-elements(sequence) of zone (see wsdl below). The correct structure (zones/zone) is shown on the web service data control pallete and I can bind it to a JSF page.
    wsdl:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wscoor="http://docs.oasis-open.org/ws-tx/wscoor/2006/06" xmlns:tns="urn:objective.com" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xi="http://www.w3.org/2001/XInclude" targetNamespace="urn:objective.com" name="searchService">
    <wsp:Policy wsu:Id="WSSPortBindingInputPolicy">
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:TransportBinding>
    <wsp:Policy>
    <wsp:All>
    <sp:TransportToken>
    <wsp:Policy>
    <sp:HttpsToken RequireClientCertificate="false"/>
    </wsp:Policy>
    </sp:TransportToken>
    <sp:AlgorithmSuite>
    <wsp:Policy>
    <sp:Basic128/>
    </wsp:Policy>
    </sp:AlgorithmSuite>
    <sp:Layout>
    <wsp:Policy>
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:Strict/>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    </sp:Layout>
    <sp:IncludeTimestamp/>
    </wsp:All>
    </wsp:Policy>
    </sp:TransportBinding>
    <sp:EndorsingSupportingTokens>
    <wsp:Policy>
    <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/AlwaysToRecipient">
    <wsp:Policy>
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:WssX509V3Token10/>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    </sp:X509Token>
    </wsp:Policy>
    </sp:EndorsingSupportingTokens>
    <sp:SignedParts>
    <sp:Body/>
    </sp:SignedParts>
    <sp:SignedSupportingTokens>
    <wsp:Policy>
    <wsp:All>
    <sp:UsernameToken sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/AlwaysToRecipient">
    <wsp:Policy>
    <sp:NoPassword/>
    </wsp:Policy>
    </sp:UsernameToken>
    </wsp:All>
    </wsp:Policy>
    </sp:SignedSupportingTokens>
    <sp:Wss11>
    <wsp:Policy>
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:MustSupportRefIssuerSerial/>
    <sp:MustSupportRefKeyIdentifier/>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    </sp:Wss11>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    <wsp:Policy wsu:Id="WSSPortBindingOutputPolicy">
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:EndorsingSupportingTokens>
    <wsp:Policy>
    <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/Always">
    <wsp:Policy>
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:WssX509V3Token10/>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    </sp:X509Token>
    </wsp:Policy>
    </sp:EndorsingSupportingTokens>
    <sp:SignedParts>
    <sp:Body/>
    </sp:SignedParts>
    <sp:Wss11>
    <wsp:Policy>
    <wsp:ExactlyOne>
    <wsp:All>
    <sp:MustSupportRefIssuerSerial/>
    <sp:MustSupportRefKeyIdentifier/>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    </sp:Wss11>
    </wsp:All>
    </wsp:ExactlyOne>
    </wsp:Policy>
    <types>
    <xsd:schema targetNamespace="urn:objective.com">
    <xsd:simpleType xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:objective.com:ecosys" name="logicalOperatorType">
    <xsd:annotation>
    <xsd:documentation>The type of join of the condition 'and' 'or'.
                   </xsd:documentation>
    </xsd:annotation>
    <xsd:restriction base="xsd:string">
    <xsd:enumeration value="and"/>
    <xsd:enumeration value="or"/>
    </xsd:restriction>
    </xsd:simpleType>
    <xsd:complexType xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:objective.com:ecosys" name="expressionType">
    <xsd:sequence>
    <xsd:choice maxOccurs="unbounded" minOccurs="0">
    <xsd:element maxOccurs="unbounded" minOccurs="0" type="tns:expressionType" name="expression"/>
    <xsd:element maxOccurs="unbounded" minOccurs="0" type="tns:metadataCondition" name="condition"/>
    </xsd:choice>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:objective.com:ecosys" name="metadataCondition">
    <xsd:annotation>
    <xsd:documentation>
    </xsd:documentation>
    </xsd:annotation>
    <xsd:all>
    <xsd:element type="tns:logicalOperatorType" name="logicalOperator"/>
    <xsd:element type="xsd:string" name="field"/>
    <xsd:element type="xsd:string" name="operator"/>
    <xsd:element minOccurs="0" type="xsd:string" name="value"/>
    </xsd:all>
    </xsd:complexType>
    <xsd:element xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:objective.com:ecosys" name="searchRequest">
    <xsd:annotation>
    <xsd:documentation>
    </xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:all>
    <xsd:element name="searchInput">
    <xsd:complexType>
    <xsd:all>
    <xsd:element name="searchInfo">
    <xsd:complexType>
    <xsd:all>
    <xsd:element minOccurs="0" name="objectTypes">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element maxOccurs="unbounded" minOccurs="1" type="xsd:string" name="objectType">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:int" name="numResults">
    <xsd:annotation>
    <xsd:documentation>The maximum number of results to     search for.</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:boolean" name="showDeleted">
    <xsd:annotation>
    <xsd:documentation>Show deleted objects in the search results?</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="textQuery">
    <xsd:annotation>
    <xsd:documentation>A Verity text query, by default the     syntax of the query is "Internet" but can also be changed     to 'Verity' via the query syntax argument.</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element type="xsd:string" minOccurs="0" name="syntax">
    <xsd:annotation>
    <xsd:documentation>The syntax of the search query either
                                                                     'Internet' (default) or 'Verity'.</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" name="searchScopes">
    <xsd:annotation>
    <xsd:documentation>Search scopes to include in the
                                                                     search.</xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element type="xsd:string" maxOccurs="unbounded" minOccurs="1" name="searchScope"/>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    <xsd:element minOccurs="0" name="zones">
    <xsd:annotation>
    <xsd:documentation>Search zones to include in the
                                                                     search.</xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element type="xsd:string" maxOccurs="unbounded" minOccurs="1" name="zone"/>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    <xsd:element type="xsd:string" minOccurs="0" name="attributes">
    <xsd:annotation>
    <xsd:documentation>The attributes used when fetching
                                                                     results (these attributes are passed to inspect).
                                                                </xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="behaviours">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="sections">
    <xsd:annotation>
    <xsd:documentation>     </xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" name="orderBy">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element maxOccurs="unbounded" minOccurs="1" name="orderByItem">
    <xsd:complexType>
    <xsd:all>
    <xsd:element type="xsd:string" name="fieldName"/>
    <xsd:element type="xsd:boolean" name="ascending"/>
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="searchRoot">
    <xsd:annotation>
    <xsd:documentation>The root container of the search, for a constrained search.</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="depth">
    <xsd:annotation>
    <xsd:documentation>The depth to traverse.</xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    <xsd:element xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:objective.com:ecosys" name="searchResult">
    <xsd:complexType>
    <xsd:all>
    <xsd:element type="xsd:string" name="resultId">
    <xsd:annotation>
    <xsd:documentation></xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element type="xsd:int" name="numberOfResults">
    <xsd:annotation>
    <xsd:documentation>     </xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element type="xsd:boolean" name="sorted">
    <xsd:annotation>
    <xsd:documentation>     </xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    <xsd:element minOccurs="0" type="xsd:string" name="sortError">
    <xsd:annotation>
    <xsd:documentation>     </xsd:documentation>
    </xsd:annotation>
    </xsd:element>
    </xsd:all>
    <xsd:attribute name="instanceDomain" type="xsd:string"/>
    </xsd:complexType>
    </xsd:element>
    </xsd:schema>
    </types>
    <message name="searchRequest">
    <part name="searchRequest" element="tns:searchRequest"/>
    </message>
    <message name="searchResult">
    <part name="searchResult" element="tns:searchResult"/>
    </message>
    <portType name="searchPortType">
    <operation name="send">
    <input message="tns:searchRequest"/>
    <output message="tns:searchResult"/>
    </operation>
    </portType>
    <binding name="searchBinding" type="tns:searchPortType">
    <wsp:PolicyReference URI="#WSSPortBindingInputPolicy"/>
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
    <operation name="send">
    <soap:operation soapAction=""/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <wsp:PolicyReference URI="#WSSPortBindingOutputPolicy"/>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="searchService">
    <documentation>"search" service.</documentation>
    <port name="searchPort" binding="tns:searchBinding">
    <soap:address location="https://youContentServer:443/services/search"/>
    </port>
    </service>
    </definitions>
    Cheers
    Boon

  • No data in generated document/web service data source/complex response type

    I can define a report with a template with the BI Publisher server and the Template Builder Desktop plugin. When I use an sql statement as data source the preview functionality in Word and in the browser (logged in to the server) results in a correct report, with the correct data from the data source.
    When I use a web service as a data source I can still generate and preview reports but no data from the data source is visible in the reports. However this data is available in the Template Builder plugin in MS-Word.
    How do I know this ? When I try to insert a field from the data source into my rtf template the plugin shows a screen with the available fields. Or actually, the screen shows all fields returned by a dummy call to the web service. When I click on a field it shows the value returned by the web service just after the test "Example". I have set up my web service such that it always returns the same response.
    The field I want to show is in a repeating record, but it does not make a difference when I surround it by a group:
    <?for-each-group:/getValidationGroupsResponse/body/validationGroupList/validationGroup[1];./name?><?name?><?end for-each-group?>
    Neither does looping over all fields display any data:
    <?for-each-group:/getValidationGroupsResponse/body/validationGroupList/validationGroup;./name?><?name?><?end for-each-group?>
    The fact that the response of my web service data source contains repeating records might be different from what others have tested so far.
    I also found two other features when defining reports. I mention them here because they could be related to my problem. When I define two data source for my report, a web service and an sql query then only the fields from the sql query are visible in MS-Word/Template Builder. Even when the Data Model specifies the web service as "Main Data Set". And the "Default data source" is always a database even when the Data Model only defines a web service as "Data Set".
    Edited by: CalculateOnline.org on May 21, 2010 2:36 PM: changed title

    Unfortunately I can not test against a public webservice and follow the examples in the tutorials, since BI Publisher does not seem to offer any proxy configuration to connect to the internet.
    My local webservice returns the following data, visible when viewing the report from the backend, when no template has been defined yet:
    <ns2:getValidationGroupsResponse xmlns:ns2="amsterdam/wabo/services/data/validationOperations" xmlns="amsterdam/wabo/services/data/common">
    <ns2:responseHeader>
    <resultaatcode>OK</resultaatcode>
    </ns2:responseHeader>
    <ns2:body>
    <ns2:validationGroupList>
    <ns2:validationGroup>
    <ns2:name>testgroep1</ns2:name>
    <ns2:caption>kop1</ns2:caption>
    <ns2:description>Voor testen ontvankelijkheidstest 1</ns2:description>
    </ns2:validationGroup>
    <ns2:validationGroup>
    <ns2:name>testgroep2</ns2:name>
    <ns2:caption>kop2</ns2:caption>
    <ns2:description>Voor testen ontvankelijkheidstest 2</ns2:description>
    </ns2:validationGroup>
    </ns2:validationGroupList>
    </ns2:body>
    </ns2:getValidationGroupsResponse>
    After defining the template, the values of the first group are visible in MS-Word as well, as example values.
    I put the the template in a public place:
    http://www.calculateonline.org/projects/bipublisher/template1.rtf
    Just in case you need the wsdl as well:
    http://www.calculateonline.org/projects/bipublisher/validationOperations.wsdl

  • Consuming a web service using UTL_HTTP, Complex XML types

    this is the first time i have encountered a complex type calling a web service from PLSQL. i have sucsessfully called other methods from this same web service so i know its working.
    this is what i have to pass in:
    <xs:complexType name="AddJobRequestStructure">
    <xs:sequence>
    <xs:element name="AffectedUnits" type="ro:UnitIdentificationStructureArray" />
    <xs:element name="ServiceCode" type="xs:string" />
    <xs:element name="RecordTypeCode" type="xs:string" />
    <xs:element name="MultipleDescriptionCodes" type="ro:DescriptionSeverityStructureArray" />
    </xs:sequence>
    </xs:complexType>
    concentraiting on the parameter "AffectedUnits" type =
    <xs:complexType name="UnitIdentificationStructure">
    <xs:sequence>
    <xs:element name="UnitID" type="xs:string" />
    <xs:element name="StreetID" type="xs:string" />
    <xs:element name="UniqueStreetReferenceNumber" type="xs:string" />
    <xs:element name="UnitNumber" type="xs:string" />
    <xs:element name="Location" type="xs:string" />
    <xs:element name="PAON" type="ro:AONstructure" />
    <xs:element name="Easting" type="xs:double" />
    <xs:element name="Northing" type="xs:double" />
    </xs:sequence>
    </xs:complexType>
    for simple types i build the XML such as:
    request.body := request.body||'<ServiceCode xsi:type="xs:string">'||some_value||'</ServiceCode>';
    (request being a type that holds the namespace,method,body and envelope tag)
    just to re-itterate, i have other web service methods (from the same web service) working this way, however im not sure where to start with this complex type, so any help would be great
    Cheers.

    Thanks for the response, I’m not familiar with XML or web services so I appreciate the input. There is indeed an intermediate type. The web service documentation I have does state that the complex type can take multiple records, however we will only ever be passing one, it was this mention of an array that threw me, i asumed the array was the complex type - rather than there being an array of complext types for the handling of multiple records.
    <xs:complexType name="UnitIdentificationStructureArray">
    <xs:complexContent>
    <xs:restriction base="soapenc:Array">
    <xs:sequence />
    <xs:attribute ref="soapenc:arrayType" n1:arrayType="ro:UnitIdentificationStructure[]" xmlns:n1="http://schemas.xmlsoap.org/wsdl/" />
    </xs:restriction>
    </xs:complexContent>
    </xs:complexType>
    I assumed I had to pass each element of the complex type in separately and then reference this somehow in the parent, but it sound like, from what you say, I can just pass in XML containing the data in the correct structure
    Could you give me a basic example of how this XML fragment might look?
    Apologies for the lack of understanding - XML is failry new to me, this is as far as i have got
    Cheers

  • Web Service invocation and Complex Types (java TO's)

    I am trying to call a java service from ColdFusion MX 8.0.1 using the following code.
    I am the developer of the Java service, not a coldfusion programmer.
    <cfscript>
         ws = CreateObject("WebService", "http://myserver.us/webservices/WebInterface?WSDL");
         vali = CreateObject("Java","vo.myapplication.ContactVO");
         vali.setId(1234);
         vali.setSecondaryID(45855);
         wsResponse = ws.updateContact(vali);
    </cfscript>
    The call fails with "Object Instantiation Exception - Class not found: vo.myapplication.ContactVO", so i know CF is unable to load my class.
    My question is why?
    My stubs have been generated into
    C:\jrun4\servers\cfusion\cfusion-ear\cfusion-war\WEB-INF\cfusion\stubs\WS-254617805
    and i can see ContactVO in there, in the correct package.
    I can make it work if i add the absolute path of the sub directory to
    Server Settings > Java and JVM > ColdFusion Class Path
    Can anyone tell me why Coldfusion 8.0.1 is not dynamically loading the VO class, so that i can perform a CreateObject?
    Thanks in advance!

    Another way to dynamically load a custom class like /vo/myapplication/ContactVO.class, besides specifying its path in the classpath, is to place it in the directory {CF_wwwroot}/WEB_INF/classes/. Mind you, I'm on the Coldfusion single-server version, on Windows.

  • Web service using jdev 10.1.3

    Hi all....
    i am trying to build a web service using oracle jdev 10.1.3.
    i have built a simple java class that return common type such as String, int, long and publish theses method as web service and it works successfully......
    but when i tried to build web service that return complex type
    i.e.
    //////////////// class that i need to create a web service from it ///////////////////////
    public calss webService {
    public Subscriber getSubscriber(){
    return new Subscriber();
    public int getID(){
    return 10;
    where Subscriber is a java object i have create.
    public class Subscriber implements Serializable {
    private String name;
    public String getName(){
    return "Name";
    when creating the web service, the getSubscriber method was not published but the getID is published.
    any idea of how to make a web service that return a complex type....... i n
    web service steps:
    http://www.orablogs.com/cmaxwell/archives/000629.html

    As per the 10.1.3 Preview Relase Notes :
    Working with OC4J 10.1.2 : By default, JDeveloper 10.1.3 works with OC4J 10.1.3. However due to bug 3989799 it cannotconnect to OC4J 10.1.2 in the same session. Testing a connection or expanding a connection will fail with an exception. Additionally, deployment will succeed, but JDeveloper will be unable to detect and report the port number needed to access any deployed web applications via HTTP. You can enable 10.1.2 support by uncommenting the line: # AddVMOption -Drmi.disablePropagation=true in the jdev.conf file (located in jdev\bin) by removing the initial '#' character and restarting JDeveloper. Note, however, that enabling this setting will prevent JDeveloper from connecting to OC4J 10.1.3 instances, including the OC4J installation provided with JDeveloper. Comment the line then restart to restore 10.1.3 connectivity.
    Hope this helps.. Sunil..

  • Implementation of Asynchronous Web Services using JDeveloper

    Various articles and tutorials, which I have read, are talking about asynchronous BPEL processes. These asynch BPEL processes are result of the orchestration of different synch and asynch atomic services (web services in specific). There are even tutorials as part of Oracle SOA Suite and JDeveloper explaining how to consume asynchronous services in a BPEL process. Well and good.
    But unfortunately I haven’t seen any tutorial or article talks about the implementation of asynchronous web services (How to implement an asynchronous service?). All what they talk about is the consumption side of it and the applicability of WS-Addressing or Correlation ID for the consumption of the Service.
    As part of my research, I delved further into the sample BPEL processes comes out with Oracle BPEL Process Manager. For example; I have had a look into the Asynchronous Loan Processor process, where it is orchestrating a Synch Credit Rating Service and three asynch services namely Star Loan, United Loan and American Loans. But as I delved down into those, I realized that these services are simply BPEL Processes where it is implemented as a sequence of Receive, Assign and Invoke activities, where each of the activities does the following.
    Receive -- Receives the request from the client
    Assign -- Does some manipulation on the Input variable and set the output variable
    Invoke -- Invokes the client back (call back)
    These kinds of asynch services are pretty fine to demonstrate theory.
    But if we put ourselves more into practical scenarios, where we invoke a service from some application and the result of that invocation shall happen after some time (minutes to hours) in the form of a callback. In that case we WON’T be able to realize the service simply by a simple BPEL Process, rather we will have to implement as a Web Service with two port types implemented, where one port type is for the request and another one for the callback.
    I do understand these kinds of services can be implemented using JAX-WS.
    Question Here: How I do it using Oracle JDeveloper and Oracle Application Server???
    If anyone have done it, the REAL implementation of ASYNCH Web Services *(NOT BY USING BPEL or BPEL Wrapper)* using JDeveloper to deploy on Oracle Application Server or on Oracle SOA Suite, please post the know-how. If someone else is interested in taking it forward, we can take it further together.
    -Sudheer
    P.S: I am NOT at all interested in theory, as I had enough. Here I don’t want to be Conceptual; rather I am talking about hands-on.

    Hi Sudheer,
    I am not sure if this will help you
    If you take Oracle SOA Suite Order Booking Tutorial and go to Chapter 5 Creating the CreditService Project ( http://download.oracle.com/docs/cd/B31017_01/core.1013/b28937/creditservice.htm ), you learn how to create a synchronous Web service from a WSDL file.
    If you take the wsdl and delete output and fault tags (you can see it below) and follow the steps you'll generate an asynchronous web service.
    The generated Java method will be a void method
    public class ValidateCreditCardImpl {
    public void verifyCC(CreditCard creditCard) {
    Inside this void method you can try to call to a Receive BPEL Activity.
    I hope this will be useful . Regards,
    J
    <definitions targetNamespace="http://www.globalcompany.com/ns/credit"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="http://www.globalcompany.com/ns/credit"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:types="http://www.globalcompany.com/ns/credit.xsd">
    <types>
    <schema targetNamespace="http://www.globalcompany.com/ns/credit.xsd"
    xmlns="http://www.w3.org/2001/XMLSchema"
    xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
    <complexType name="CreditCard">
    <sequence>
    <element name="ccType" type="string"/>
    <element name="ccNum" type="string"/>
    </sequence>
    </complexType>
    <element name="CreditCard" type="types:CreditCard"/>
    <element name="valid" type="boolean"/>
    <element name="error" type="string"/>
    </schema>
    </types>
    <message name="CreditCardValidationRequestMessage">
    <part name="CreditCard" element="types:CreditCard"/>
    </message>
    <message name="CreditCardValidationResponseMessage">
    <part name="valid" element="types:valid"/>
    </message>
    <message name="CreditCardValidationFaultMessage">
    <part name="error" element="types:error"/>
    </message>
    <portType name="ValidateCreditCard">
    <operation name="VerifyCC">
    <input message="tns:CreditCardValidationRequestMessage"
    name="CreditCardInfo"/>
    </operation>
    </portType>
    <binding name="ValidateCreditCardSoapHttp" type="tns:ValidateCreditCard">
    <soap:binding style="document"
    transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="VerifyCC">
    <soap:operation soapAction="http://www.globalcompany.com/ns/credit/VerifyCC"/>
    <input name="CreditCardInfo">
    <soap:body use="literal" parts="CreditCard"/>
    </input>
    </operation>
    </binding>
    <service name="CreditService">
    <port name="ValidateCreditCardServiceSoapHttp"
    binding="tns:ValidateCreditCardSoapHttp">
    <soap:address location="http://localhost:8888/CreditService"/>
    </port>
    </service>
    </definitions>
    Edited by: user10262974 on 30-mar-2009 16:19

  • Unable to pass xmlbeans object in weblogic web services using OEPE

    Migrating Weblogic web services from Weblogic Workshop 10.3 to Oracle Enterprise for Eclipse...Passing xmlbean generated types in arguments of webservice call
    How to work around the following errors? I do not have this error when in workshop 10.3 only in OEPE eclipse
    "oracle.eclipse.tools.webservices.compiler.CompilationException: Errors: JAX-WS web services must not have xmlBean parameter or return type"
    PLease note that I want DocType to be xmlbeans generated or inherited from org.apache.xmlbeans.XmlObject....
    @WebMethod
         public void upload(String filename, DocType doc) {
    Hi, I have legacy codes from Weblogic workshop 10.1 and 10.3.....
    I am able to compile and run in Weblogic workshop 10.3 by passing the xmlbean generated DocType as arguments in the web services call.... but why am I not able to do this in Oracle Enterprise for Eclipse OEPE......
    If I were to generate the web service from teh wsdl...it will generate it's own DocType.class in the jar files and not use the xmlbean generated class one....
    How to get iOEPE to generate the classes in build\jws\ for
    testWSService-annotation.xml
    weblogic-webservices.xml etc like in workshop
    How can I resolve this??? Am I stuck with Workshop on this?? How to work around??
    Any help or clarifications would be much appreciated.
    Inside testWS.java,
    package ws;
    import java.io.File;
    import javax.jws.*;
    import org.example.doc.DocType;
    @WebService
    public class testWS {
         @WebMethod
         public void upload(String filename, DocType doc) {
              try {
                   doc.save(new File(filename));
              catch(Exception e) {
                   System.out.println(e);
    Inside xmlbeans generated DocType.java.....and DocTypeDocuments.java
    * XML Type: DocType
    * Namespace: http://www.example.org/doc
    * Java type: org.example.doc.DocType
    * Automatically generated - do not modify.
    package org.example.doc;
    * An XML DocType(@http://www.example.org/doc).
    * This is a complex type.
    public interface DocType extends org.apache.xmlbeans.XmlObject
    public static final org.apache.xmlbeans.SchemaType type = (org.apache.xmlbeans.SchemaType)
    org.apache.xmlbeans.XmlBeans.typeSystemForClassLoader(DocType.class.getClassLoader(), "schemaorg_apache_xmlbeans.system.testWSTypeSystem").resolveHandle("doctypec217type");
    * Gets the "element1" element
    java.lang.String getElement1();
    * Gets (as xml) the "element1" element
    org.apache.xmlbeans.XmlString xgetElement1();
    * Sets the "element1" element
    void setElement1(java.lang.String element1);
    * Sets (as xml) the "element1" element
    void xsetElement1(org.apache.xmlbeans.XmlString element1);
    * Gets the "element2" element
    java.lang.String getElement2();
    * Gets (as xml) the "element2" element
    org.apache.xmlbeans.XmlString xgetElement2();
    * Sets the "element2" element
    void setElement2(java.lang.String element2);
    * Sets (as xml) the "element2" element
    void xsetElement2(org.apache.xmlbeans.XmlString element2);
    * A factory class with static methods for creating instances
    * of this type.
    public static final class Factory
    public static org.example.doc.DocType newInstance() {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, null ); }
    public static org.example.doc.DocType newInstance(org.apache.xmlbeans.XmlOptions options) {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, options ); }
    /** @param xmlAsString the string value to parse */
    public static org.example.doc.DocType parse(java.lang.String xmlAsString) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, null ); }
    public static org.example.doc.DocType parse(java.lang.String xmlAsString, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, options ); }
    /** @param file the file from which to load an xml document */
    public static org.example.doc.DocType parse(java.io.File file) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, null ); }
    public static org.example.doc.DocType parse(java.io.File file, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, options ); }
    public static org.example.doc.DocType parse(java.net.URL u) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, null ); }
    public static org.example.doc.DocType parse(java.net.URL u, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, options ); }
    public static org.example.doc.DocType parse(java.io.InputStream is) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, null ); }
    public static org.example.doc.DocType parse(java.io.InputStream is, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, options ); }
    public static org.example.doc.DocType parse(java.io.Reader r) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, null ); }
    public static org.example.doc.DocType parse(java.io.Reader r, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, options ); }
    public static org.example.doc.DocType parse(javax.xml.stream.XMLStreamReader sr) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, null ); }
    public static org.example.doc.DocType parse(javax.xml.stream.XMLStreamReader sr, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, options ); }
    public static org.example.doc.DocType parse(org.w3c.dom.Node node) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, null ); }
    public static org.example.doc.DocType parse(org.w3c.dom.Node node, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, options ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.example.doc.DocType parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, null ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.example.doc.DocType parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return (org.example.doc.DocType) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, options ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, null ); }
    /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */
    public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException {
    return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, options ); }
    private Factory() { } // No instance of this class allowed
    Edited by: user11079482 on Jan 1, 2010 2:09 AM

    Ok just as I expected. So I guess I am left with the following two options
    1) either I switched to using JAXB in my apps instaed of xmlbeans....
    2) or if I still wanna use the old JAX-RPC web services to deploy on the Weblogic 10gR3 server i will have to create my own ant task jwsc directly......as shown below in your docs
    Programming Web Services for WebLogic Server (ant tasks)
    http://download.oracle.com/docs/cd/E13222_01/wls/docs92/webserv/anttasks.html
    Getting Started With WebLogic Web Services Using JAX-RPC
    http://download.oracle.com/docs/cd/E12840_01/wls/docs103/webserv_rpc/index.html
    Will OEPE be supporting the old JAX-RPC anytime in the near future release? or have to create own build ant task to call jwsc ant task directly to compile JAX-RPC web services??

  • Error when generating a Web Service from WSDL (Weblogic Workshop)

    Hi,
    I am using weblogic workshop 10 for implementing web services and its was working fine. But now when I try to generate a web service from WSDL its crashing with the following error;
    Could not find one or more classes: "org.apache.tools.ant.launch.AntMain". Please check the Ant classpath.
    org.eclipse.core.runtime.CoreException: Could not find one or more classes: "org.apache.tools.ant.launch.AntMain". Please check the Ant classpath.
         at com.bea.workshop.webservices.core.gen.JwsFromWsdlBuilder.buildJws(JwsFromWsdlBuilder.java:107)
         at com.bea.workshop.webservices.ui.wizards.jwsfromwsdl.GenerateJwsFromWsdlWizard$1.execute(GenerateJwsFromWsdlWizard.java:133)
         at org.eclipse.ui.actions.WorkspaceModifyOperation$1.run(WorkspaceModifyOperation.java:101)
         at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1737)
         at org.eclipse.ui.actions.WorkspaceModifyOperation.run(WorkspaceModifyOperation.java:113)
         at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
    org.eclipse.core.runtime.CoreException[4]: com.bea.workshop.webservices.core.gen.WebServicesException:
         at com.bea.workshop.webservices.core.gen.GenerationScript.runAnt(GenerationScript.java:154)
         at com.bea.workshop.webservices.core.gen.GenerationScript.createJWS(GenerationScript.java:98)
         at com.bea.workshop.webservices.core.gen.JwsFromWsdlBuilder.buildJws0(JwsFromWsdlBuilder.java:135)
         at com.bea.workshop.webservices.core.gen.JwsFromWsdlBuilder.buildJws(JwsFromWsdlBuilder.java:98)
         at com.bea.workshop.webservices.ui.wizards.jwsfromwsdl.GenerateJwsFromWsdlWizard$1.execute(GenerateJwsFromWsdlWizard.java:133)
         at org.eclipse.ui.actions.WorkspaceModifyOperation$1.run(WorkspaceModifyOperation.java:101)
         at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1737)
         at org.eclipse.ui.actions.WorkspaceModifyOperation.run(WorkspaceModifyOperation.java:113)
         at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
    Caused by: org.eclipse.core.runtime.CoreException: Could not find one or more classes: "org.apache.tools.ant.launch.AntMain". Please check the Ant classpath.
         at org.eclipse.ant.core.AntRunner.problemLoadingClass(AntRunner.java:445)
         at org.eclipse.ant.core.AntRunner.handleInvocationTargetException(AntRunner.java:417)
         at org.eclipse.ant.core.AntRunner.run(AntRunner.java:362)
         at com.bea.workshop.webservices.core.gen.GenerationScript.runAnt(GenerationScript.java:152)
         ... 8 more
    I have checked my ANT_HOME and its pointing to the correct location bea\tools\eclipse32\eclipse\plugins\org.apache.ant_1.6.5 and the AntMain classs is present in this path: org.apache.tools.ant.launch.AntMain
    If anyone has any idea on this please suggest a solution.
    Thanks in advance
    -AKJ

    Yes, I assume you are talking about ANT_HOME:
    see this Screenshot which shows my current settings
    [http://i43.tinypic.com/nbrec6.jpg|http://i43.tinypic.com/nbrec6.jpg]
    Regards
    -AKJ

  • How to invoke a web service using https

    Hi,
    I have a few security related questions surrounding BPEL process manager.
    1. Does the BPEL engine have the capability to invoke a web service using https (HTTP over SSL)? Does it automatically do that if partner link URI starts with https:// ?
    2. If not, what needs to be done to enable accessing a https based web service?
    3. I need to write a web service that accepts a message and updates certain information in the database. The web service will be deployed in an OC4J instance in Oracle App Server. We want to allow the web service to be accessed from BPEL only by users registered in the database. What is the recommended way to pass username and password to a webservice if service is invoked from BPEL process manager? Note that specifying username/password in bpel.xml is not an option.
    Thanks,
    Pranav

    1. Does the BPEL engine have the capability to invoke a web service using https (HTTP over SSL)? Does it automatically do that if partner link URI starts with https:// ?
    We currently don't have support for HTTP over SSl. We are working on it to include this functionality in near future.
    2. If not, what needs to be done to enable accessing a https based web service?
    I am not sure it is possible with current product offering. I will confirm it after discussing with our concerned development group. There is some work going to integrate with Oblix security mechanism [recently acquired by Oracle].
    3. I need to write a web service that accepts a message and updates certain information in the database. The web service will be deployed in an OC4J instance in Oracle App Server. We want to allow the web service to be accessed from BPEL only by users registered in the database. What is the recommended way to pass username and password to a webservice if service is invoked from BPEL process manager? Note that specifying username/password in bpel.xml is not an option.
    This will be easier to do if we can use Oblix along with BPEL PM. Could you please let us know more about your application so that we can provide you the customized solution till it's part of the product. You can send this query to [email protected] so that our product management team can give you more detailed roadmap regarding this.
    HTH.
    Thanks,
    Rakesh

  • Invoking web service using Weblogic Workshop (JCX)

    Invoking web service using Weblogic Workshop
    Posted: 5 Jan 2005 23:31 PM Reply
    Hi,
    I have WSDL from which I have generated a web service control (.jcx) using Weblogic Workshop.
    I need to write a client which will invoke the web service using the control.
    Can someone help me on how to go about this ?
    BTW .. I also tried the clientgen route and tried to generated the proxy jar from the WSDL but wasn't successful because of a existing clientgen bug.
    Refer bug

    Hi,
    if the consumer of the webservice is a control-aware consumer ( pageflow, control, process ) simply drag the control to this consumer and the control variable is ready for use.
    if the consumer is not control-aware, try to generate a proxy using eg. the axis tool, or handcode your proxy class.
    links :
    how to use webservice control
    http://e-docs.bea.com/workshop/docs81/doc/en/workshop/guide/controls/conGettingStartedWithJavaControls.html
    axis
    http://ws.apache.org/axis/
    - Anders M.
    - Anders M.

  • Creating Web Services using Netbeans GUI only

    Hi all,
    Creating, deploying & testing simple web-services through Netbeans point-n-click interface is quite simple (demo at: http://download.java.net/javaee5/screencasts/hello-simple-glassfish/). The demo shows a very simple service creation scenario, accepting and returning String types only. The service can easily be tested using the GUI option 'Test Web Service', which simply test the service through a simple web page at http://localhost:8080/MyWebApplication/MyWebService?Tester
    In a similar manner, I am trying to implement a web service (a little complex one, accepting and returning custom types) using Netbeans GUI only. Versioning information I am using are as follows:
    NetBeans IDE 6.1
    Sun Java System Application Server 9.1_02 (build b04-fcs)
    JAX-WS 2.1.3.1
    Roughly speaking, the service's method signature I am using is shown below:
    public abstract myclass.X MyService.serviceMethod( myclass.X )
    Since it uses a custom type in parameter and return-types, the web-based test doesn't work any more. I wrote a separate client class to invoke the service using client-side stub classes (suppose to be generated by JAX-WS generated classes). The client code looks like as follows:
    public class ServiceClient {
         public static void main(String[] args) {
              MyService srv = new MyService ().getMyServicePort();
              X xin= new X();
              X xout= srv.serviceMethod( xin );
              System.out.println( "Result: "+ xout.toString());
    Netbeans shows a compiler error on "MyService srv = new MyService ().getMyServicePort();
    Is it possible to get it resolved without making use of ant scripts for generating client-side artifacts (stubs etc.)?
    Thanks,
    irfan

    Hello Sandy,
    Have you installed the Sun Java System App Server or JWSDP? If so, please make sure that one of the libraries in your Netbeans project contains the jaxrpc-api and jaxrpc-impl jars (which seem to be necessary to run wscompile).
    Netbeans ("standalone") doesn't seem to install the jaxrpx libraries and other jars required to compile and run webservices.
    Regards,
    Jonatan

  • Call MTOM web service using pl/sql (utl_http)

    Hi All,
    Is anyone able to call a MTOM web service using utl_http from pl/sql ?
    A typical request looks like this:
    --uuid:fd1fbed8-7042-4673-a304-becc1ffb037f+id=1
    Content-ID: <http://tempuri.org/0>
    Content-Transfer-Encoding: 8bit
    Content-Type: application/xop+xml;charset=utf-8;type="text/xml"
    <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"><s:Body>......</s:Body></s:Envelope>
    uuid:fd1fbed8-7042-4673-a304-becc1ffb037f+id=1
    A microsoft C# tool is provided to generate some requests and using fiddler I can see the content type is in the header as well as in the request. In the requests it doesn't contain the UID. Connection is set to keep-alive, is that possible using pl/sql ?
    The part that builds the header looks like:
    l_http_request := UTL_HTTP.begin_request(url => 'http://' || l_host_name || ':' || l_port || '/CRUDService.svc', method => 'POST', http_version => 'HTTP/1.1');
    UTL_HTTP.set_header(l_http_request, 'Host', l_host_name || ':' || l_port);
    UTL_HTTP.set_header(l_http_request, 'SOAPAction', '"action"');
    UTL_HTTP.set_header(l_http_request, 'Content-Length', LENGTH(l_string_request));
    UTL_HTTP.set_header(l_http_request, 'Content-ID', '<http://tempuri.org/0>');
    UTL_HTTP.set_header(l_http_request, 'Content-Transfer-Encoding', '8bit');
    UTL_HTTP.set_header(l_http_request, 'Content-Type', 'multipart/related; type="application/xop+xml";start="<http://tempuri.org/0>";boundary="uuid:fd1fbed8-7042-4673-a304-becc1ffb037f+id=1";start-info="text/xml"');
    I've played with the request by adding or removing information, the http response is (400) "Bad Request - Invalid Header", so should be somewhere in the header? Anyone ideas?
    Kind regards,
    Michiel

    HI Michiel
    I am also trying to achieve something similar to that. I am trying to call a web service that sends an xml attachment over MTOM? Kindly, let me know if this was achievable from your end? I mean how did the issue got resolved.
    thanks
    vijay

Maybe you are looking for