Invoking a web service via proxy

Hi,
I have requirement to invoke a web service protected by basic http authentication.
I have generated a jax-ws proxy, the proxy makes a local copy of the wsdl.
And I use the following code to invoke it:
lDAPUserAdminService = new LDAPUserAdminService();
LDAPUserAdminServiceSoap lDAPUserAdminServiceSoap = lDAPUserAdminService.getLDAPUserAdminServiceSoap();
BindingProvider bindingProvider = (BindingProvider) lDAPUserAdminServiceSoap;
Map<String,Object> rc = (Map<String,Object>)bindingProvider.getRequestContext();
rc.put(BindingProvider.USERNAME_PROPERTY, "lclient");
rc.put(BindingProvider.PASSWORD_PROPERTY, "xxxxx");
lDAPUserAdminServiceSoap.getUser()..
it works fine for the url that is used to generate the proxy.
But when I try to invoke the same service deployed on a different server using the following code:
lDAPUserAdminService = new LDAPUserAdminService(
new URL("http://10.23.48.132:7003/LDAPAdminServices/user/LDAPUserAdminService.jws?wsdl"),
new QName("http://www.openuri.org/", "LDAPUserAdminService")); *//gives 401 error*
LDAPUserAdminServiceSoap lDAPUserAdminServiceSoap = lDAPUserAdminService.getLDAPUserAdminServiceSoap();
BindingProvider bindingProvider = (BindingProvider) lDAPUserAdminServiceSoap;
Map<String,Object> rc = (Map<String,Object>)bindingProvider.getRequestContext();
rc.put(BindingProvider.USERNAME_PROPERTY, "lclient");
rc.put(BindingProvider.PASSWORD_PROPERTY, "xxxxx");
lDAPUserAdminServiceSoap.getUser()..
I get 401 unauthorized error when trying to create the proxy itself trying to access the wsdl.
Is there any way to pass credentials programatically so that the proxy can access the wsdl.
Really appreciate any help!!
Anil

Hi,
Have a look at this one...
http://www.rgagnon.com/javadetails/java-0085.html
Cheers,
Vlad

