Have Error invoking SSL web service using pl sql procedure

Hi All,
Please any one can tell where i am going wrong,in calling ssl soa web service from plsql procedure.
Below steps i followed ssl configure in soa server
1- For configuring ssl in soa 11g, i am going to weblogic console->environment-> servers-> soa_server1-> check ssl box of port 8002.
2- restart the server.
3- One process i devloped, deployed in em console, while trying to acces the service with 8002 port, i need to use https://servicepath.
Is there is any problem in the above approch for configuring ssl in soa server.
Now coming to the procedure part, in below i given the deatails
DECLARE
HTTP_REQ UTL_HTTP.REQ;
HTTP_RESP UTL_HTTP.RESP;
URL_TEXT VARCHAR2(32767);
lv_process_xml_body varchar2(4000);
BEGIN
DBMS_OUTPUT.ENABLE(1000000);
lv_process_xml_body:='<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
     <soap:Body xmlns:ns1="http://xmlns.oracle.com/SOA_RND_jws/Sample/DemoBPELProcess">
          <ns1:process>
               <ns1:input></ns1:input>
</ns1:process>
</soap:Body>
</soap:Envelope>';
UTL_HTTP.SET_WALLET('file:/db/oracle/app/oradb/product/11.2.0/dbhome_1/bin/client', 'abcd123');
HTTP_REQ := UTL_HTTP.BEGIN_REQUEST('https://172.28.40.20:8002/soa-infra/services/Client/Sample/demobpelprocess_client_ep', 'POST' , 'HTTP/1.0');
UTL_HTTP.set_header(http_req, 'Content-Type', 'text/xml');
UTL_HTTP.set_header(http_req, 'Content-Length', LENGTH(lv_process_xml_body));
UTL_HTTP.SET_HEADER(HTTP_REQ, 'SOAPAction', 'process');
UTL_HTTP.write_text(http_req, lv_process_xml_body);
HTTP_RESP := UTL_HTTP.GET_RESPONSE(HTTP_REQ);
UTL_HTTP.END_RESPONSE(HTTP_RESP);
dbms_output.put_line('success');
exception
when others then
dbms_output.put_line(sqlerrm);
END;
But i am getting the error, unable to open the file
Regarding certificate i have taken from the browser while running the above soa service in browser with 8002 port.
Please let me know where i am doing wrong...
Please if some one knows about steps ...... to do it to work
Its urgent please help me out on this
Thanks
Dillip
Edited by: 903915 on Dec 21, 2011 9:51 PM
Edited by: 903915 on Dec 21, 2011 10:11 PM

Oracle is hosted by HOST A - this is where the pl/sql program resides.
The Web Service being accessed by pl/sql program is hosted by HOST B and there are 4 firewalls in between.
Oracle was not even able to establish connection to web services host.
Escalated the issue with networking folks and they resolved the connectivity problem.
Hope that helps.

