Web-service call from Apache to Glassfish

I have written static HTML pages which run on Apache server and I give a web-service call which is present on Glassfish server.
I want to calculate the number of rows present in the selected Excel file. For this, I make a web-service call through Ajax; where I send a file object to it, which then, reads the file and returns the number of rows present in that file.
But, I could not make an Ajax POST for a file object.
For Example, I have an HTML form containing a file object (for which I have to calculate the number of rows). I have to send this form to the web-service for processing the file.
My form is like this:
<form id="myForm" action="http://www.mydomain.com:8080/myApp/jersey/myClass/calculateRows" method="POST" enctype="multipart/form-data" accept-charset="utf-8" name="submitForm">
        input id ="workbook" name="workbook" type="hidden"/>
</form>
For this I used:
    $("#myForm").ajaxSubmit(function(noOfRows)
       alert(noOfRows);
In the web-service, I gave:
    @Path('myClass')
    public class myClass
      @POST
      @Path("calculateRows")
      public Response calculateNoOfRows(@Context HttpServletRequest request)
        int noOfRows = 0;
        String wbk = request.getParameter("workbook");
        for (Part part : request.getParts())
             if (!part.getName().equalsIgnoreCase("workbook"))
                  //code to calculate number of rows
                  noOfRows = 100;   (for example)
        ResponseBuilder builder = null;
        builder = Response.ok(String.valueOf(noOfRows));
        builder.header("Access-Control-Allow-Origin", "*");
        builder.header("Access-Control-Allow-Methods","POST");
        builder.header("Allow-Control-Allow-Headers", "Origin,Connection,Keep-Alive,Accept-Encoding,Accept-Charset,Accept,User-Agent,Host,X-Requested-With");
        return builder.build();
In the Firebug, the above given URL does not appear in the Console tab.
And, in the Net tab, I see like this:
    OPTIONS http://www.mydomain.com:8080/myApp/jersey/myClass/calculateRows
I am not able to resolve the problem. Can anyone help?

Hi,
I would recommend implementing the web-service callout logic in a custom cachestore/cacheloader (see the CacheLoader.load() method) and configure your rwbm with your cachestore implementation.
While subclassing RWBM and overriding functionality can be done, the CacheLoader interface is the intended method designed to accomplish this kind of task. RWBM internal implementations may perform other internal bookkeeping and may vary over time.
See also:
http://download.oracle.com/otn_hosted_doc/coherence/351/com/tangosol/net/cache/CacheLoader.html
http://wiki.tangosol.com/display/COH35UG/cachestore-scheme
http://wiki.tangosol.com/display/COH35UG/Sample+CacheStores
thanks,
-Rob

Similar Messages

  • Configuring SSL to make a HTTPS web Service call from XI

    Hi All,
    We are making a <b>https web service call</b> using soap adapter from XI. Looking at the various posts and SAP help links, we are configuring SSL for the same.
    The procedure given in SAP help has been followed to configure SSL but with no luck. If someone had done this could you please give a <b>step by step procedure</b> to configure SSL, we might have missed out on something.
    Also are there are <b>any other settings apart from SSL</b> to be done to make a  https web service call using soap adapter from XI.
    Cheers,
    Chandra

    user13046122 wrote:
    I have an old pl/sql "helper" package, originally written to make SOAP Web Service calls from the database - it uses UTL_HTTP to invoke the target services.
    I now need to make SOAP Web Service calls - from an 8.1.7.4 database
    But the version of UTL_HTTP inside 8.1.7.4 does not contain the functions needed in the helper package
    Can anybody suggest a means of making SOAP Web Service calls from an 8.1.7.4 database ?I think you'll be very lucky to find anyone here who still has access to a version of Oracle that is that old.... I mean... that's like what? 15 years old at least? I'm surprised you've still got hardware that can run that.
    It would probably help if you could post what code you've got and explain which function(s) it's complaining about, as I doubt people will want to guess.

  • Making Web Service calls from a Form in the WorkSpace

    I am getting conflicting information about this, so I hope someone here could clarify it. TIA.
    This is what I want to do:
    after a form is displayed/launched in the WorkSpace,
    when the user Tabs out of a field (Exit event) on the form,
    I want to make a Web Service call from the form,
    get the result from the WebService,
    and use the Result to populate another field on the form.
    I know for certain that this works if I Reader-Extend the form,
    and I set the JavaScript at the Exit event (to execute WebService call)
    as "Run At Client".
    The question is:
    can I make the WebService calls without Reader-Extending the form???
    I have been told that, yes you can,
    but *only if* you let the JavaScript "Run At Server".
    I tried that, but it caused the Reader to crash.
    Some other people told me,
    no you can not,
    even if you "Run At Server", the form still needs to be Reader-Extended,
    when using it in the WorkSpace environment.
    So, what is the truth? can someon tell me?
    Can I make WebServers calls from the Server-side at all?
    Do I really need to Reader-Extend the form even if calling it from server side?
    What exactly is it SUPPOSED to work?
    thanks

    yes, thank you both. I got the fix from Adobe Tech Support last week. It's working.
    The fix I got included a rather complex looking "Submit Service" though. Makes me wonder how a regular user would know that he needs to write such a Submit Service?? and even if he knows that he needs a special Submit Service, would he know how to write it??? I found no documentation for this type of things either.
    Shouldn't this solution be published somewhere in Adobe's website? Dev Lab perhaps?

  • Special Character XML Web Service call from Flex

    Hi,
    Let me first give a little background.
    I have to query and return data in XML format. To do so, I have created a custom DSC component. In cases where XML has special characters, LC throws error saying that XML is not properly formed. To over come this issue I used CDATA tag at DSC component. Now LC works as it should and I returns correct result.
    I have a web service call from Flex to get this XML result. Every time i trigger this web service I get an error message saying </document> tag is missing.
    I understand in Flex, web service returned data is wrapped in CDATA tag, thats what i causing all this issue.
    I am not sure, how to handle this situation, I am sure this is a common problem and there should be ways to work around it.
    I would really appreciate if any one could point me in the right direction.
    Thank you ..

    The web service has four operations in it, I need pingQuery operation execution code since it doesnot need any input value.
    I have used code something like this.. Any one please correct me if I am wrong..
    <mx:WebService 
    <mx:WebService> id="webService" wsdl=""https://hydrogen.csd.sc.edu/axis2/services/AcademicHistoryService?wsdl
    >
    <mx:operation name="pingQuery"resultFormat="
    object"result="resultHandler(event);"
    fault="faultHandler(event);"
    >
    <mx:request>
    <PingQuerySpecification>
    <value>
    fsdf
    </value>
    </PingQuerySpecification>
    </mx:request>
    </mx:operation>
    </mx:WebService>
    private function resultHandler(evt:ResultEvent):void {Alert.show(ObjectUtil.toString(evt.result));
    private function faultHandler(evt:FaultEvent):void {Alert.show(evt.message.toString());

  • Web service call from a ReadWriteBackingMap

    We are thinking of making a web service call from a ReadWriteBackingMap
    <cachestore-scheme>
    <class-scheme>
    <class-name>
    We will extend ReadWriteBackingMap class and override load() method to make a call to a web service.
    This cache will be read only data and will hold relatively static data like list of c
    ountries.
    We expect to use Spring framework/JDK 1.5/WS security to make this web service call. We hope to
    have the jar/config files available in server classpath when we start coherence servers.
    1. Do you see any issues with this approach?
    2. Any best practices?
    3. Server resources(memory etc) will be shared between the server java process and this call to
    web services, getting the xml, parsing the data etc. Any issues with that?

    Hi,
    I would recommend implementing the web-service callout logic in a custom cachestore/cacheloader (see the CacheLoader.load() method) and configure your rwbm with your cachestore implementation.
    While subclassing RWBM and overriding functionality can be done, the CacheLoader interface is the intended method designed to accomplish this kind of task. RWBM internal implementations may perform other internal bookkeeping and may vary over time.
    See also:
    http://download.oracle.com/otn_hosted_doc/coherence/351/com/tangosol/net/cache/CacheLoader.html
    http://wiki.tangosol.com/display/COH35UG/cachestore-scheme
    http://wiki.tangosol.com/display/COH35UG/Sample+CacheStores
    thanks,
    -Rob

  • External Web services call from within Oracle Pl/SQL

    Hi there,
    can anyone guide me whether there is any option to create web services call from Oracle Stored procedure ? ( External web services are available using SOAP)
    Thanks in advance.
    Regards,
    Jatin

    http://bit.ly/Uiaies

  • Web Services call from SOA to BI Publisher

    Hi,
    I have never worked on this web service call from SOA to BI Publisher funcationality and I am strugulling to understand on how this woks.
    My requirement is that SOA will call BI Publisher on a parameter basis eg( some id) to a report and BI publisher should pick that id and execute the report and place the PDF file (file name is combination of id and date) into specific location in the FTP server and in return BI Publisher should send the response to SOA defining the file name and location of the FTP server.
    Can anyone please help on this. This is a big sore on my head.
    Thanks in advance.
    Regards,
    Apk

    Thanks for your replies.
    Actually I am working on Forms 6i version , so does same solution works on Forms 6i as well.
    Also this application is for address search, so user provides for some key like PostCode etc and then call the Webservice and it will give you list of options.
    Now user will choose and confirm one address.
    Do all this interaction possible using UTL_HTTP?
    After going through link provided , I need to implemented in following steps:-
    1) Using JDeveloper 10.1.3.1.0 Create a SOAP_REQUEST.
    2)Create a wrapper program who calls Web Service.
    3) Call this Wrapper Program from our form and PL/SQL Package.
    Please let me know if this sounds OK.
    Thanks a Ton,
    Manisha

  • Architecture/design for high volume web service calls from on Demand

    Hi,
    We have hundreds of end users (less than 600 users) that will be initiating web service calls from On Demand that will deal with both querying (stateful transaction) and inserting/updating data (stateless). Currently, we see a limitation on the number of stateless sessions (33) that can initiate web service calls. We are afraid this will lead to poor performance with the number of sessions that are allocated for stateless sessions.
    Can someone provide any design or framework information that can be implemented for high volume web service calls from On Demand? We anticipate 35K+ web service calls that will be initiated from On Demand per hour.
    Thanks.

    Hi,
    We have hundreds of end users (less than 600 users) that will be initiating web service calls from On Demand that will deal with both querying (stateful transaction) and inserting/updating data (stateless). Currently, we see a limitation on the number of stateless sessions (33) that can initiate web service calls. We are afraid this will lead to poor performance with the number of sessions that are allocated for stateless sessions.
    Can someone provide any design or framework information that can be implemented for high volume web service calls from On Demand? We anticipate 35K+ web service calls that will be initiated from On Demand per hour.
    Thanks.

  • Occasional SOAP errors when making web service calls from C#

    We have a C# application making web service calls to RFCs (non-NCO, SAP 4.7, WAS 6.40) and occasionally getting the following error:
    The 'SOAP-ENV:Envelope' start tag on line '1' does not match the end tag of 'SOAP-ENV:Envel'. Line 1, position 34560.
    This error happens randomly and can occur, not occur, and occur again for the exact same call (same data, same web service call).  I anticipate that we might have a missing configuration on one of our application servers, but don't know where to tell BASIS to look.  Any ideas or other help would be appreciated.

    That's going to be difficult.  The random nature of the error makes it impossible to reproduce (so far) in our Development and Test environments.  Since the error is coming from the SAP side, I believe I would need a sniffer on each production application server in order to try to catch this and that would result in some very large log files.  Is there any log file or other SAP transaction that might already be capturing these failures?

  • Asynchronous web service call from Redwood

    Hi Everyone,
    Build version M33.104.
    We have a scenario where we have to call an asynchronous web service.
    From the documentation i understand that the Redwood job will be in status Running until the web service completes.
    How does the call back work from the web service to Redwood? How does Redwood know the asynchronous web service job completed?
    From the documentation, the per-requisite is:
    callback to UpdateJob1 web service at ServerAddress with JobId and FinalStatus as Out parameters
    Should i create two out parameters for the web service job definition in Redwood? one JobId and another FinalStatus?
    How do i get the URL to UpdateJob1 web-service, so that i can make my web service, call it, to update the Redwood job that called it?
    thanks
    Nanda

    Hi HP,
    I included the following snippet in job source:
    //Set completion strategy to external
    jcsJobContext.setCompletionStrategy(CompletionStrategyType.External);
    I get the following error when compiled:
    JCS-102183: Compile failed for Job Definition SOAP_GlobalWeatherSoap_GetCitiesByCountry (Latest Version): SOAP_GlobalWeatherSoap_GetCitiesByCountry.java:user code 24:40:cannot find symbol symbol : variable CompletionStrategyType location: class com.redwood.scheduler.custom.SOAP_GlobalWeatherSoap_GetCitiesByCountry jcsJobContext.setCompletionStrategy(CompletionStrategyType.External);
    I am not able to find any information from the API documentation on the method setCompletionStrategy, so I'm not able to figure what type of variable am i passing, so that i can initialize it. Please shed some light on it.
    Also there is no path called Scripting > Built-In Web Services
    I have only Scripting>Published Web Services
    Thanks
    Nanda

  • Web Service call from VB Macros & web service for logging in

    Hi All,
    Is it possible to call a SAP web services from a Visual Basic macro?
    1) If yes, how to do so?
    2) Is there a standard web service through which we can login to an R/3 system?
    3) Once we are logged in can we call other web services?
    Thanks in advance!!
    Regards,
    Saurabh

    Hi Saurabh,
    ad 1) It is possible. In this Excel to SAP R/3 I posted some examples on how to call webservices from within Office 2003 applications.
    The posts are very detailed, I just didn't create a blog since feedback to scripting languages blogs is so low that I didn't find it worth to carefully author a blog.
    ad 2) Web service calls are stateless so you have to authenticate each time you call a service. Either by single sign on mechanisms or by simply hardcoding the credentials.
    hope it helps,
    anton

  • Web service call from PDF

    Hi All,
    I need your help as i got an assignment where i suppose to call web service from PDF.
    I do have Adobe live cycle server environment along with me.
    I have created an sample orchestration in workbench where it does the some calculation and i use it as web service in PDF.
    I have followed the below procedure to call web service in pdf using designer
    1. Go to file
    2. Click on the new data connection
    3. then WSDL url
    and complete the rest of procedure.
    When i click on the invoke button web service get call it prompt me for username and password and pdf works fine
    I dont want my web service to pop up any username and password when i click invoke button so i should embbed some certificates in pdf i guess.
    How do i achieve it?
    Guys do reply thanks in advance....

    Few more question related to web service call
    1. Is it free Adobe reader will not call a web service?
            Answer: If you are using Adobe Reader, you need to apply Usage Rights (through Reader Extensions) to invoke any web service.
    2. If i am trying for third party web service which may be having username and password then how do i call web service from reader without prompting username and pwd?
         Answer: With a little tweak, you can do this if you know the username and password for the external web service.
    Create a LC process and invoke the external web service from it. In the WebService activity, you can mention the required username and password.
    Now, invoke the LC process through SOAP from your PDF. This option will work without prompting the user with Login dialog.
    Please note that if you don't set appropriate permission to invoke the LC process, it will still show you up a dialog to authenticate in order to invoke the LC process.
    3. Is there any javascript available to call web service which required credentials?
          Answer: Yes, you can write JavaScript to invoke the web service with the supplied credential in the code.
    The API reference link is mentioned below.
    http://wwwimages.adobe.com/www.adobe.com/content/dam/Adobe/en/devnet/acrobat/pdfs/js_api_r eference.pdf
    Go through the SOAP methods; you will find a request object which encapsules the oAuthenticate parameter where you can mention the username and password.
    4. How do i open wsdl file in live cycle workbench?
        Answer: You can open the WSDL through a WebService activity. Drag an Web Service activity into a process and click on configure button. The first textbox is the WSDL URL field. Enter the WSDL URL and click load. You will find the WSDl content in the large text area.
    Nith

  • Web service call from pl/sql 10g

    I am having problems in calling a web service from pl/sql. This is what I followed
    Here is my wsdl
    <?xml version="1.0" encoding="UTF-8"?>
    <wsdl:definitions targetNamespace="http://svc" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://svc" xmlns:intf="http://svc" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <wsdl:types>
    <schema elementFormDefault="qualified" targetNamespace="http://svc" xmlns="http://www.w3.org/2001/XMLSchema">
    <element name="name" type="xsd:string"/>
    <element name="location" type="xsd:string"/>
    <element name="getGreetingReturn" type="xsd:string"/>
    </schema>
    </wsdl:types>
    <wsdl:message name="getGreetingResponse">
    <wsdl:part element="impl:getGreetingReturn" name="getGreetingReturn"/>
    </wsdl:message>
    <wsdl:message name="getGreetingRequest">
    <wsdl:part element="impl:name" name="name"/>
    <wsdl:part element="impl:location" name="location"/>
    </wsdl:message>
    <wsdl:portType name="PlsqlS">
    <wsdl:operation name="getGreeting" parameterOrder="name location">
    <wsdl:input message="impl:getGreetingRequest" name="getGreetingRequest"/>
    <wsdl:output message="impl:getGreetingResponse" name="getGreetingResponse"/>
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="PlsqlSSoapBinding" type="impl:PlsqlS">
    <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="getGreeting">
    <wsdlsoap:operation soapAction=""/>
    <wsdl:input name="getGreetingRequest">
    <wsdlsoap:body use="literal"/>
    </wsdl:input>
    <wsdl:output name="getGreetingResponse">
    <wsdlsoap:body use="literal"/>
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="PlsqlSService">
    <wsdl:port binding="impl:PlsqlSSoapBinding" name="PlsqlS">
    <wsdlsoap:address location="http://myServer:7001/plsqlsvc/services/PlsqlS"/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
    Here is my pl/sql
    package body pkg_my_webservice as
    vg_funciton_fnc VARCHAR2(256) := 'getGreeting';
    vg_ws_address VARCHAR2(255) := 'http://myServer:7001/plsqlsvc/services/PlsqlS';
    FUNCTION call_myfuntion(
    vp_parameter1 VARCHAR2,
    vp_parameter2 VARCHAR2)
    RETURN VARCHAR2 AS
    ol_req soap_api.t_request;
    ol_resp soap_api.t_response;
    BEGIN
    -- we initilize a new request
    ol_req := soap_api.new_request(vg_funciton_fnc,
    'xmlns="' || vg_ws_address || '"');
    -- we started to add parameters
    soap_api.add_parameter(ol_req,'name', 'partns:string',
    vp_parameter1);
    soap_api.add_parameter(ol_req,'location', 'partns:string',
    vp_parameter2);
    ol_resp := soap_api.invoke(ol_req, vg_ws_address, vg_funciton_fnc);
    -- we get back the results
    RETURN soap_api.get_return_value(ol_resp, 'getGreetingReturn', -- result tag name
    'xmlns:m="' || vg_ws_address || '"');
    exception WHEN others then
    dbms_output.put_line ( Utl_Http.get_detailed_sqlcode || Utl_Http.Get_Detailed_Sqlerrm);
    return 'exception happened';
    END call_myfuntion;
    end pkg_my_webservice;
    Here is the error
    SQL> /
    PKG_MY_WEBSERVICE.CALL_MYFUNTION('ABC','EFG')
    exception happened
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.or
    g/soap/envelope/" xmlns:xsi="http://www.w3.org/1999/XMLSchem
    a-instance" xmlns:xsd="http://www.w3.org/1999/XMLSchema"><SO
    AP-ENV:Body><getGreeting xmlns="http://myServer:7001/p
    lsqlsvc/services/PlsqlS" SOAP-ENV:encodingStyle="http://sche
    mas.xmlsoap.org/soap/encoding/"><name xsi:type="string">abc<
    /name><location xsi:type="string">efg</location></getGreetin
    g></SOAP-ENV:Body></SOAP-ENV:Envelope>
    -12535ORA-12535: TNS:operation timed out
    Any help appreciated
    Thanks

    It was found out that the server port was not open from the data-tier.

  • Web Service Call from PL/SQL

    Hi Gurus,
    I am calling a Web Service(RoadNet Application) from Oracle PL/SQL(11g Database). My code is working for simple xml type to get the response. But when I tried with a complex XML type, I am getting the response, but it does not have the complete output.
    Working Sample Code
    Here is the code and the calling block which I am using to call. This does not have any input parameters, just one output parameter.
    -----------------Start of the procedure----------------------------------------------------------------------
    create or replace
    PROCEDURE ORACLE_TO_ROADNET_PROC_TEST (p_input IN NUMBER,
                                      l_out_return OUT NUMBER)
    AS
      l_service          UTL_DBWS.service;--TransportationWebService.Service?? what is DB data service?
      l_call             UTL_DBWS.call;--TransportationWebService.
      l_wsdl_url         VARCHAR2(32767);
      l_namespace        VARCHAR2(32767);
      l_soap_env         VARCHAR2(32767);
      l_soap_enc         VARCHAR2(32767);
      l_instance         VARCHAR2(32767);
      l_schema           VARCHAR2(32767);
      l_service_qname    UTL_DBWS.qname;
      l_port_qname       UTL_DBWS.qname;
      l_operation_qname  UTL_DBWS.qname;
      l_xmltype_in       SYS.XMLTYPE;
      l_xmltype_out      SYS.XMLTYPE;
    l_xsdoc     DBMS_XMLDOM.DOMDocument;
      l_dn        DBMS_XMLDOM.DOMNode;
      l_return           NUMBER;
    BEGIN
      l_wsdl_url        := 'http://10.81.8.39:80/TransportationWebService.wsdl';
      l_namespace       := 'http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService';
      l_service_qname   := UTL_DBWS.to_qname(l_namespace, 'TransportationWebService');
      l_port_qname      := UTL_DBWS.to_qname(l_namespace, 'TransportationWebService');
      l_operation_qname := UTL_DBWS.to_qname(l_namespace, 'VersionInformation');
      l_service := UTL_DBWS.create_service (
        wsdl_document_location => URIFACTORY.getURI(l_wsdl_url),
        service_name           => l_service_qname);
      dbms_output.put_line('Created the Web Service');
      l_call := UTL_DBWS.create_call (
        service_handle => l_service,
        port_name      => l_port_qname,
        operation_name => l_operation_qname);
        dbms_output.put_line('Created the Web Service Operation');
    --UTL_DBWS.set_target_endpoint_address(l_call, 'http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService/');
    UTL_DBWS.set_property(l_call, 'USERNAME', 'SAE');
    UTL_DBWS.set_property(l_call, 'PASSWORD', 'CxzMte22');
    --UTL_DBWS.set_property(l_call, 'DOMAIN', 'rhea');
    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://www.roadnet.com/RTS/TransportationSuite/TransportationWebService/');
    l_xmltype_in := SYS.XMLTYPE('<?xml version="1.0" encoding="utf-8"?>
        <VersionInformation xmlns="' || l_namespace || '">
        <parameters>' || p_input || '</parameters>
        </VersionInformation>');
        dbms_output.put_line('Prepared the XML String to pass');
      l_xmltype_out := UTL_DBWS.invoke(call_Handle => l_call ,
                                       request     => l_xmltype_in);
    dbms_output.put_line('Invoked the Web Services');
      UTL_DBWS.release_call (call_handle => l_call);
      UTL_DBWS.release_service (service_handle => l_service);
    dbms_output.put_line('Before Reading the XML output data');
    l_return := l_xmltype_out.extract(''//ns1:VersionInformationResponse/ns1:version/text()','xmlns:ns1="http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService">').getNumberVal();
    --dbms_output.put_line('After Reading the XML output data'||l_xmltype_out);
    --dbms_output.put_line('l_return'||l_return);
    -- l_out_return := l_return;
      --dbms_output.put_line('l_dn '||l_dn);
    END ORACLE_TO_ROADNET_PROC_TEST;
    -------------------------------End Of Procedure----------------------------------------------------
    ---Call to Web Service----------------------------------------
    declare
    x_return NUMBER;
    Begin
    Oracle_to_RoadNet_proc_test (p_input => 1,
                           l_out_return => x_return);
    dbms_output.put_line(  ' x_return'||x_return);                   
    end;         
    -----------------------------------------------------------------------------Sample Code Which is not giving output
    Here is the other one which is not returing the right output. It got 3 input parameters and multiple output parameters, looks like it is not reading the inputs and not able to get the response.
    -----------------------Start of the procedure---------------------------------------------
    create or replace
    PROCEDURE ORACLE_TO_ROADNET_PROC(p_region_id IN NUMBER,
                                     p_location_type NUMBER,
                                     p_location_id   NUMBER,
                                     l_out_return OUT varchar2)
    AS
      l_service          UTL_DBWS.service;
      l_call             UTL_DBWS.call;
      l_wsdl_url         VARCHAR2(32767);
      l_namespace        VARCHAR2(32767);
      l_soap_env         VARCHAR2(32767);
      l_soap_enc         VARCHAR2(32767);
      l_instance         VARCHAR2(32767);
      l_schema           VARCHAR2(32767);
      l_service_qname    UTL_DBWS.qname;
      l_port_qname       UTL_DBWS.qname;
      l_operation_qname  UTL_DBWS.qname;
      l_xmltype_in       SYS.XMLTYPE;
      l_xmltype_out      SYS.XMLTYPE;
      l_xsdoc     DBMS_XMLDOM.DOMDocument;
      l_dn        DBMS_XMLDOM.DOMNode;
      l_locationinfo      varchar2(100);
    BEGIN
      l_wsdl_url        := 'http://10.81.8.39:80/TransportationWebService.wsdl';
      l_namespace       := 'http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService';
      l_service_qname   := UTL_DBWS.to_qname(l_namespace, 'TransportationWebService');
      l_port_qname      := UTL_DBWS.to_qname(l_namespace, 'TransportationWebService');
      l_operation_qname := UTL_DBWS.to_qname(l_namespace, 'RetrieveLocationByIdentity');
      l_service := UTL_DBWS.create_service (
        wsdl_document_location => URIFACTORY.getURI(l_wsdl_url),
        service_name           => l_service_qname);
      dbms_output.put_line('Created the Web Service');
      l_call := UTL_DBWS.create_call (
        service_handle => l_service,
        port_name      => l_port_qname,
        operation_name => l_operation_qname);
        dbms_output.put_line('Created the Web Service Operation');
    --UTL_DBWS.set_target_endpoint_address(l_call, 'http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService/');
    UTL_DBWS.set_property(l_call, 'USERNAME', 'SAE');
    UTL_DBWS.set_property(l_call, 'PASSWORD', 'CxzMte22');
    --UTL_DBWS.set_property(l_call, 'DOMAIN', 'rhea');
    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://www.roadnet.com/RTS/TransportationSuite/TransportationWebService/');
    l_xmltype_in := SYS.XMLTYPE('<?xml version="1.0" encoding="utf-8"?>
        <RetrieveLocationByIdentity xmlns="' || l_namespace || '">
        <identity>
        <regionID>' || p_region_id || '</regionID>
        <locationType>' || p_location_type || '</locationType>
        <locationID>' || p_location_id || '</locationID>
        </identity>
        </RetrieveLocationByIdentity>');
        dbms_output.put_line('Prepared the XML String to pass');
      l_xmltype_out := UTL_DBWS.invoke(call_Handle => l_call ,
                                       request     => l_xmltype_in);
    dbms_output.put_line('Invoked the Web Services');
      UTL_DBWS.release_call (call_handle => l_call);
      UTL_DBWS.release_service (service_handle => l_service);
    dbms_output.put_line('Before Reading the XML output data');
    insert into  utldbws.EBH_XMLDATA
    values
    (l_xmltype_out, sysdate);
    commit;
    select extractvalue(l_xmltype_out,'//ns1:RetrieveLocationByIdentityResponse/ns1:location/ns1:description', 'xmlns:ns1="http://www.roadnet.com/RTS/TransportationSuite/TransportationWebService">' )
    into l_locationinfo
    from dual;
    l_out_return := l_locationinfo;
    dbms_output.put_line('l_locationinfo '||l_locationinfo);
    END ORACLE_TO_ROADNET_PROC;
    ----------------------End Of the Procedure-------------------------------------------------------
    ----------------Calling Block------------------------
    DECLARE
      p_region_id VARCHAR2(50);
      p_location_type VARCHAR2(50);
      p_location_id VARCHAR2(50);
      L_OUT_RETURN VARCHAR2(100);
    BEGIN
      ORACLE_TO_ROADNET_PROC(
        p_region_id => '310',
        p_location_type => '200',
        p_location_id => '499022',
        L_OUT_RETURN => L_OUT_RETURN
      DBMS_OUTPUT.PUT_LINE('L_OUT_RETURN = ' || L_OUT_RETURN);
    END;
    -----------------------------------------------------------------------------------------------Looks like this is not reading the input parameters and not returning the output but execution is successful. Please go throguh this and let me know, if I am missing anything. If you have worked on similar Web Services, please let me know.
    Thanks in advance!
    Ravi
    Edited by: BluShadow on 16-May-2013 15:19
    added {noformat}{noformat} tags for readability.  Please read the FAQ: {message:id=9360002} and do this yourself in future posts.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    1006367 wrote:
    I am calling a Web Service(RoadNet Application) from Oracle PL/SQL(11g Database). I would not use UTL_DBWS. I had to do another web service interface recently, had a look at UTL_DBWS, and again decided not to use it. Simply put. It lacks.
    I use SOAPUI (OpenSource/free version) to interrogate the web service (read wsdl) and format a sample SOAP envelope to use.
    I then use UTL_HTTP and code a HTML POST for that web service, using the SOAPUI generated envelope as template. Supporting WSSE is also not a problem (easily done using PL/SQL).
    I posted an example of my approach in {message:id=10448611} almost a year ago - and recent experience having looked at both UTL_DBWS and the plan vanilla PL/SQL HTTP approach, I still recommend the latter.

  • Web Service call from java UDF in message mapping

    Hi,
           Is it possible to call a web service from inside a java UDF in message mapping? The webservice can be any standard one. If this is possible please let me know how this can be done.
    Regards,
    Shiladitya

    Hi Shila,
                 Hope u remember me
    Here is the standard code used to call webservice from Java UDF
    public String setSoapAction(String SOAPAction,Container container){
    try{
    DynamicConfiguration conf = (DynamicConfiguration)container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey soapurl = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/SOAP" , "THeaderSOAPACTION");
    conf.put(soapurl, SOAPAction);
    return "";
    }catch(Exception e){
    e.getMessage();
    return "";
    Regards,
    Arijit

Maybe you are looking for

  • ITunes will not start...

    I have installed and uninstalled iTunes numerous times and followed the troubleshooting guide on the support page. Every time iTunes is finished installing it says "iTunes has encountered a problem and needs to close" and then I have the option to se

  • ICloud email (Migrated from .Mac MobileMe) no longer works on older device (iOS 4.2.1)

    Hi there. Here is my question/concern. I just migrated to iCloud from MobileMe (with the same Apple ID/email I have had since it was the free iTools.com years ago). Aside from the general up and down connectivity most people are experiencing (I am su

  • HFM 9.3.1 - Consolidation - Abort

    Hi, Please suggest me on this. Having problem when I added the following in business rule. The consolidation aborts when it reaches 17%! Tops = ".I#[ICP Top].C1#AllCustom1.C2#TOTAL_SOURCE.C3#AllCustom3.C4#AllCustom4" HS.EXP "A#II_COML_C_AND_I = A#II_

  • How to add new company in JD Edwards EnterpriseOne

    Hi all I am trying to create a new company on the JD Edwards EnterpriseOne, but I dont know how to do so. I try to navigate on the General Ledger setup menus, but there i dont find the possibility to add a new company. As i was reading the implementa

  • After i installed the update of itunes, i cannot open it now.

    what must i do?