Similar Messages

  • Error during connection to https web-service via proxy-server

    Hello!
    I have created Web Service Proxy using wizard in JDeveloper. Then added some code for authorization on my corporate proxy server.
    Then I was trying to connect to two different web services
    - first one was HTTP web-service - successful
    - second one was HTTPS web-service - failed with error :
    <Error> <Net> <BEA-000903> <Failed to communicate with proxy: myproxy/myproxyport. Will try connection target_url/443 now.
    java.net.ProtocolException: Server redirected too many times (4)
         at weblogic.net.http.HttpsClient.makeConnectionUsingProxy(HttpsClient.java:433)
         at weblogic.net.http.HttpsClient.openServer(HttpsClient.java:358)
         at weblogic.net.http.HttpsClient.New(HttpsClient.java:527)
         at weblogic.net.http.HttpsURLConnection.connect(HttpsURLConnection.java:239)
         at com.sun.xml.ws.transport.http.client.HttpClientTransport.getOutput(HttpClientTransport.java:136)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:187)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:124)
         at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:121)
         at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:866)
         at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:815)
         at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:778)
         at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:680)
         at com.sun.xml.ws.client.Stub.process(Stub.java:272)
         at com.sun.xml.ws.client.sei.SEIStub.doProcess(SEIStub.java:153)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:115)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:95)
         at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:136)
         at $Proxy30.queryRange(Unknown Source)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at weblogic.wsee.jaxws.spi.ClientInstanceInvocationHandler.invoke(ClientInstanceInvocationHandler.java:84)
         at $Proxy31.queryRange(Unknown Source)
         at com.volga_dnepr.wsi.fusion.model.sched_mov.SchedMovSoap12Client.main(SchedMovSoap12Client.java:54)
    Although if i switch off proxy server everything works perfect (both HTTP and HTTPS web-services).
    What could be the problem with?

    Hi Kenneth,
    At the moment, SALT does not support the configuring of an outbound proxy server. I suspect you could use a transparent proxy server, i.e., a proxy server/router combination that proxies outgoing requests, although this isn't something we have tested. My suggestion would be to open a support case and ask for this enhancement. I think it is a reasonable thing for SALT to support.
    Regards,
    Todd Little
    Oracle Tuxedo Chief Architect

  • Invoke existing DotNet web services via B1IF soap call

    Hi All,
    I have developed my own B1IF web services and invoked them with dot net.
    I now want to invoke existing hosted web services via B1IF (Not B1IF Web Services).
    Can someone guide me using the Web Service Call (soap call).
    Can I invoke any web service via B1IF scenarios (Web Service Call) ?
    Kind Regards,
    Brenden Draper

    Hi Bastian,
    I read about it for some reason I get the following error when loading the wsdl:
    Can you maybe tell me why I get this ?
    I can access the wsdl via my browser perfectly.
    Kind Regards,
    Brenden Draper

  • Expecting response in XML format after invoking bea web service

    What should I do in order to receive the response from the web service in XML document
    (i.e. a well-formed XML document) after invoking the web service via my client
    application
    (a servlet in my case)? I would like to validate the XML document against a schema
    in my
    servlet. I deployed my web service sucessfully and followed the WSDL web page
    recommendation about creating a client. That is I used the generated stub (client
    jar file
    generated using clientgen) in my servlet. The result I received was a java object
    and not in
    XML document form.

    If you do clientgen on a WSDL, it will generate
    java types by default. You can trun this off by
    setting autotype="false" in the clientgen ant task.
    I have not tried it out, but i think this will use
    javax.xml.soap.SOAPElement instead of
    generated java types. Then you can create a
    DOM object from soap element.
    Another option is to use DII with generic
    typemapping. An example here:
    http://www.manojc.com/?sample27
    Regards,
    -manoj
    http://manojc.com
    "Michael Wong" <[email protected]> wrote in message
    news:3f1edd7c$[email protected]..
    >
    What should I do in order to receive the response from the web service inXML document
    (i.e. a well-formed XML document) after invoking the web service via myclient
    application
    (a servlet in my case)? I would like to validate the XML document againsta schema
    in my
    servlet. I deployed my web service sucessfully and followed the WSDL webpage
    recommendation about creating a client. That is I used the generated stub(client
    jar file
    generated using clientgen) in my servlet. The result I received was ajava object
    and not in
    XML document form.

  • Web Service Proxy client to invoke a Web service on SSL (Jdev 10.1.3.1)

    Hi,
    I have to develope a Web Service proxy client to invoke a web service on SSL. First I'm testing with OC4J 10.1.3.1 and JDEV 10.1.3.1 and did this:
    1) Developed a basic PL/SQL Web Service with JDEV and publish on my standalone OC4J.
    2) Made a test with a browser, it worked OK
    3) Generated a proxy client from JDev 10.1.3.1 to invoke web service, it worked OK
    --- Now make it work on SSL----
    4) Then, added SSL configuration to oc4j , generated a certificate with keytool (updated server.xml, secure-web-site.xml), and shutting down and starting the OC4j instance.
    5) Import the certificate to JAVA_HOME/jre/lib/security/cacerts
    6) Test web service from browser on https and worked OK.
    7) When tried to modified proxy client (generated in step 3) to make it work on SSL, I realized that just changing the END_POINT to the new url (https) it worked!
    Questions----
    1.- By default the proxy client generated from JDEV 10.1.3.1 knows how to deal with SSL conections?
    2.- If I dont have previously the server certificate to import it into JAVA keystore (cacerts) how could I ,from proxy client code, capture it and import it before the validation occurs... because if the certificate is not in keystore , the program fails.
    Thanks in advance
    J.

    Hi,
    Could you please provide me with the steps necessary to create a web service proxy client through JDeveloper or any other mechanism when 2 way SSL (requiring client authentication) is enabled.
    Thanks a lot in advance
    Nilesh

  • Error while invoking web services from Proxy services in OSB

    I have a Proxy Service of message type in Oracel Service Bus 10gR3 and it passes the incoming messages from a JMS Queue to Business Service of Web Services type. This Web Service is hosted in Glass Fish v3 and it's binding style is RPC. The JRE used in both the servers are 1.6.0_20. The JMS message is of Text type. The Web Services at the Glass Fish throws MessageCreationException for any content of the JMS message. However, it works fine if Business Service's test client is invoked from the OSB'S Admin Console. However, the same will not work if Proxy Service's test client is called.
    The detailed exception stack is given below :
    Thanks for the help.
    - Raj
    com.sun.xml.ws.protocol.soap.MessageCreationException: Couldn't create SOAP message due to exception: XML reader error: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
    at [row,col {unknown-source}]: [1,0]
         at com.sun.xml.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:359)
         at com.sun.xml.ws.transport.http.HttpAdapter.decodePacket(HttpAdapter.java:318)
         at com.sun.xml.ws.transport.http.HttpAdapter.access$500(HttpAdapter.java:92)
         at com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit.handle(HttpAdapter.java:501)
         at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:285)
         at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:143)
         at org.glassfish.webservices.Ejb3MessageDispatcher.handlePost(Ejb3MessageDispatcher.java:116)
         at org.glassfish.webservices.Ejb3MessageDispatcher.invoke(Ejb3MessageDispatcher.java:87)
         at org.glassfish.webservices.EjbWebServiceServlet.dispatchToEjbEndpoint(EjbWebServiceServlet.java:196)
         at org.glassfish.webservices.EjbWebServiceServlet.service(EjbWebServiceServlet.java:127)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
         at com.sun.grizzly.http.servlet.FilterChainImpl.doFilter(FilterChainImpl.java:195)
         at com.sun.grizzly.http.servlet.FilterChainImpl.invokeFilterChain(FilterChainImpl.java:139)
         at com.sun.grizzly.http.servlet.ServletAdapter.doService(ServletAdapter.java:376)
         at com.sun.grizzly.http.servlet.ServletAdapter.service(ServletAdapter.java:329)
         at com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:166)
         at com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:100)
         at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:245)
         at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791)
         at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693)
         at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954)
         at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170)
         at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135)
         at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102)
         at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88)
         at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76)
         at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53)
         at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57)
         at com.sun.grizzly.ContextTask.run(ContextTask.java:69)
         at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330)
         at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309)
         at java.lang.Thread.run(Thread.java:619)
    Caused by: com.sun.xml.ws.streaming.XMLStreamReaderException: XML reader error: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog
    at [row,col {unknown-source}]: [1,0]
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.wrapException(XMLStreamReaderUtil.java:267)
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.next(XMLStreamReaderUtil.java:95)
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.nextContent(XMLStreamReaderUtil.java:110)
         at com.sun.xml.ws.streaming.XMLStreamReaderUtil.nextElementContent(XMLStreamReaderUtil.java:100)
         at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:175)
         at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:303)
         at com.sun.xml.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:129)
         at com.sun.xml.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:354)

    Let me explain what I am trying to achieve. Our application receives data from multiple sources - from mainframe using FTP, JMS Queue and BPM application using Web Services. The data from all these sources are sending to a Web Service running in GlassFish V3. To handle this I have created three Proxy Services and one Business Service on OSB. The Business Service is of type Web Service using the same WSDL from the target Web Service.
    The Proxy Services are configured as follows:
    Proxy 1 (type - Messaging service) listens to the JMS Queue and receives JMS Text Message -> Business Service(B1) (Web Service).
    Proxy 2 (type - Messaging service Polls files from the FTP Server -> Business Service(B1) (Web Service).
    Proxy 3 (type - Web service) is invoked by the BPM application and sends a String -> Business Service(B1) (Web Service).
    All the Proxies route to the same Business Service - B1 which calls the Web Service in GlassFish. The only Proxy that works fine is Proxy 3 which is created using the same WSDL of the Web Service. In the other two proxies it thows the same exception in GlassFish as I mentioned before.
    com.sun.xml.ws.protocol.soap.MessageCreationException: Couldn't create SOAP message due to exception: XML reader error: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog at [row,col {unknown-source}]: [1,0] at com.sun.xml.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:359)
    Is this configuration correct to achieve my requirements?
    Once again thanks for the help.
    - Raj

  • Return NULL when invoke Web Service via UTL_DBWS

    Hi all,
    right now, i'm using UTL_DBWS to acces Web Service via database.. but when i'm trying to get data from WEB SERVICE, using utl_dbws.invoke , i got NULL value.
    It happened if The result more than Varchar2 / 32767 byte.
    i'have tried to change code by :
    result := sys.utl_dbws.invoke(l_call, l_input_params);
    P_clob := sys.anydata.accessCLOB(result);
    The Output IS NULL value even if the data was less than Varchar2 or 32767 byte..
    this is my script looks like ::
    declare
    service sys.utl_dbws.SERVICE;
    l_call sys.utl_dbws.CALL;
    result ANYDATA;
    wsdl_url VARCHAR2(1024);
    service_name VARCHAR2(200);
    operation_name VARCHAR2(200);
    input_params sys.utl_dbws.ANYDATA_LIST;
    p_out VARCHAR2(32767);
    p_xml XMLTYPE;
    p_clob CLOB;
    begin
    wsdl_url := 'http://127.0.0.1/Exercise/WSDL2.php?wsdl';
    service_name :='{urn:hellowsdl}hellwsdl';
    operation_name := 'getData';
    service := sys.UTL_DBWS.create_service (
    wsdl_document_location => URIFACTORY.getURI(wsdl_url),
    service_name => service_name);
    l_call := sys.utl_dbws.create_call(
    service_handle => service,
    port_name => null,
    operation_name => operation_name
    input_params(1) := ANYDATA.ConvertVarchar2('DOCCODE');
    result := sys.utl_dbws.invoke(l_call, l_input_params);
    p_out := sys.anydata.accessVarchar2(result);
    sys.UTL_DBWS.release_call (call_handle => l_call);
    sys.UTL_DBWS.release_service (service_handle => service);
    end;
    Thanx for Any Help

    The basics are simple:
    - format a valid SOAP envelope
    - use UTL_HTTP to make the call
    - process the response (typically XML output)
    Sample source code in {message:id=4205205}.

  • Invoking Siebel CRM OnDemand Web Service via BPEL

    I'm trying to invoke a Siebel CRM OnDemand Web Service via BPEL. Basically, the Siebel guide says to post to a url with user/pwd to get a session ID returned from a cookie. I did that using embedded java and have the session ID as a variable in my BPEL process. My problem is with now calling the Web Service to perform the action. I have a WSDL from Siebel, but the guide says to use an HTTP post with the session ID in the url and the XML in the body. How do I do that? Shouldn't the WSDL handle that when I create the Partner Link? Do I need to use more embedded Java for this or can I set up a Partner Link? I created a Partner Link and it shows the methods I want to use, but I get the following error when I try to call it because I don't know where to add the session ID:
    <ErrorCode xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">SBL-ODU-01006</ErrorCode>
    <ErrorMessage xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">Internal Error: Session is not available. Aborting.</ErrorMessage>
    Any help would be GREATLY appreciated. Please let me know if you need more information.
    THANKS!

    The Siebel OnDemand web services can accept the siebel session token in the URL. Append ';jessionid={%sessionIdFromCookie%}' to the end point. Obviously this has to be done dynamically. Refer to the article called 'Making BPEL Processes Dynamic' (http://www.oracle.com/technology/pub/articles/bpel_cookbook/carey.html) pay particular attention to the 'Eliminating address dependency at run time' section.
    Peter

  • Invoke Siebel OnDemand Web Service via BPEL

    Hi,
    We are trying to invoke Siebel OnDemand Web Service via BPEL.
    We have followed the steps as mentioned in
    http://www.oracle.com/technetwork/topics/ofm-siebel-blog-postings-092216.html
    But still we are unable to get the Session Id.
    Do we need to opne any port to resolve this issue or do we have any other way to get the session ID.
    Please let me know if there is any solution to this...
    Thanks

    Thanks for the update..
    We are trying to invoke the CRM On Demand session ID using the BPEL. It seems the we are having some problem with the URL
    https://secure-ausomxapa.crmondemand.com/Services/Integration?command=login
    => `Integration?command=login
    we are trying to access the URL from our SOA server using wget and we are getting following result.
    [XXXXXXXXXXXXXXX ~]$ wget https://secure-ausomxapa.crmondemand.com/Services/Integration?command=login
    --07:32:19-- https://secure-ausomxapa.crmondemand.com/Services/Integration?command=login
    => `Integration?command=login'
    Resolving secure-ausomxapa.crmondemand.com... 141.146.149.68
    Connecting to secure-ausomxapa.crmondemand.com|141.146.149.68|:443...
    We are expecting that we are unable to access the URL using 443 port.

  • Invoking BPEL Process as a Web Service via AJAX / JavaScript

    So, I am able to invoke the BPEL process using the console with a nice XML SOAP fragment. If I take the same fragment and try to invoke the process using JavaScript, I get a NullPointerException:
    <2007-04-03 08:31:24,433> <DEBUG> <default.collaxa.cube.ws> SOAPRequestProvider
    java.lang.NullPointerException
         at com.collaxa.cube.ws.soap.oc4j.SOAPRequestProviderHelper.getSOAPAction(SOAPRequestProviderHelper.java:431)
         at com.collaxa.cube.ws.soap.oc4j.SOAPRequestProvider.processBPELMessage(SOAPRequestProvider.java:231)
         at com.collaxa.cube.ws.soap.oc4j.SOAPRequestProvider.processMessage(SOAPRequestProvider.java:129)
         at oracle.j2ee.ws.server.provider.ProviderProcessor.doEndpointProcessing(ProviderProcessor.java:869)
         at oracle.j2ee.ws.server.WebServiceProcessor.invokeEndpointImplementation(WebServiceProcessor.java:349)
         at oracle.j2ee.ws.server.provider.ProviderProcessor.doRequestProcessing(ProviderProcessor.java:460)
         at oracle.j2ee.ws.server.WebServiceProcessor.processRequest(WebServiceProcessor.java:114)
         at oracle.j2ee.ws.server.WebServiceProcessor.doService(WebServiceProcessor.java:96)
         at oracle.j2ee.ws.server.WebServiceServlet.doPost(WebServiceServlet.java:177)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.security.jazn.oc4j.JAZNFilter$1.run(JAZNFilter.java:396)
         at java.security.AccessController.doPrivileged(Native Method)
         at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
         at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:410)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:368)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:866)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:302)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:190)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    Am I missing something here??? I have injected TCP-Mon into the mix and it is showing me the exact same message going to the web service.
    The message information that is sent looks like:
    POST /orabpel/default/C3eFormInitiation/1.0 HTTP/1.1
    Accept: */*
    Accept-Language: en-ca
    Referer: file://G:\Brad\eformInitiation\eformInitiation.html
    Content-Type: text/xml; charset=UTF-8
    Accept-Encoding: gzip, deflate
    User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; InfoPath.1; FDM)
    Host: d0027200.idir.bcgov:8081
    Content-Length: 1264
    Connection: Keep-Alive
    Cache-Control: no-cache
    Cookie: oracle.uix=0^^GMT-8:00
    <?xml version="1.0" encoding="UTF-8"?>
    <soapenv:Envelope xmlns:q0="http://pssg.gov.bc.ca/c3/eForms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
         <soapenv:Body>
              <q0:formInitiationProcessRequest>
                   <q0:locationCd>VIRCC</q0:locationCd>
                   <q0:initiatorUserId>bxworsfo</q0:initiatorUserId>
                   <q0:parentDocId>0</q0:parentDocId>
                   <q0:submittedForms>
                        <q0:submittedForm>
                             <q0:primaryForm>Y</q0:primaryForm>
                             <q0:assignmentDetails>
                                  <q0:assigneeId>bxworsfo</q0:assigneeId>
                                  <q0:assigneeTypeCd>U</q0:assigneeTypeCd>
                                  <q0:docTypeCd>IACF</q0:docTypeCd>
                                  <q0:docTypeVersion>1.0</q0:docTypeVersion>
                             </q0:assignmentDetails>
                             <q0:workflowDetails>
                                  <q0:docId>n/a</q0:docId>
                                  <q0:docFolderPrefixCd>n/a</q0:docFolderPrefixCd>
                                  <q0:docFolderSeq>n/a</q0:docFolderSeq>
                                  <q0:docSeq>n/a</q0:docSeq>
                                  <q0:workflowTaskURL>n/a</q0:workflowTaskURL>
                                  <q0:workflowDisplayFormIdentifier>n/a</q0:workflowDisplayFormIdentifier>
                             </q0:workflowDetails>
                        </q0:submittedForm>
                   </q0:submittedForms>
              </q0:formInitiationProcessRequest>
         </soapenv:Body>
    </soapenv:Envelope>
    To invoke the web service, we are just using the JavaScript code that has been generated by BPEL Process Manager. The call looks like:
    function invokeSync (url, xmlDoc) {
    var req = null; if (window.XMLHttpRequest) {
    req = new XMLHttpRequest();
    } else if (window.ActiveXObject) {
    req = new ActiveXObject("Microsoft.XMLHTTP");
    if (req) {
    req.open("POST", url, false);
    req.setRequestHeader("Content-Type", "text/xml");
    req.send(xmlDoc);
    return req.responseXML;
    I have been able to invoke other web services using exactly the same function. They all seem fine.
    I am even able to use an AXIS type client to invoke the BPEL web service from Eclipse.
    Advice??? This definitely appears to be some sort of bug?
    Thanks,
    BradW

    check out 102.InvokingProcess/ws tutorial .. which uses axis .. or generate the client based on the wsdl that you can retrieve from the bpel console / click on the process/ and then wsdl tab ..
    hth clemens

  • Problem invoking a web service from soa11g BPEL.

    Hi ,
    I am trying to invoke a web service from soa bpel 11g composite.
    We have the wsdl, wsdl URL of the web service along with the user name , password credentials.
    Initially w/o any WS policy attached and testing the composite, it fails with the below message
    *<fault>*
    *<bpelFault>*
    *<faultType>0</faultType>*
    *<remoteFault>*
    *<part name="summary">*
    *<summary>An Authentication object was not found in the SecurityContext</summary>*
    *</part>*
    *<part name="detail">*
    *<detail>javax.xml.ws.soap.SOAPFaultException: An Authentication object was not found in the SecurityContext</detail>*
    *</part>*
    *<part name="code">*
    *<code>soap:Server</code>*
    *</part>*
    *</remoteFault>*
    *</bpelFault>*
    *</fault>*
    *<faultType>*
    *<message>0</message>*
    *</faultType>*
    *</messages>*
    So I have gone back to the composite and added the WS policy (oracle/wss_username_token_client_policy) by Right clicking on web service -> Configure WS Policy -> Security -> oracle/wss_username_token_client_policy -> OK.
    After this I have added the following binding properties 'oracle.webservices.auth.username' , 'oracle.webservices.auth.password' with the respective values and deployed it again.
    Even then I face the same issue. I have looked into the EM console and found the HTTP username and password properties were blank for this Web service even though the WS policy was attached.
    Later I have tried editing the username pwd from the EM console, only to find out that the composite was now failing in the previous step (an ordinary db adapter with a select statement) even before it reaches the web service invocation.
    If I redeploy the composite, the http username and pwd properties in the EM console are erased and when i test it, it errors out at the web service invocation with the same issue again.
    Any pointers on how to solve this issue ??
    How can I figure out what is the security policy the web service is using ??
    Regards,
    Shiva Kiran

    Hi,
    Can anyone help me with this ??
    I guess I am not able to send the authorization credentials via the request to the web service invocation.
    Plz help ! This is a bit urgent..
    Regards,
    Shiva Kiran

  • Error in Invoking External Web Service in BPEL

    Hello,
    I have a Temperature Conversion Web Service deployed on an external server.
    I want to invoke this Web Service in my BPEL process.
    I got the wsdl loacation of the Web Service as "http://webservices.daelab.net/temperatureconversions/TemperatureConversions.wso?WSDL" and then in my workspace, I created a Web Service out of that WSDL.
    My idea was to create a web service out of that WSDL and then to deploy that web service on SOA server so that i can invoke that deployed service in my BPEL process, but when i am creating a web service out of that WSDL , and trying to test the webservice in my local oc4j, i am gettting a fault exception.
    Am i doing anything wrong ? Is there any other alternative to call a external web service in BPEL?
    Thanks
    Nutan

    Hi,
    you are on the wrong track....
    Open your BPEL. Put the http://webservices.daelab.net/temperatureconversions/TemperatureConversions.wso?WSDL into a PartnerLink and wire an invoke against this PartnerLink....
    Put the parameters via assign into the variables.
    Done...
    Why do you want to create an interal webservice and invoke this one via BPEL? Do you want to invoke the external webservice from the internal one?

  • 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

  • Invoking a web service

    Hello All,
    I am trying to invoke a web service hosted on webMethods (our R/3 being an older version, can't expose function modules as web services). I am able to generate Java proxies from the wsdl provided by webMethods. But, I found by studying the generated Java proxies/stubs that its required to send both input (import) and output (export) parameters to invoke the function module.
    To give you an example, lets say, my function module takes 3 input parameters and returns 120 output parameters. So, to invoke this function, I thought I just need 3 parameters to be supplied to make a call like invokeXYZ(param1, param2, param3). But, when I looked at the generated code, I saw that I need to supply a total of 3 + 120 parameters to invoke the web service. 120 of them are empty objects of type output parameter.
    I think either SAP isn't generating the proxy classes correctly (You don't want to supply 120 arguments to make a call) or I am doing something wrong.
    Any suggestions/comments appreciated.
    Thanks,
    Kiran

    Valery,
    Here's the wsdl. I removed most of the out parameters for brevity.
    <?xml version="1.0" encoding="UTF-8"?>
         <wsdl:definitions name="Neal_test_package_Handlers" targetNamespace="http://hpgena2d/"
                   xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
                   xmlns:xsd="http://www.w3.org/2001/XMLSchema"
                   xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
                   xmlns:tns="http://hpgena2d/"
                   xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
                   xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
         <wsdl:types>
            <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://localhost/Neal_test_package/Handlers/invokeZ_CCS_CUST_INFO" xmlns:tns="http://localhost/Neal_test_package/Handlers/invokeZ_CCS_CUST_INFO">
              <xsd:complexType name="__in">
                <xsd:sequence>
                  <xsd:element name="wmAlias" nillable="true" type="xsd:string"/>
                  <xsd:element name="SEL_CONTRACT_ACCOUNT" nillable="true" type="xsd:string" minOccurs="0"/>
                  <xsd:element name="SEL_LEGACY_ACCOUNT" nillable="true" type="xsd:string" minOccurs="0"/>
                </xsd:sequence>
              </xsd:complexType>
              <xsd:complexType name="__out">
                <xsd:sequence>
                  <xsd:element name="ACCOUNT_BALANCE" nillable="true" type="xsd:string"/>
                  <xsd:element name="ACCOUNT_NAME" nillable="true" type="xsd:string"/>
                  <xsd:element name="ACCOUNT_STATUS" nillable="true" type="xsd:string"/>
                  <xsd:element name="ACCOUNT_STATUS_DESC" nillable="true" type="xsd:string"/>
                  <xsd:element name="APP_CYCLING" nillable="true" type="xsd:string"/>
                </xsd:sequence>
              </xsd:complexType>
            </xsd:schema>
         </wsdl:types>
         <wsdl:message name="invokeZ_CCS_CUST_INFOInput">
              <wsdl:part name="wmAlias" type="xsd:string"/>
              <wsdl:part name="SEL_CONTRACT_ACCOUNT" type="xsd:string"/>
              <wsdl:part name="SEL_LEGACY_ACCOUNT" type="xsd:string"/>
         </wsdl:message>
         <wsdl:message name="invokeZ_CCS_CUST_INFOOutput">
              <wsdl:part name="ACCOUNT_BALANCE" type="xsd:string"/>
              <wsdl:part name="ACCOUNT_NAME" type="xsd:string"/>
              <wsdl:part name="ACCOUNT_STATUS" type="xsd:string"/>
              <wsdl:part name="ACCOUNT_STATUS_DESC" type="xsd:string"/>
         </wsdl:message>
         <wsdl:portType name="Neal_test_package_HandlersPortType">
              <wsdl:operation name="invokeZ_CCS_CUST_INFO">
                   <wsdl:input message="tns:invokeZ_CCS_CUST_INFOInput"/>
                   <wsdl:output message="tns:invokeZ_CCS_CUST_INFOOutput"/>
              </wsdl:operation>
         </wsdl:portType>
         <wsdl:binding name="Neal_test_package_HandlersBinding" type="tns:Neal_test_package_HandlersPortType">
              <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
              <wsdl:operation name="invokeZ_CCS_CUST_INFO">
                   <soap:operation soapAction=""/>
                   <wsdl:input>
                        <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://hpgena2d/Neal_test_package.Handlers" use="encoded"/>
                   </wsdl:input>
                   <wsdl:output>
                        <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://hpgena2d/Neal_test_package.Handlers" use="encoded"/>
                   </wsdl:output>
              </wsdl:operation>
         </wsdl:binding>
         <wsdl:service name="Neal_test_package_HandlersService">
              <wsdl:port name="Neal_test_package_HandlersPort0" binding="tns:Neal_test_package_HandlersBinding">
                   <soap:address location="https://hpgena2d:5555/soap/FEWSController"/>
              </wsdl:port>
         </wsdl:service>
         </wsdl:definitions>
    Thanks for your time,
    Kiran

Maybe you are looking for

  • Zoom H4n Stereo Audio Plays Only Left Speaker - How to Double It?

    Hello Everyone, I've been working on a few projects and noticed that the audio captured by the Zoom H4n will preview in both speakers (and before I drag it to the timeline I can right click -> Modify ->Audio Channels and get all the options there as

  • I Hate Quick Time!

    I just upgraded to 7.5 ..... big mistake... three hours later and still not working! Quicktime will not play avi from my casio camera. I have read previous forms..... nothing works! Perian is installed and updated.... Please help! I feel myself turni

  • Refurbished X201 integrated camera settings don't work

    My refurbished X201 (3680HN9) has an integrated camera (so says device manager) but nothing happens when I press FN+F6. I have downloaded the integrated camera driver from Lenovo support site but after install FN+F6 still does nothing. I would apprec

  • Headphone Jack does not fit into my new Sansa Clip +

    Hi, I just bought a new Sansa Clip + so I could listen to my songs while on vacation, but when I put in my headphones 3.5 jack plug into the hole on the side of the mp3 player it  won't go all the way in and falls out if I dont hold it properly. Is t

  • How can I fix this code ?

    hello, I have a small problem with this code: #include  <fstream> #include  <iostream> #include  <algorithm> #include  <iterator> #include  <string> #include  <vector> using namespace std; int main()      string from, to;      cin >> from >> to;