Similar Messages

  • Error invoking SSL web service using pl sql UTL_HTTP

    Web Services Gurus,
    I am invoking a secure web service based on the following WSDL file from a pl/sql program using UTL_HTTP package.
    The web service is secure and prompts for authentication.
    The web services certificate is imported in Oracle Wallet on Database Server.
    I am listing the WSDL file, the pl/sql code and error message as follows -
    1. The WSDL file -
    <definitions
    name="Webservice"
    targetNamespace="http://webservice.airclic.com/"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="http://webservice.airclic.com/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    >
    <types>
    <xs:schema targetNamespace="http://webservice.airclic.com/" version="1.0" xmlns:tns="http://webservice.airclic.com/"
    xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <xs:element name="Exception" type="tns:Exception"/>
    <xs:element name="sendAuthenticationResponse" type="tns:sendAuthenticationResponse"/>
    <xs:element name="sendAuthenticationResponseResponse" type="tns:sendAuthenticationResponseResponse"/>
    <xs:complexType name="AuthenticationResponse">
    <xs:complexContent>
    <xs:extension base="tns:Response">
    <xs:sequence>
    <xs:element name="success" type="xs:boolean"/>
    <xs:element name="username" type="xs:string"/>
    <xs:element minOccurs="0" name="password" type="xs:string"/>
    <xs:element minOccurs="0" name="firstName" type="xs:string"/>
    <xs:element minOccurs="0" name="lastName" type="xs:string"/>
    <xs:element minOccurs="0" name="email" type="xs:string"/>
    <xs:element minOccurs="0" name="active" type="xs:boolean"/>
    <xs:element minOccurs="0" name="timeZone" type="xs:string"/>
    <xs:element minOccurs="0" name="group" type="xs:string"/>
    <xs:element minOccurs="0" name="role" type="xs:string"/>
    <xs:element minOccurs="0" name="errorCode" type="xs:string"/>
    <xs:element minOccurs="0" name="errorMessage" type="xs:string"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>
    <xs:complexType name="DispatchEvent"></xs:complexType>
    <xs:complexType name="sendAuthenticationResponse">
    <xs:sequence>
    <xs:element minOccurs="0" name="authenticationResponse" type="tns:AuthenticationResponse"/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name="sendAuthenticationResponseResponse">
    <xs:sequence/>
    </xs:complexType>
    <xs:simpleType name="status"></xs:simpleType>
    <xs:simpleType name="source"></xs:simpleType>
    <xs:simpleType name="eventType"></xs:simpleType>
    </xs:schema>
    </types>
    <message name="Webservice_sendAuthenticationResponse">
    <part name="sendAuthenticationResponse" element="tns:sendAuthenticationResponse"/>
    </message>
    <message name="Webservice_sendAuthenticationResponseResponse">
    <part name="sendAuthenticationResponseResponse" element="tns:sendAuthenticationResponseResponse"/>
    </message>
    <portType name="Webservice">
    <operation name="sendAuthenticationResponse" parameterOrder="sendAuthenticationResponse">
    <input message="tns:Webservice_sendAuthenticationResponse"/>
    <output message="tns:Webservice_sendAuthenticationResponseResponse"/>
    <fault name="Exception" message="tns:Exception"/>
    </operation>
    </portType>
    <binding name="WebserviceBinding" type="tns:Webservice">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="sendAuthenticationResponse">
    <soap:operation soapAction=""/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <soap:body use="literal"/>
    </output>
    <fault name="Exception">
    <soap:fault name="Exception" use="literal"/>
    </fault>
    </operation>
    </binding>
    <service name="Webservice">
    <port name="WebservicePort" binding="tns:WebserviceBinding">
    <soap:address location="https://host.airclic.com:443/webservice/product/fieldservice/v1/Webservice"/>
    </port>
    </service>
    </definitions>
    2. The pl/sql code that calls the web service operation sendAuthenticationResponse
    procedure send_auth_response
    as
    soap_request varchar2(30000);
    soap_respond varchar2(30000);
    http_req utl_http.req;
    http_resp utl_http.resp;
    resp XMLType;
    i integer;
    begin
    -- initiate wallet for AirClic certificate
    dbms_output.put_line ('1');
    utl_http.set_wallet('file:/etc/oracle/wallet','<wallet password>');
    -- create soap request
    dbms_output.put_line ('2');
    soap_request:= '<?xml version = "1.0" encoding = "UTF-8"?>
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <SOAP-ENV:Body>
    <ns1:sendAuthenticationResponse xmlns="https://host.airclic.com:443/webservice/product/fieldservice/v1/Webservice" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
    <success xsi:type="xsd:boolean">true</success>
    <username xsi:type="xsd:string">changlanih</username>
    <password xsi:type="xsd:string">abcd1234</password>
    <firstName xsi:type="xsd:string">hero</firstName>
    <lastName xsi:type="xsd:string">changlani</lastName>
    <email xsi:type="xsd:string">[email protected]</email>
    <active xsi:type="xsd:boolean">true</active>
    <timeZone xsi:type="xsd:string">eastern</timeZone>
    <group xsi:type="xsd:string">Northeast</group>
    <role xsi:type="xsd:string">Service Manager</role>
    <errorCode xsi:type="xsd:string"></errorCode>
    <errorMessage xsi:type="xsd:string"></errorMessage>
    </ns1:sendAuthenticationResponse>
    </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>';
    -- request that exceptions are raised for error Status Codes
    dbms_output.put_line ('3');
    utl_http.set_response_error_check (true);
    -- allow testing for exceptions like UTL_HTTP.http_server_error
    dbms_output.put_line ('4');
    utl_http.set_detailed_excp_support (true);
    --utl_http.set_transfer_timeout (ln_time_out);
    dbms_output.put_line ('5');
    utl_http.set_body_charset ('UTF-8');
    -- begin request
    dbms_output.put_line ('5.5');
    http_req:= utl_http.begin_request
    ('https://host.airclic.com:443/webservice/product/fieldservice/v1/Webservice/sendAuthenticationResponse', ------ is the url correct here ?
    'POST',
    'HTTP/1.1'
    dbms_output.put_line ('6');
    utl_http.set_authentication(http_req, '<username for webservice>', '<password for webservice user>');
    dbms_output.put_line ('7');
    utl_http.set_persistent_conn_support (http_req, false);
    dbms_output.put_line ('8');
    utl_http.set_header(http_req, 'Content-Type', 'text/xml'); -- since we are dealing with plain text in XML documents
    dbms_output.put_line ('9');
    utl_http.set_header(http_req, 'Content-Length', length(soap_request));
    dbms_output.put_line ('10');
    utl_http.set_header(http_req, 'SOAPAction', ''); -- required to specify this is a SOAP communication
    dbms_output.put_line ('11');
    utl_http.write_text(http_req, soap_request);
    dbms_output.put_line ('12');
    http_resp := utl_http.get_response(http_req);
    -- debug messages
    DBMS_OUTPUT.PUT_LINE('-------utl_http.get_response---------------------');
    DBMS_OUTPUT.PUT_LINE('http_resp.status_code is :'||http_resp.status_code );
    DBMS_OUTPUT.PUT_LINE('http_resp.reason_phrase is :'||http_resp.reason_phrase);
    DBMS_OUTPUT.PUT_LINE('http_resp.http_version is :'||http_resp.http_version);
    DBMS_OUTPUT.PUT_LINE('http_resp.private_hndl is :'||http_resp.private_hndl);
    DBMS_OUTPUT.PUT_LINE('-------utl_http.get_response----------------------');
    utl_http.read_text(http_resp, soap_respond);
    dbms_output.put_line ('13');
    utl_http.end_response(http_resp);
    dbms_output.put_line ('14');
    resp := XMLType.createXML(soap_respond);
    dbms_output.put_line ('15');
    resp := resp.extract('/soap:Envelop/soap:Body/child::node()',
    'xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"');
    i:=0;
    dbms_output.put_line ('16');
    loop
    dbms_output.put_line(substr(soap_respond, 1 + i * 255, 250));
    i := i + 1;
    if (i * 250) > length(soap_respond) then
    exit;
    end if;
    end loop;
    exception
    when utl_http.request_failed then
    dbms_output.put_line('request failed: ' || utl_http.get_detailed_sqlerrm);
    when utl_http.http_server_error then
    dbms_output.put_line('server error: ' || utl_http.get_detailed_sqlerrm);
    when utl_http.http_client_error then
    dbms_output.put_line('client error: ' || utl_http.get_detailed_sqlerrm);
    when others then
    dbms_output.put_line(sqlerrm);
    end send_auth_response;
    3. Output when I run the send_auth_response procedure
    Connecting to the database cpdev.
    1
    2
    3
    4
    5
    5.5
    ORA-12560: TNS:protocol adapter error
    Process exited.
    Disconnecting from the database cpdev.
    Comments -
    The web service operation only has input message. The input message consists of a complex type as seen in WSDL.
    Questions -
    1. This is my first attempt in invoking a web service from pl/sql program. Is the code in SOAP body correct as mapped to the complex type in WSDL ?
    2. As seen from the dbms_out - the last message before ORA-12560 is 5.5, that means the call is erroring at following code line -
    http_req:= utl_http.begin_request ------ what am I doing wrong here ?
    3. The web service is SSL as seen from WSDLand needs a username/password for access - which is being performed by following code line -
    utl_http.set_authentication(http_req, '<username for webservice>', '<password for webservice user>'); ------- is that correct ?
    4. I am not using any proxy server - should I be using it ? When is it necessary to use proxy ?
    Appreciate any help.
    Thanx.

    Oracle is hosted by HOST A - this is where the pl/sql program resides.
    The Web Service being accessed by pl/sql program is hosted by HOST B and there are 4 firewalls in between.
    Oracle was not even able to establish connection to web services host.
    Escalated the issue with networking folks and they resolved the connectivity problem.
    Hope that helps.

  • ORA-29532 error when invoking SSL web services using UTL_DBWS

    Web Service gurus,
    The WSDL for web services is as follows -
    <definitions name="Webservice" targetNamespace="http://webservice.airclic.com/">

    <types>

    <xs:schema targetNamespace="http://webservice.airclic.com/" version="1.0">
    <xs:element name="Exception" type="tns:Exception"/>
    <xs:element name="listenForEvents" type="tns:listenForEvents"/>
    <xs:element name="listenForEventsResponse" type="tns:listenForEventsResponse"/>
    <xs:element name="sendAuthenticationResponse" type="tns:sendAuthenticationResponse"/>
    <xs:element name="sendAuthenticationResponseResponse" type="tns:sendAuthenticationResponseResponse"/>
    <xs:element name="upsertTask" type="tns:upsertTask"/>
    <xs:element name="upsertTaskResponse" type="tns:upsertTaskResponse"/>

    <xs:complexType name="upsertTask">

    <xs:sequence>
    <xs:element minOccurs="0" name="task" type="tns:Task"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Task">

    <xs:complexContent>

    <xs:extension base="tns:PlatformObject">

    <xs:sequence>
    <xs:element minOccurs="0" name="status" type="tns:status"/>
    <xs:element minOccurs="0" name="assignee" type="xs:string"/>
    <xs:element minOccurs="0" name="assigneeUserId" type="xs:string"/>
    <xs:element minOccurs="0" name="name" type="xs:string"/>
    <xs:element minOccurs="0" name="type" type="xs:string"/>
    <xs:element minOccurs="0" name="creationTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="updateTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="startTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="endTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="source" type="tns:source"/>
    <xs:element minOccurs="0" name="notes" type="xs:string"/>
    <xs:element minOccurs="0" name="priority" type="xs:int"/>
    <xs:element minOccurs="0" name="penalized" type="xs:boolean"/>
    <xs:element minOccurs="0" name="hasSLA" type="xs:boolean"/>
    <xs:element minOccurs="0" name="location" type="tns:Location"/>
    <xs:element minOccurs="0" name="windowStartTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="windowEndTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="signee" type="xs:string"/>
    <xs:element minOccurs="0" name="signature" type="xs:base64Binary"/>
    <xs:element minOccurs="0" name="customerId" type="xs:string"/>
    <xs:element minOccurs="0" name="travelTime" type="xs:int"/>
    <xs:element minOccurs="0" name="expirationTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="parentId" type="xs:long"/>
    <xs:element minOccurs="0" name="externalTimezone" type="xs:string"/>
    <xs:element minOccurs="0" name="localTimeOffset" type="xs:long"/>
    <xs:element minOccurs="0" name="consignee" type="xs:string"/>
    <xs:element minOccurs="0" name="assignmentWindowStartTimestamp" type="xs:long"/>
    <xs:element minOccurs="0" name="assignmentWindowEndTimestamp" type="xs:long"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="PlatformObject">

    <xs:sequence>
    <xs:element name="id" type="xs:string"/>
    <xs:element name="externalId" type="xs:string"/>
    <xs:element name="revision" type="xs:long"/>
    <xs:element name="platformDateCreated" type="xs:dateTime"/>
    <xs:element name="platformDateUpdated" type="xs:dateTime"/>
    <xs:element name="objectName" type="xs:string"/>
    <xs:element maxOccurs="unbounded" name="extendedAttributes" type="tns:ExtendedAttribute"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Location">

    <xs:sequence>
    <xs:element minOccurs="0" name="name" type="xs:string"/>
    <xs:element minOccurs="0" name="description" type="xs:string"/>
    <xs:element minOccurs="0" name="type" type="xs:string"/>
    <xs:element minOccurs="0" name="address" type="tns:Address"/>
    <xs:element minOccurs="0" name="position" type="tns:Position"/>
    <xs:element minOccurs="0" name="geofenceId" type="xs:long"/>
    <xs:element minOccurs="0" name="capcity" type="xs:int"/>
    <xs:element minOccurs="0" name="contact" type="xs:string"/>
    <xs:element minOccurs="0" name="email" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Address">

    <xs:sequence>
    <xs:element minOccurs="0" name="addressLine" type="xs:string"/>
    <xs:element minOccurs="0" name="addressLine2" type="xs:string"/>
    <xs:element minOccurs="0" name="city" type="xs:string"/>
    <xs:element minOccurs="0" name="secondaryCity" type="xs:string"/>
    <xs:element minOccurs="0" name="subdivision" type="xs:string"/>
    <xs:element minOccurs="0" name="postalCode" type="xs:string"/>
    <xs:element minOccurs="0" name="country" type="xs:string"/>
    <xs:element minOccurs="0" name="phone" type="xs:string"/>
    <xs:element minOccurs="0" name="freeform" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Position">

    <xs:sequence>
    <xs:element name="latitude" type="xs:double"/>
    <xs:element name="longitude" type="xs:double"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="ExtendedAttribute">

    <xs:sequence>
    <xs:element name="name" type="xs:string"/>
    <xs:element name="value" type="xs:anyType"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="upsertTaskResponse">

    <xs:sequence>
    <xs:element minOccurs="0" name="task" type="tns:Task"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Exception">

    <xs:sequence>
    <xs:element minOccurs="0" name="message" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="listenForEvents">

    <xs:sequence>
    <xs:element minOccurs="0" name="listenParams" type="tns:ListenParams"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="ListenParams">

    <xs:sequence>
    <xs:element name="queueName" type="xs:string"/>
    <xs:element name="resendLast" type="xs:boolean"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="listenForEventsResponse">

    <xs:sequence>
    <xs:element maxOccurs="unbounded" minOccurs="0" name="events" type="tns:Event"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="Event">

    <xs:sequence>
    <xs:element name="id" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="AuthenticationRequestEvent">

    <xs:complexContent>

    <xs:extension base="tns:RequestEvent">

    <xs:sequence>
    <xs:element name="username" type="xs:string"/>
    <xs:element minOccurs="0" name="password" type="xs:string"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="RequestEvent">

    <xs:complexContent>

    <xs:extension base="tns:Event">

    <xs:sequence>
    <xs:element name="correlationId" type="xs:string"/>
    <xs:element name="response" type="tns:Response"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="Response">

    <xs:sequence>
    <xs:element name="correlationId" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="AuthenticationResponse">

    <xs:complexContent>

    <xs:extension base="tns:Response">

    <xs:sequence>
    <xs:element name="success" type="xs:boolean"/>
    <xs:element name="username" type="xs:string"/>
    <xs:element minOccurs="0" name="password" type="xs:string"/>
    <xs:element minOccurs="0" name="firstName" type="xs:string"/>
    <xs:element minOccurs="0" name="lastName" type="xs:string"/>
    <xs:element minOccurs="0" name="email" type="xs:string"/>
    <xs:element minOccurs="0" name="active" type="xs:boolean"/>
    <xs:element minOccurs="0" name="timeZone" type="xs:string"/>
    <xs:element minOccurs="0" name="group" type="xs:string"/>
    <xs:element minOccurs="0" name="role" type="xs:string"/>
    <xs:element minOccurs="0" name="errorCode" type="xs:string"/>
    <xs:element minOccurs="0" name="errorMessage" type="xs:string"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="DispatchEvent">

    <xs:complexContent>

    <xs:extension base="tns:Event">

    <xs:sequence>
    <xs:element name="type" type="tns:eventType"/>
    <xs:element minOccurs="0" name="previousTask" type="tns:Task"/>
    <xs:element name="changeTask" type="tns:Task"/>
    <xs:element minOccurs="0" name="newTask" type="tns:Task"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>

    <xs:complexType name="sendAuthenticationResponse">

    <xs:sequence>
    <xs:element minOccurs="0" name="authenticationResponse" type="tns:AuthenticationResponse"/>
    </xs:sequence>
    </xs:complexType>

    <xs:complexType name="sendAuthenticationResponseResponse">
    <xs:sequence/>
    </xs:complexType>

    <xs:simpleType name="status">

    <xs:restriction base="xs:string">
    <xs:enumeration value="NULL"/>
    <xs:enumeration value="UNASSIGNED"/>
    <xs:enumeration value="ASSIGNED"/>
    <xs:enumeration value="RECEIVED"/>
    <xs:enumeration value="ACCEPTED"/>
    <xs:enumeration value="REJECTED"/>
    <xs:enumeration value="IN_PROGRESS"/>
    <xs:enumeration value="POSTPONED"/>
    <xs:enumeration value="COMPLETED"/>
    <xs:enumeration value="CANCELED"/>
    <xs:enumeration value="CLEARED"/>
    <xs:enumeration value="EXPIRED"/>
    </xs:restriction>
    </xs:simpleType>

    <xs:simpleType name="source">

    <xs:restriction base="xs:string">
    <xs:enumeration value="NULL"/>
    <xs:enumeration value="DISPATCH"/>
    <xs:enumeration value="SYSTEM"/>
    <xs:enumeration value="ENDUSER"/>
    </xs:restriction>
    </xs:simpleType>

    <xs:simpleType name="eventType">

    <xs:restriction base="xs:string">
    <xs:enumeration value="TaskCreated"/>
    <xs:enumeration value="TaskUpdated"/>
    <xs:enumeration value="TaskAssigned"/>
    <xs:enumeration value="TaskDeleted"/>
    <xs:enumeration value="TaskStatusChanged"/>
    <xs:enumeration value="TaskConflicted"/>
    </xs:restriction>
    </xs:simpleType>
    </xs:schema>
    </types>

    <message name="Webservice_listenForEvents">
    <part element="tns:listenForEvents" name="listenForEvents"/>
    </message>

    <message name="Webservice_sendAuthenticationResponseResponse">
    <part element="tns:sendAuthenticationResponseResponse" name="sendAuthenticationResponseResponse"/>
    </message>

    <message name="Webservice_sendAuthenticationResponse">
    <part element="tns:sendAuthenticationResponse" name="sendAuthenticationResponse"/>
    </message>

    <message name="Webservice_upsertTaskResponse">
    <part element="tns:upsertTaskResponse" name="upsertTaskResponse"/>
    </message>

    <message name="Exception">
    <part element="tns:Exception" name="Exception"/>
    </message>

    <message name="Webservice_upsertTask">
    <part element="tns:upsertTask" name="upsertTask"/>
    </message>

    <message name="Webservice_listenForEventsResponse">
    <part element="tns:listenForEventsResponse" name="listenForEventsResponse"/>
    </message>

    <portType name="Webservice">

    <operation name="listenForEvents" parameterOrder="listenForEvents">
    <input message="tns:Webservice_listenForEvents"/>
    <output message="tns:Webservice_listenForEventsResponse"/>
    <fault message="tns:Exception" name="Exception"/>
    </operation>

    <operation name="sendAuthenticationResponse" parameterOrder="sendAuthenticationResponse">
    <input message="tns:Webservice_sendAuthenticationResponse"/>
    <output message="tns:Webservice_sendAuthenticationResponseResponse"/>
    <fault message="tns:Exception" name="Exception"/>
    </operation>

    <operation name="upsertTask" parameterOrder="upsertTask">
    <input message="tns:Webservice_upsertTask"/>
    <output message="tns:Webservice_upsertTaskResponse"/>
    <fault message="tns:Exception" name="Exception"/>
    </operation>
    </portType>

    <binding name="WebserviceBinding" type="tns:Webservice">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>

    <operation name="listenForEvents">
    <soap:operation soapAction=""/>

    <input>
    <soap:body use="literal"/>
    </input>

    <output>
    <soap:body use="literal"/>
    </output>

    <fault name="Exception">
    <soap:fault name="Exception" use="literal"/>
    </fault>
    </operation>

    <operation name="sendAuthenticationResponse">
    <soap:operation soapAction=""/>

    <input>
    <soap:body use="literal"/>
    </input>

    <output>
    <soap:body use="literal"/>
    </output>

    <fault name="Exception">
    <soap:fault name="Exception" use="literal"/>
    </fault>
    </operation>

    <operation name="upsertTask">
    <soap:operation soapAction=""/>

    <input>
    <soap:body use="literal"/>
    </input>

    <output>
    <soap:body use="literal"/>
    </output>

    <fault name="Exception">
    <soap:fault name="Exception" use="literal"/>
    </fault>
    </operation>
    </binding>

    <service name="Webservice">

    <port binding="tns:WebserviceBinding" name="WebservicePort">
    <soap:address location="https://webservice.mp.b.airclic.com:443/webservice/product/fieldservice/v1/Webservice"/>
    </port>
    </service>
    </definitions>
    Following is the pl/sql code using UTL_DBWS
    DECLARE
    l_service UTL_DBWS.service;
    l_call UTL_DBWS.call;
    l_wsdl_url VARCHAR2(32767);
    l_namespace VARCHAR2(32767);
    l_service_qname UTL_DBWS.qname;
    l_port_qname UTL_DBWS.qname;
    l_operation_qname UTL_DBWS.qname;
    l_input_params UTL_DBWS.anydata_list;
    soap_request xmltype;
    l_result xmltype;
    result_output VARCHAR2(32767);
    BEGIN
    l_wsdl_url := 'https://webservice.mp.b.airclic.com/webservice/product/fieldservice/v1/Webservice?WSDL';
    l_namespace := 'http://webservice.airclic.com/';
    dbms_output.put_line ('1');
    l_service_qname := UTL_DBWS.to_qname(l_namespace, 'Webservice');
    dbms_output.put_line ('2');
    l_port_qname := UTL_DBWS.to_qname(l_namespace, 'WebservicePort');
    dbms_output.put_line ('3');
    l_operation_qname := UTL_DBWS.to_qname(l_namespace, 'sendAuthenticationResponse');
    dbms_output.put_line ('4');
    l_service := UTL_DBWS.create_service (
    wsdl_document_location => URIFACTORY.getURI(l_wsdl_url),
    service_name => l_service_qname);
    dbms_output.put_line ('5');
    l_call := UTL_DBWS.create_call (
    service_handle => l_service,
    port_name => l_port_qname,
    operation_name => l_operation_qname);
    dbms_output.put_line ('6');
    UTL_DBWS.SET_PROPERTY(l_call,'USERNAME',<username to access wsdl>);
    dbms_output.put_line ('7');
    UTL_DBWS.SET_PROPERTY(l_call,'PASSWORD',<password>);
    dbms_output.put_line ('8');
    utl_dbws.set_property(l_call,'OPERATION_STYLE', 'document');
    dbms_output.put_line ('9');
    soap_request := xmltype.createxml('<?xml version="1.0" encoding="UTF-8"?>
    <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
    <ns2:sendAuthenticationResponse xmlns:ns2="http://webservice.airclic.com/">
    <authenticationResponse>
    <correlationId>4646735802698040711:[email protected]</correlationId>
    <success>true</success>
    <username>changlanih</username>
    <password>abcd1234</password>
    <firstName>hero</firstName>
    <lastName>changlani</lastName>
    <email>[email protected]</email>
    <active>true</active>
    <timeZone>eastern</timeZone>
    <group>Northeast</group>
    <role>Service Manager</role>
    </authenticationResponse>
    </ns2:sendAuthenticationResponse>
    </S:Body>
    </S:Envelope>');
    l_result := UTL_DBWS.invoke ( l_call,soap_request);
    UTL_DBWS.release_call (call_handle => l_call);
    UTL_DBWS.release_service (service_handle => l_service);
    result_output := l_result.getstringval;
    dbms_output.put_line('web svc output ===> ' || result_output);
    END;
    Following is the error from pl/sql code
    1
    2
    3
    4
    DECLARE
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception: java.lang.IllegalAccessException: error.build.wsdl.model: oracle.j2ee.ws.common.tools.api.WsdlValidationException:
    Failed to read WSDL from https://webservice.mp.b.airclic.com/webservice/product/fieldservice/v1/Webservice?WSDL:
    HTTP connection error code is 401
    ORA-06512: at "SYS.UTL_DBWS", line 193
    ORA-06512: at "SYS.UTL_DBWS", line 190
    ORA-06512: at line 20
    Notes
    The program fails at following line of code -
    l_service := UTL_DBWS.create_service (
    wsdl_document_location => URIFACTORY.getURI(l_wsdl_url),
    service_name => l_service_qname);
    Web services are SSL.
    The WSDL is at https location and needs username/password for access. The username/password to access WSDL are set using UTL_DBWS.SET_PROPERTY
    To access the SSL site, I have imported the CA in Oracle Wallet, JVM home and JDK home.
    Can anyone tell me what am I doing wrong here. I am not able to even establish connection to web service host.
    This is very frustrating - Oracle has no examples on how to access a SSL Web Service (that needs authentication) from Database.
    This is effecting our project deadlines ......... any help would be greatly appreciated.
    Thanks.

    Hi,
    I presume your Web Service needs HTTP (BASIC?) Authentication.
    All this needs is setting the following 2 properties, which as can be seen, you are setting....
    UTL_DBWS.set_property(l_call, 'USERNAME', '<username>');
    UTL_DBWS.set_property(l_call, 'PASSWORD', '<pwd>');
    This should work as long as your DBWS Callout Utility was downloaded from OTN after June 2008, and it's version is atleast 10.1.3.1.
    Following is a sample code snippet that was tested successfully for this :
    Declare
    l_service UTL_DBWS.service;
    l_call UTL_DBWS.call;
    l_result sys.XMLTYPE;
    l_request sys.XMLTYPE;
    BEGIN
    l_service := UTL_DBWS.create_service(null);
    l_call := UTL_DBWS.create_call(l_service);
    UTL_DBWS.set_target_endpoint_address(l_call, 'http://xxx.oracle.com:8888/basic/MyWebService1SoapHttpPort');
    UTL_DBWS.set_property(l_call, 'USERNAME', 'username');
    UTL_DBWS.set_property(l_call, 'PASSWORD', 'pwd');
    UTL_DBWS.set_property(l_call, 'OPERATION_STYLE', 'document');
    UTL_DBWS.set_property(l_call, 'SOAPACTION_USE', 'true');
    UTL_DBWS.set_property(l_call, 'SOAPACTION_URI', 'http://xxx.oracle.com:8888/basic/MyWebService1SoapHttpPort');
    l_request := XMLTYPE('<Z_CENTRICITY_GET_DOCLIST
    xmlns:urn="urn:sap-com:document:sap:rfc:functions">' ||
    '<I_INCLUDE_OLD_VERSIONS></I_INCLUDE_OLD_VERSIONS>' ||
    '<I_INSTITUTION>0001</I_INSTITUTION>' ||
    '<I_PATIENT_NR>0000000181</I_PATIENT_NR>' ||
    '</Z_CENTRICITY_GET_DOCLIST>');
    l_result := UTL_DBWS.invoke(l_call, l_request);
    UTL_DBWS.release_call (call_handle => l_call);
    UTL_DBWS.release_service (service_handle => l_service);
    EXCEPTION
    WHEN OTHERS THEN
    dbms_output.put_line(sqlcode || ' ' || sqlerrm);
    END;
    Hope this helps,
    Yogesh

  • Invoking P6 web services using PL/SQL block

    Hi Team,
    We have requirement like
    Oracle jobs will invoke PL/SQL code to authenticate and establish a session with the P6 Web services.
    Web service will export Project data from One Primavera database as an XML and copy to common location.
    Then this XML project files will be imported into archive database.
    Could anyone help me how I can establish sessio between Pl/SQL and P6 webservices?
    Please let me know if you need any more information.
    Regards,
    Santosh
    Edited by: SantoshV Singh on Apr 29, 2013 10:09 PM

    It will be no different than connecting to any web services through PL/SQL which is pretty hard to do and if you are asking how to do it then you have a steep learning curve ahead of you and not a great deal in the way of good examples out there.
    I wouldn't even attempt the approach you suggest.  Instead I would probably write a Java application to do it and use your PL/SQL to enqueue a message that routed to the Java application.  Then the java application with the Web Services support and P6 client would be easier to do what you want with web services.

  • 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

  • How to invoke a Web Service from PL/SQL with Complex Type as  input.

    Hello,
    I am trying to invoke a web service from PL/SQL using the UTL_DBWS package.
    The web service expects a complex type as input (defined below):
    <xs:complexType name="MsgType">
    <xs:sequence>
    <xs:element name="sender" type="xs:string"/>
    <xs:element name="messageId" type="xs:string"/>
    <xs:element name="messageType" type="xs:string"/>
    <xs:element name="dateSent" type="xs:date"/>
    </xs:sequence>
    </xs:complexType>
    How to construct input to this in PL/SQL Procedure?
    Has any body tried this before?
    An exmaple will be helpful.
    Thanks

    Dear,
    I have read your article, it is useful for me. But I cannot Apply to my case. Please kindly help me. Thank you.
    When running, the error occurs:
    1:39:31 Execution failed: ORA-20000: soapenv:Server.userException - org.xml.sax.SAXParseException: Attribute name &quot;password&quot; associated with an element type &quot;user&quot; must be followed by the &apos; = &apos; character.
    My webservice Url: http://abc.com.vn:81/axis/ABC_WS_TEST.jws?wsdl
    I make PL/SQL (similiar as your example)
    FUNCTION INVOKESENDMT
    RETURN VARCHAR2
    AS
    l_request soap_api.t_request;
    l_response soap_api.t_response;
    l_return VARCHAR2(32767);
    l_url VARCHAR2(32767);
    l_namespace VARCHAR2(32767);
    l_method VARCHAR2(32767);
    l_soap_action VARCHAR2(32767);
    l_result_name VARCHAR2(32767);
    p_zipcode VARCHAR2(160);
    BEGIN
    --p_zipcode:='''TEST'' ; ''TEST'';''84912187098'';''84912187098'';''0'';''8118'';''1'';''000001'';''ThuNghiem'';''''';
    p_zipcode:='TEST';
    -- Set proxy details if no direct net connection.
    --UTL_HTTP.set_proxy('myproxy:4480', NULL);
    --UTL_HTTP.set_persistent_conn_support(TRUE);
    -- Set proxy authentication if necessary.
    --soap_api.set_proxy_authentication(p_username => 'TEST',
    -- p_password => 'TEST');
    l_url := 'http://abc.com.vn:81/axis/ABC_WS_TEST.jws';
    l_namespace := 'xmlns="' || l_url || '"';
    l_method := 'sendMT';
    l_soap_action := l_url || '#sendMT';
    l_result_name := 'sendMTResponse';
    l_request := soap_api.new_request(p_method => l_method,
    p_namespace => l_namespace);
    soap_api.add_parameter(p_request => l_request,
    p_name => 'user password sender receiver chargedflag servicenumber messagetype messageid textcontent binarycontent',
    p_type => 'xsd:string',
    p_value => p_zipcode);
    l_response := soap_api.invoke(p_request => l_request,
    p_url => l_url,
    p_action => l_soap_action);
    l_return := soap_api.get_return_value(p_response => l_response,
    p_name => l_result_name,
    p_namespace => l_namespace);
    RETURN l_return;
    END;

  • Creating web service from pl/sql procedure

    Hello.
    I need to create a web service from pl/sql procedure and i chose JDeveloper for this implementation. I have wsdl, but I never created web services. So, I created web service with document/literal message format.
    But I have several troubles:
    1. All element names have lower case letters.
    2. The SOAP envelope must begin from words soapenv:Envelope but i have soap:Envelope.
    3. And operation name has tail like "Element".
    I know bad way for implement 1 and 3 points. It's a modification of java_wsdl_mapping.xml and wsdl files. But if I want to add new method to my service all changes will be cleaned. It's not critical but inconvenient to support.
    But for point 3 i have no ideas.
    This task is very important for me. Can somebody help me?
    JDeveloper 10.1.3.3
    Regards,
    Aleksey

    http://www.oracle.com/technology/obe/obe1013jdev/10131/wsfromplsqlpackage/devwsfrom%20plsql.htm
    Frank

  • Creating Web service for PL/SQL Procedure with Complex Data Types

    I need to created web service for PL/SQL Procedure with Complex Data types like table of records as parameters, how do we map the pl/sql table type parameters with web service, how to go about these?

    Hello,
    When you are creating a service from a Stored Procedure, the OracleAS WS tools will create necessary Java and PL wrapper code to handle the complex types (table of record) properly and make them compatible with XML format for SOAP messages.
    So what you should do is to use JDeveloper or WSA command line, to create a service from your store procedure and you will see that most of the work will be done for you.
    You can find more information in the:
    - Developing Web Services that Expose Database Resources
    chapter of the Web Service Developer's guide.
    Regards
    Tugdual Grall

  • Error invoking a web service within another web service

    Hi all!
    I have to develop a web service which needs to invoke another web service, thus the first web service is acting as a client of the second one. To get this, the first web service uses the proxy provided by the home page of the second one. However, when the first service invokes the second service, the body within the soap message is modified in such a way that it is not valid for the second service, because some namespaces declarations are added, in spite of the fact that they already exist. Then, I find the following:
    Body of the SOAP request created by the first web service:
    <a:request attribute1="urn:attribute:one"
    xmlns:a="urn:namespace:one" xmlns:b="urn:namespace:two">
    <b:body>Hello</b:body>
    </a:request>
    Body of the SOAP request received by the second web service:
    <a:request xmlns:a="urn:namespace:one"
    attribute1="urn:attribute:one"
    xmlns:a="urn:namespace:one" xmlns:b="urn:namespace:two">
    <b:body xmlns:b="urn:namespace:two">Hello</b:body>
    </a:request>
    I have also tried to run a client using this proxy outside the web service, and everything is ok. So, from my point of view, the problem is when running the proxy inside a web service. I wonder if I have to do something special with this proxy in order to use it within a web service.
    Has anybody run into this situation?
    Could anybody be so kind as to tell me how to solve it or if, on the contrary, it is an oc4j bug, please?
    Thank you very much in advance.
    Inma.

    Hi,
    Thanx it is working now.
    BTW can you give me some urls with info of this kind of setting which i need to do for other kind of integarions in J2EE platform.Sorry if i am asking too much as i am a starter in this technology.

  • Invoking a Web Service using XI 2.0

    Hi all,
    I am attempting to create a scenario where an SAP application invokes a web service through XI 2.0.
    I have created an ABAP proxy to allow my ABAP to start the call process and have set up the message interfaces within the Integration Directory.
    I want XI to receive a call from this proxy and then act as the client to an existing Web Service.. calling it and bringing back a response... but it doesn't look like I can import the existing WSDL as a I would have expected.
    So... instead I have exported the Message Interface for the "out of XI" portion of the interface as a WSDL and have asked the Web Service provider to amend their service according to this XI generated WSDL.
    My difficulty now is how to use the SOAP adapter. Within the Integration Directory I presumably need to define the endpoint with XI Connectivity but I am not sure how to fill in the URL address of the SOAP adapter...
    Any help on how to configure the actual SOAP adapter to fulfill this requirement would be great too.
    I have looked around the boards to see if I could work this out from previous posts but without success so far.
    It's a synchronous scenario and basically should look like...
    ABAP Proxy->XI->SOAP Adapter->Web Service->XI->ABAP Proxy
    Many thanks,
    Gordon

    Hi Gordon,
    here is an example for SOAP-Adapter config:
    # Bubble adapter java class
    classname=com.sap.aii.messaging.adapter.ModuleBubble
    # Sets the bubble module helper that can instantiate your bubble bag
    Bubble.Helper=com.sap.aii.messaging.adapter.ModuleBubbleHelperXMBWSImpl
    ###### Part 0 (FromWS and ToWS) : common part ######
    # Keeps the XMB headers in web service messages
    XMBWS.KeepHeaders=false
    # Encodes the xmb headers into a special HTTP header string x-xmb_ws_encoded
    XMBWS.UseEncoded=false
    # The target URL for the web service, to which the adapter sends web service messages.
    # The address is part of the WSDL
    XMBWS.TargetURL=http://www.extensio.com:8080/ExtensioInfoServer/servlet/rpcrouter
    # Proxy configuration from SAP
    XMBWS.proxyHost=PrOxY
    XMBWS.proxyPort=8080
    # The port and path where the adapter waits for XMB messages from clients.
    XMBWS.XMBPort=8400
    XMBWS.XMBPath=/soap/stockquote
    # The default SOAPAction HTTP request header to the web Service server
    # The SoapAction is part of the WSDL
    XMBWS.DefaultSOAPAction=
    Of course you have to set URL, proxy and SOAP-action to your belongings.
    You define the endpoint as:
    "http://<Adapter-Server>:<XMBPort><XMBPath>"
    in this example:
    "http://localhost:8400/soap/stockquote"
    Stefan

  • Errors calling oracle web service from pl/sql

    Oracle application server version 10.1.2.2.0
    Jdeveloper version 10.1.2.1.0
    I have published a function of an oracle database package as a web service using jdeveloper by creating a connection to my database and right clicking on the package and selecting publish as a web service. I accepted all the defaults and deployed the web service to my application server also using jdeveloper. I have been able to invoke the web service from the url which was generated.
    I now want to invoke this web service from another pl/sql procedure in the same database as the function I've published as a web service using the utl_dbws facility but get the following error
    ORA-29532: Java call terminated by uncaught Java exception: javax.xml.rpc.soap.SOAPFaultException: No Deserializer found to deserialize a 'http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/:p_group_id' using encoding style 'null'. [java.lang.IllegalArgumentException]
    I have amended the wsdl to look like this
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <!--Generated by the Oracle JDeveloper 10g Web Services WSDL Generator-->
    <!--Date Created: Tue Sep 29 12:32:20 BST 2009-->
    <wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:s="http://www.w3.org/2001/XMLSchema"
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:tns="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/"
    xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    targetNamespace="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
    <wsdl:types>
    <s:schema elementFormDefault="qualified"
    targetNamespace="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/">
    <s:element name="totalliveusers">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="p_group_id" type="s:string"/>
    </s:sequence>
    </s:complexType>
    </s:element>
    <s:element name="totalliveusersResponse">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="totalliveusersResult" type="s:int"/>
    <s:element minOccurs="0" maxOccurs="1" name="p_group_desc" type="s:string"/>
    </s:sequence>
    </s:complexType>
    </s:element>
    </s:schema>
    </wsdl:types>
    <wsdl:message name="totalliveusersSoapIn">
    <wsdl:part name="parameters" element="tns:totalliveusers"/>
    </wsdl:message>
    <wsdl:message name="totalliveusersSoapOut">
    <wsdl:part name="parameters" element="tns:totalliveusersResponse"/>
    </wsdl:message>
    <wsdl:portType name="totalliveusersSoap">
    <wsdl:operation name="totalliveusers">
    <wsdl:input message="tns:totalliveusersSoapIn"/>
    <wsdl:output message="tns:totalliveusersSoapOut"/>
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="totalliveusersSoap" type="tns:totalliveusersSoap">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="totalliveusers">
    <soap:operation
    soapAction="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/totalliveusers"
    style="document"/>
    <wsdl:input>
    <soap:body use="literal"/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use="literal"/>
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="totalliveusers">
    <wsdl:port name="totalliveusersSoap" binding="tns:totalliveusersSoap">
    <soap:address location="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS"/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
    The function has an in varchar2 parameter and an out varchar2 parameter and returns a number
    Can anyone help?

    Hi,
    On way we can call a web service is to pass the Web Service URL to UTL_HTTP package:
    Sample Web Service URL
    ===================
    lv_url :=
    'http://67.97.189.151:8888/plsqlsample/dbfunc?invoke=placeOrder'
    || '&'
    || 'param0=1'
    || '&'
    || 'param1=1'
    || '&'
    || 'param2=1';
    Sample Call using UTL_HTTP
    =====================
    SELECT UTL_HTTP.request (lv_url)
    INTO lv_result
    FROM DUAL;
    Thank you.
    Regards,
    Balu

  • 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

  • Calling a Web Service from PL/SQL Procedure

    How can you call a web service from a pl/sql package , also is it valid to call a web service from pl/sql according to Fusion Standards..

    Hi,
    On way we can call a web service is to pass the Web Service URL to UTL_HTTP package:
    Sample Web Service URL
    ===================
    lv_url :=
    'http://67.97.189.151:8888/plsqlsample/dbfunc?invoke=placeOrder'
    || '&'
    || 'param0=1'
    || '&'
    || 'param1=1'
    || '&'
    || 'param2=1';
    Sample Call using UTL_HTTP
    =====================
    SELECT UTL_HTTP.request (lv_url)
    INTO lv_result
    FROM DUAL;
    Thank you.
    Regards,
    Balu

  • Help Urgent : Invoking SMS Web Services Using ABAP FM HTTP_POST

    Dear Gurus,
    Our client requirement is in such a way that ,
    They want to invoke web services for sending SMS through ABAP program.
    Please suggest the way .
    I am using FM HTTP_POST in order to call the URL for web service for SMS.
    My URL is as follows,
    'http://IP ADDRESS :PORT /invoke/crm_sms/send_crm_sms?&mobile_no=9987536748&message=HI' .
    and my code is as follows,
    ========================================================================
    report ztesturl.
    data : begin of t_request_body occurs 0 ,
            body(1025),
            end of t_request_body.
    data : begin of t_request_header occurs 0 ,
            body(1025),
            end of t_request_header.
    data : str(20) value '9987536748' ,int(20) value 'text',uri(460),
           status_code(100),
           status_text(100),
           len type i.
    data : begin of t_response_body occurs 0 ,
            body(1025),
            end of t_response_body.
    data : begin of t_response_header occurs 0 ,
            body(1025),
            end of t_response_header.
    uri = 'http://IP ADDRESS :PORT /invoke/crm_sms/send_crm_sms?mobile_no=9987536748&message=HI' .
    concatenate 'mobile_no=' str into t_request_body-body.
    append t_request_body.
    concatenate 'message=' int into t_request_body-body.
    append t_request_body.
    move: url to t_request_header-body.
    append t_request_header.
    call function 'HTTP_POST'
      exporting
        absolute_uri                = uri
        request_entity_body_length  = 300
        blankstocrlf              = 'X'
        proxy                       = 'IP Address:Port'                  ===> Same as Interner Tools -> Connection
        proxy_user               = EMAIL ID                            ===> Which i am using Userid for Internet
        proxy_password       = 'password123'
      importing
        status_code             = status_code
        status_text              = status_text
        response_entity_body_length = len
      tables
        request_entity_body         = t_request_body
        request_headers             = t_request_header
        response_entity_body        = t_response_body
        response_headers            = t_response_header.
    I am getting Following log in t_response_body
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    2 3 5                                             
    ERROR                                             
    6                                             
    Cache Accesss
    7                                             
    8                                             
    9 While trying to retrieve the URL: 10 http://IP ADDRESS :PORT /invoke/crm_sms/send_crm_sms?
    11
    12 The following error was encountered:
    13                              
    14
    15 16 Cache Access Denied. 17 18
    19
    20 21
    Sorry, you are not currently allowed to request: 22
        http://IP ADDRESS :PORT /invoke/crm_sms/send_crm_sms?
    23 from this cache until you have authenticated yourself. 24
    25 26
    27 You need to use Netscape version 2.0 or greater, or Microsoft Internet 28 Explorer 3.0, or an HTTP/1.1 compliant browser for this to work. Please 29 contact the cache administrator if you have 30 difficulties authenticating yourself or
    31 change your default password.
    32                    
    33
    34                                             
    35                                             
    36 Generated Thu, 26 Jun 2008 11:18:54 GMT by ProxyServer.VakolaProxy (Squid/2.4.STABLE7) 37                                                                                
    Thanks in advance.
    With Regards,
    Rajesh C

    slen = strlen( user ).
    call 'AB_RFC_X_SCRAMBLE_STRING'
      id 'SOURCE'      field user        id 'KEY'         field key
      id 'SCR'         field 'X'         id 'DESTINATION' field user
      id 'DSTLEN'      field slen.
    slen = strlen( password ).
    call 'AB_RFC_X_SCRAMBLE_STRING'
      id 'SOURCE'      field password    id 'KEY'         field key
      id 'SCR'         field 'X'         id 'DESTINATION' field password
      id 'DSTLEN'      field slen.

  • Unknown site error while deploying web services using OC4J

    Hi,
    I have been testing the deploying webservices examples using demo.zip on OTN site.
    I have trouble in binding the web application name to stand alone OC4J.
    I am running stand alone OC4J server fine. I verified the website http://localhost:8888, which is running fine.
    If I issue the command
    java -jar admin.jar ormi://localhost:23791 admin password1 -bindwebapp demo_ejb_web_service HelloService_web http://localhost:8888/ sejb_webservices
    I get error
    oracle.oc4j.admin.internal.DeployerException: Unknown site: http://localhost:8888/
    What is the http-web-site address that needs to be given for binding web app, if I am running local standalone OC4J with no default port changes?
    Thanks,
    Mohan

    Eric,
    Thanks for the response. But, still I am not able to bind web-application to OC4J.
    Here is how my server.xml has defined the web-site tag:
    <web-site default="true" path="./http-web-site.xml" />
    My http-web-site.xml has following web-site tag:
    <web-site port="8888" display-name="OC4J 10g (10.0.2) HTTP Web Site">
    <default-web-app application="default" name="defaultWebApp"/>
    <web-app application="default" name="dms0" root="/dms0" access-log="false" />
    <web-app application="default" name="dms0" root="/dmsoc4j" access-log="false" />
    <web-app application="default" name="admin_web" root="/adminoc4j"/>
    <access-log path="../log/http-web-access.log"/>
    </web-site>
    I used the following command to bind the example web service:
    java -jar c:\XtendTools\oc4j\j2ee\home\admin.jar ormi://localhost admin password1 -bindWebApp demo_ejb_service HelloService_web default-web-site /sejb_services
    I get "oracle.oc4j.admin.internal.DeployerException: Unknown site: default-web-site" error.
    I tried to use following names as http-web-site, but nothing works.
    "http://localhost:8888"
    "dms0"
    "adminoc4j"
    I downloaded stand alone OC4J 10.1.2 from OTN and tried these samples.
    Your help will be appreciated.
    Thanks,
    Mohan

Maybe you are looking for

  • Backing-up: External Hard Drive to External Hard Drive with LR5

    I use LR5 on a Mac laptop. My catalog, backups, original images, presets…EVERYTHING is on the (main) external hard drive. No problems there. I backup my catalog regularly. I was told to use Carbon Copy Cloner to periodically clone the main external h

  • Typewriter in Acrobat Pro 9

    Typewriter in Acrobat Pro 9 is now only typing in 'Comments' & not on the page. What is wrong?  I opened a pdf document > clicked the typewriter button > the usual 'A_' showed > I clicked on the document were I wanted to enter text > when finished I

  • Indesign Javascript and xml structure

    Hi to all I am new to program javascript in Indesign, and I am looking for some example on how modify the xml structure inside a document using a javascript script. i.e. if I have a structure like this in the original document: root section tag1 tag2

  • Use a converter?

    I imagine a number of people have run into this, but I haven't been able to find anything on it yet... Our users want the phone number to be broken into three fields representing the 3 part of a US phone number. However, we are sharing objects with a

  • Available System Updates | Status = Canceling (2 days this)

    ZCM on the SLES10x64 Configuration | Available System Updates I see: Update for ZCM (10.3.1) Jul 28, 2010 My steps: 0) check this Update 1) Action 2) Download Updates ... 3) When status was 76 % -..... Power OFF... ;( 4) wait 4h. PowerOF | Server Up