Web Services Dynamic Invocation

Hi,
I am trying to find a way to do web services dynamic invocation where params and return type can be complex types.
The process I intent to follow is, query a uddi registry based on some search criteria to get a reference to the service wsdl. Use maybe wsdl4j to introspect the wsdl to determine porttype, operations, param data types etc and then perform a dynamic invocation.
Does anybody have any ideas on how best this can be achieved without having to reinvent the wheel.
Thanks,
-V

Hi
I am looking for the same thing, please let me know if you resolve it.
thanks

Similar Messages

  • Step by step installation for Web Services Dynamic Invocation application?

    please let me know the step by step process to install the Web Services Dynamic Invocation application Sample code.The install.htm that comes with the download does not give enough information.
    Thanks in Advance
    Shyam

    Sorry for the confusion,i got hold of the right document.
    Thanks
    Shyam

  • Web Service Dynamic Invocation Classes

    I am trying to locate a jar file that contains the following classes:
    import oracle.j2ee.ws.client.WebServiceProxy;
    import oracle.j2ee.ws.client.WebServiceMethod;
    import oracle.j2ee.ws.client.WebServiceProxyFactory;
    Could someone point me to a site where I can download a jar file?
    Thanks
    Robert Williams

    These classes are part of dsv2.jar file which is located in ORACLE9iAS_HOME/lib
    raghu
    JDev Team

  • Oracle PL/SQL Web service - dynamic parameters... possible?

    Oracle 11.2.0.3 - newbie on web services!
    Currently we have a pl/sql web service taking in 2 static parameters and returning a varchar2 response.
    I was asked today if it's possible for a web service to take in a dynamic set of parameters and return a corresponding set of results. It's as if I need to pass the web service a table with two columns and return a table of one column.
    For example:
                        Input                          Output
              1 2                             3
              3 4                             7
              5 6                            11output being in XML of course. It is possible?
    p.s. I posted this in OC4J also - no response hence the re-post !

    Parameters relate to procedures. Web Services require XML messages.
    Where are the parameters coming from? You cannot pass a dynamic number of parameters into a procedure, but you can pass a structured type as a parameter which can contain multiple values, whether that is an array/collection type or an XML document itself.
    Just package up the values into the XML and pass it to the web service.
    If this doesn't answer your question, please post more information, with some example data and code. Read the FAQ: {message:id=9360002}

  • Web service dynamic client property for Call

    Hi, Hope this is the right forum for web service questions. The oracle document (6 Developing JAX-RPC Web Service Clients) on web service client only shows the stub and properties can be set in stub. I would like to use dynamic client. Can Call object have some properties? what are they?
    Thanks

    Can any one please help :-(

  • Type mismatch on SOAP Web Service method invocation

    When I run the generated client for a web service, I get the following error, which I can get rid of by using a primitive type (e.g. String) as the parameter to doSomething instead of wstest.test2.APIClass3, i.e. the SOAP server seems happy handling wstest.test2.APIClass1 as a return type, but not a similar class as a parameter type:
    [SOAPException: faultCode=SOAP-ENV:Server; msg=type mismatch [java.lang.IllegalArgumentException]]
         wstest.test2.APIClass1 wstest.test2.EmbeddedStatelessTest2Stub.doSomething(wstest.test2.APIClass3)
              EmbeddedStatelessTest2Stub.java:89
         void wstest.test2.EmbeddedStatelessTest2Stub.main(java.lang.String[])
              EmbeddedStatelessTest2Stub.java:48
    I am using JDeveloper9i 9.0.3 Preview and the standalone OC4J 9.0.3 that came with it. I followed the Oracle9i JDeveloper 9.0.3 Web Services Quickstart Install (http://otn.oracle.com/tech/webservices/htdocs/quickstart/quickstart903.html) to get OC4J running standalone. I had to register the stateless EJB provider, and the WEB services wizard didn't manage to include APIClass2 (an instance of which is contained in APIClass1) in the .dd so I added it manually which works fine with APIClass1 as the method return type.
    Sorry for the length of this posting, but I wasn't sure which bits would be relevant.
    WSDL
    ====
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!--Generated by the Oracle9i JDeveloper Web Services WSDL Generator-->
    <!--Date Created: Wed Sep 11 15:54:08 BST 2002-->
    <definitions
    name="StatelessTest2"
    targetNamespace="http://wstest/test2/StatelessTest2.wsdl"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:tns="http://wstest/test2/StatelessTest2.wsdl"
    xmlns:ns1="http://wstest.test2/IStatelessTest2.xsd">
    <types>
    <schema
    targetNamespace="http://wstest.test2/IStatelessTest2.xsd"
    xmlns="http://www.w3.org/2001/XMLSchema"
    xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
    <complexType name="wstest_test2_APIClass3" jdev:packageName="wstest.test2" xmlns:jdev="http://xmlns.oracle.com/jdeveloper/webservices">
    <all>
    <element name="Name" type="string"/>
    <element name="Value" type="double"/>
    </all>
    </complexType>
    <complexType name="wstest_test2_APIClass1" jdev:packageName="wstest.test2" xmlns:jdev="http://xmlns.oracle.com/jdeveloper/webservices">
    <all>
    <element name="Name" type="string"/>
    <element name="Value" type="double"/>
    <element name="APIClass2" type="ns1:wstest_test2_APIClass2"/>
    </all>
    </complexType>
    <complexType name="wstest_test2_APIClass2" jdev:packageName="wstest.test2" xmlns:jdev="http://xmlns.oracle.com/jdeveloper/webservices">
    <all>
    <element name="IntegerValue" type="int"/>
    <element name="DoubleValue" type="double"/>
    <element name="Name" type="string"/>
    </all>
    </complexType>
    </schema>
    </types>
    <message name="doSomething0Request">
    <part name="p0" type="ns1:wstest_test2_APIClass3"/>
    </message>
    <message name="doSomething0Response">
    <part name="return" type="ns1:wstest_test2_APIClass1"/>
    </message>
    <portType name="StatelessTest2PortType">
    <operation name="doSomething">
    <input name="doSomething0Request" message="tns:doSomething0Request"/>
    <output name="doSomething0Response" message="tns:doSomething0Response"/>
    </operation>
    </portType>
    <binding name="StatelessTest2Binding" type="tns:StatelessTest2PortType">
    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="doSomething">
    <soap:operation soapAction="" style="rpc"/>
    <input name="doSomething0Request">
    <soap:body use="encoded" namespace="wstest.test2.StatelessTest2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    </input>
    <output name="doSomething0Response">
    <soap:body use="encoded" namespace="wstest.test2.StatelessTest2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    </output>
    </operation>
    </binding>
    <service name="StatelessTest2">
    <port name="StatelessTest2Port" binding="tns:StatelessTest2Binding">
    <soap:address location="http://localhost:8888/soap/servlet/soaprouter"/>
    </port>
    </service>
    </definitions>
    Deployment Decriptor
    ====================
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!--Generated by the Oracle9i JDeveloper Web Services Deployment Descriptor Generator-->
    <!--This Deployment Descriptor file is for use with the Oracle9iAS Release 2 / Apache 2.2 SOAP Server SOAP Server-->
    <!--Date Created: Wed Sep 11 15:54:09 BST 2002-->
    <isd:service
    id="wstest.test2.StatelessTest2"
    type="rpc"
    xmlns:isd="http://xmlns.oracle.com/soap/2001/04/deploy/service">
    <isd:provider
    id="stateless-ejb-provider"
    methods="doSomething"
    scope="Request">
    <isd:option key="JNDILocation" value="StatelessTest2"/>
    <isd:option key="DeploymentName" value="StatelessTest2"/>
    </isd:provider>
    <isd:faultListener
    class="org.apache.soap.server.DOMFaultListener"/>
    <isd:mappings>
    <isd:map
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:x="http://wstest.test2/IStatelessTest2.xsd"
    qname="x:wstest_test2_APIClass1"
    javaType="wstest.test2.APIClass1"
    java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
    xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
    <isd:map
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:x="http://wstest.test2/IStatelessTest2.xsd"
    qname="x:wstest_test2_APIClass2"
    javaType="wstest.test2.APIClass2"
    java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
    xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
    <isd:map
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:x="http://wstest.test2/IStatelessTest2.xsd"
    qname="x:wstest_test2_APIClass3"
    javaType="wstest.test2.APIClass3"
    java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
    xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
    </isd:mappings>
    </isd:service>
    StatelesTest2.java
    ==================
    package wstest.test2;
    import javax.ejb.EJBObject;
    import java.rmi.RemoteException;
    public interface StatelessTest2 extends EJBObject {
    * @webmethod
    APIClass1 doSomething(APIClass3 p0) throws RemoteException;
    StatelessTest2Bean.java
    =======================
    package wstest.test2.impl;
    import javax.ejb.SessionBean;
    import javax.ejb.SessionContext;
    import wstest.test2.APIClass1;
    import wstest.test2.APIClass2;
    import wstest.test2.APIClass3;
    public class StatelessTest2Bean implements SessionBean {
    public void ejbCreate() {
    public void ejbActivate() {
    public void ejbPassivate() {
    public void ejbRemove() {
    public void setSessionContext(SessionContext ctx) {
    public APIClass1 doSomething(APIClass3 p0) {
    APIClass1 ac1 = new APIClass1();
    ac1.setName(p0.getName() + "1");
    ac1.setValue(p0.getValue());
    APIClass2 ac2 = ac1.getAPIClass2();
    ac2.setName(p0.getName() + "2");
    ac2.setIntegerValue(new Integer(ac1.getValue().intValue()));
    ac2.setDoubleValue(new Double(ac1.getValue().doubleValue() * 2.0));
    return ac1;
    EmbeddedStatelessTest2Stub.java
    ===============================
    I change the http port from 8988 to 8888 to get this working. Also, the generated referenced a new class APIClass31, also generated, but as it didn't make any difference to the problem I replaced it with APIClass3, which has essentially the same characteristics.
    package wstest.test2;
    import oracle.soap.transport.http.OracleSOAPHTTPConnection;
    import org.apache.soap.encoding.soapenc.BeanSerializer;
    import org.apache.soap.encoding.SOAPMappingRegistry;
    import org.apache.soap.util.xml.QName;
    import java.net.URL;
    import org.apache.soap.Constants;
    import org.apache.soap.Fault;
    import org.apache.soap.SOAPException;
    import org.apache.soap.rpc.Call;
    import org.apache.soap.rpc.Parameter;
    import org.apache.soap.rpc.Response;
    import wstest.test2.*;
    import java.util.Vector;
    import java.util.Properties;
    import wstest.test2.APIClass1;
    import wstest.test2.APIClass2;
    import wstest.test2.APIClass3;
    * Generated by the Oracle9i JDeveloper Web Services Stub/Skeleton Generator.
    * Date Created: Wed Sep 11 15:41:19 BST 2002
    * WSDL URL: file:/C:/Projects/WSTest/Test2/src/wstest/test2/StatelessTest2.wsdl
    public class EmbeddedStatelessTest2Stub
    public EmbeddedStatelessTest2Stub()
    m_httpConnection = new OracleSOAPHTTPConnection();
    m_smr = new SOAPMappingRegistry();
    BeanSerializer beanSer = new BeanSerializer();
    m_smr.mapTypes(Constants.NS_URI_SOAP_ENC, new QName("http://wstest.test2/IStatelessTest2.xsd", "wstest_test2_APIClass1"), wstest.test2.APIClass1.class, beanSer, beanSer);
    m_smr.mapTypes(Constants.NS_URI_SOAP_ENC, new QName("http://wstest.test2/IStatelessTest2.xsd", "wstest_test2_APIClass2"), wstest.test2.APIClass2.class, beanSer, beanSer);
    m_smr.mapTypes(Constants.NS_URI_SOAP_ENC, new QName("http://wstest.test2/IStatelessTest2.xsd", "wstest_test2_APIClass3"), wstest.test2.APIClass3.class, beanSer, beanSer);
    public static void main(String[] args)
    try
    EmbeddedStatelessTest2Stub stub = new EmbeddedStatelessTest2Stub();
    // Add your own code here.
    APIClass3 ac3 = new APIClass3();
    ac3.setName("fred");
    ac3.setValue(new Double(17.36));
    printAPIClass3("Input", ac3);
    APIClass1 retAc1 = stub.doSomething(ac3);
    printAPIClass1("Return", retAc1);
    catch(Exception ex)
    ex.printStackTrace();
    public String endpoint = "http://172.25.1.176:8888/soap/servlet/soaprouter";
    private OracleSOAPHTTPConnection m_httpConnection = null;
    private SOAPMappingRegistry m_smr = null;
    public APIClass1 doSomething(APIClass3 p0) throws Exception
    APIClass1 returnVal = null;
    URL endpointURL = new URL(endpoint);
    Call call = new Call();
    call.setSOAPTransport(m_httpConnection);
    call.setTargetObjectURI("wstest.test2.StatelessTest2");
    call.setMethodName("doSomething");
    call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
    Vector params = new Vector();
    params.addElement(new Parameter("p0", wstest.test2.APIClass3.class, p0, null));
    call.setParams(params);
    call.setSOAPMappingRegistry(m_smr);
    Response response = call.invoke(endpointURL, "");
    if (!response.generatedFault())
    Parameter result = response.getReturnValue();
    returnVal = (APIClass1)result.getValue();
    else
    Fault fault = response.getFault();
    throw new SOAPException(fault.getFaultCode(), fault.getFaultString());
    return returnVal;
    private static void printAPIClass3(String prefix, APIClass3 ac3)
    System.out.println(prefix + ": [" + ac3.getName() + ", " + ac3.getValue() + "]");
    private static void printAPIClass1(String prefix, APIClass1 ac1)
    APIClass2 ac2 = ac1.getAPIClass2();
    System.out.println(prefix + ": [" + ac1.getName() + ", " + ac1.getValue() + " ["
    + ac2.getName() + ", " + ac2.getIntegerValue() + ", " + ac2.getDoubleValue()
    + "]]");
    public void setMaintainSession(boolean maintainSession)
    m_httpConnection.setMaintainSession(maintainSession);
    public boolean getMaintainSession()
    return m_httpConnection.getMaintainSession();
    public void setTransportProperties(Properties props)
    m_httpConnection.setProperties(props);
    public Properties getTransportProperties()
    return m_httpConnection.getProperties();
    APIClass1.java
    ==============
    package wstest.test2;
    import java.io.Serializable;
    public class APIClass1 implements Serializable {
    private String name;
    private Double value;
    private APIClass2 apiClass2;
    public APIClass1() {
    name = new String("");
    value = new Double(0.0);
    apiClass2 = new APIClass2();
    public String getName() {
    return name;
    public void setName(String newName) {
    name = new String(newName);
    public Double getValue() {
    return value;
    public void setValue(Double newValue) {
    value = new Double(newValue.doubleValue());
    public APIClass2 getAPIClass2() {
    return apiClass2;
    public void setAPIClass2(APIClass2 newAPIClass2) {
    apiClass2 = new APIClass2();
    apiClass2.setName(newAPIClass2.getName());
    apiClass2.setDoubleValue(newAPIClass2.getDoubleValue());
    apiClass2.setIntegerValue(newAPIClass2.getIntegerValue());
    APIClass2.java
    ==============
    package wstest.test2;
    import java.io.Serializable;
    public class APIClass2 implements Serializable {
    private String name;
    private Integer iVal;
    private Double dVal;
    public APIClass2() {
    iVal = new Integer(0);
    dVal = new Double(0.0);
    name = new String("");
    public Integer getIntegerValue() {
    return iVal;
    public void setIntegerValue(Integer newIVal) {
    iVal = new Integer(newIVal.intValue());
    public Double getDoubleValue() {
    return dVal;
    public void setDoubleValue(Double newDoubleValue) {
    dVal = new Double(newDoubleValue.doubleValue());
    public String getName() {
    return name;
    public void setName(String newName) {
    name = new String(newName);
    APIClass3.java
    ==============
    package wstest.test2;
    import java.io.Serializable;
    public class APIClass3 implements Serializable {
    private String name;
    private Double value;
    public APIClass3() {
    public String getName() {
    return name;
    public void setName(String newName) {
    name = new String(newName);
    public Double getValue() {
    return value;
    public void setValue(Double newValue) {
    value = new Double(newValue.doubleValue());
    APIClass31.java
    ===============
    package wstest.test2;
    * Generated by the Oracle9i JDeveloper Web Services Stub/Skeleton Generator.
    * Date Created: Wed Sep 11 10:44:56 BST 2002
    * <pre>
    * &lt;complexType name="wstest_test2_APIClass3" jdev:packageName="wstest.test2" xmlns:jdev="http://xmlns.oracle.com/jdeveloper/webservices">
    * &lt;all>
    * &lt;element name="Name" type="string"/>
    * &lt;element name="Value" type="double"/>
    * &lt;/all>
    * &lt;/complexType>
    * </pre>
    public class APIClass31 {
    private String m_Name;
    private Double m_Value;
    public APIClass31() {
    public APIClass31(String Name, Double Value) {
    m_Name = Name;
    m_Value = Value;
    public void setName(String Name) {
    m_Name = Name;
    public String getName() {
    return m_Name;
    public void setValue(Double Value) {
    m_Value = Value;
    public Double getValue() {
    return m_Value;

    I believe this is a bug in JDev/OC4J 9.0.3 that is being further investigated right now. I have duplicated your problem in a simpler test case and folks are looking into it.
    Mike.

  • How to dynamically connect to a web service

    hello
    i wana know how can i connect to a webservices dynamically in java
    i am using MYeclipse i know how to create a web service client but i dnt know how to connect to a web service dynamically ie i give the url of the service at run time and then connect to that service....................
    regards
    Shakeel Abbas

    Shakeel.Abbas wrote:
    how can i connect to a webservices dynamically in java?you can do this following ways:
    *&#963;*    Use [javax.xml.soap|http://java.sun.com/javaee/5/docs/api/javax/xml/soap/package-summary.html] package for invoking web services using Simple Object Access Protocol (SOAP). Using SOAPConnection you can connect and communicate to a webservice via SOAPMessage . [More about SOAP Connection|http://java.sun.com/javaee/5/docs/tutorial/doc/bnbhg.html#bnbhq].
    *&#963;*    Use [java.net|http://java.sun.com/javase/6/docs/api/java/net/package-summary.html] package for invoking web services using Hypertext Transfer Protocol (HTTP). Using HttpURLConnection you can connect and communicate to a webservice.
    Hope this will help.
    Thanks,
    Tejas

  • Dynamic - Web Service Call

    Hi All
    I am working on 12.2.3 build 165. I am trying to call web service dynamically providing url at the run time..
    I tried using wizard way- giving url, then selecting operation and it works fine. But is it possible to give url as input at run time... I have tried giving no. of inputs at run time but none worked. Pls guide in detail if this is possible.
    thanking you all , taranum

    Hello Nagaraju,
    I need to create a dynamic Webservice call for my application.
    As you mentioned on above I passed the following with link editor in Web service call,
    1. WSDL Base URL
    2. WSDL URL
    3. Opertaion
    but its showing the following error
    com.sap.lhcommon.webservice.SoapOperation.getInputMessage() of an object loaded from local variable 'oper'
    Am i missing any mandatory field value to pass to Webservice call ?
    how can I pass XML input at run time to the request object in this scenario ?
    Here I'm using this as a common transaction, so multiple transaction can use it to post to Web sphere.
    Looking forward for your assistance.
    I need to pass wsdl's dynamically, So can I pass Input XML to request object in linke editor ?
    on of the WSDL structure:
    Regards,
    Srisailam Yadav

  • ANN: Tutorial - Dynamically Invoking Web Services

    This tutorial describes how build an application that invokes Web Services dynamically at runtime. You will also learn how to publish and find Web Services registered in Oracle UDDI registry. The sample application implements a bportal where the user can compare insurance prices.
    http://otn.oracle.com/sample_code/tutorials/wsdyn/toc.htm
    Available 1/7/03.

    When you test the connection (steps are below, and in the Setup section, http://otn.oracle.com/sample_code/tutorials/wsdyn/setup.htm#editthe)
    do you get a Status Success message?
    Edit the connection
    1. Click on the Connections node to expand it.
    2. Double click on Application server.
    3. In the connection wizard step 1 type Connection name as "WebServiceDII".
    4. Select connection type as Oracle9iApplication server.
    5. Click next to go to Step 2
    6. Enter Username and Password valid for this server.
    7. Click Next to go to Step 3.
    8. Click Next to go to Step 4.
    9. Test the connection you should get status "Success".
    10. For all future deployment purposes use this ("WebServiceDII") connection.
    11. Click "Finish" button to dismiss the dialog box.

  • Dynamic Web Service Consumption

    Hi
    I want to know if it is possible to consume a web service dynamically. Or is there any other way to consume web service in JSP without using proxies.
    I have already done consumption using deployable proxies but the way of consuming the web service is hardcoded. We have 3 landscape boxes (development box, maintenance box, production box). The problem is the URL for each WSDL in each box is different. So if we move our code from say dev box to maintenance box we have to edit our code for consumption before moving our codes. I hope there's a way to consume our web service/ WSDL dynamically.
    Thanks.

    Hello Melanie, I wanted to ask you:
    how do you do a deployable proxy in 7.3 ?
    In 7.0 I used to make a "Deployable Proxy Project", and now I don't know how to go.
    I have tried with an "Entreprise App. Project" wich in it has a "EJB project" wich also has an "Web Service Client". I don't know if Im doing it the right way.
    Thanks.

  • Dynamic invoking web service via uddi regitry server

    Hi,
    I need to call the web service dynamically after searching from the UDDI Registry Server. pls give me some reply that how to call the web service dynamic.
    Thnx in Advance.
    [email protected]

    Hi,
    Try using the udditest.sap.com   it is the Test Registry provided.
    Configuring the UDDI Client and UDDI Server    ::::
    To use the UDDI client for publishing, updating, or discovering business services and tModels, first you have to administer the UDDI client as well as the UDDI server using the J2EE Engine Visual Administrator.
    Procedure
           1.      Select Web Services Container ® Runtime ® UDDI Client.
           2.      From the Available Registries list, select a UDDI registry.
                                a.      To enter a different Inquiry URL and Publish URL, choose Edit Registry and enter new locations.
    Make sure that the URLs contain a  value. If they do not, then add the port value manually (for example, localhost:50000).
                                b.      To add a registry to the Available Registries list, choose New Registry.
                                c.      To remove a registry from the list, choose Remove Registry.
           3.      On the UDDI Server tab page, choose New User and enter the corresponding data. For more information, see Managing the UDDI Server in the Administration Manual.
    Using the Visual Administrator, you can create users for а local test registry only.
    Create the User here for the test registry used.
    regards
    Ganga
    Edited by: gangaprasad chintala on Dec 26, 2008 8:04 PM

  • Jax-WS 2.2 web service instances management on Glassfish 3

    Hi all, I'm studying Jax-WS specification in general and its implementation on Glassfish 3.1.2. I built a simple standard example where a jax-ws soap based web service is called from a jsp page by using the artifacts generated through wsimport (the webservice and the jsp page are both deployed on Glassfish in the same EAR but in 2 different wars).
    Everything works as expected but I have a question: looking at the application log, it seems that Glassfish creates a new instance of the webservice each time it is called. I would like to know where Java offically defines how a web container should manage webservice instances and if developers can customize this behaviour.
    I read jax-ws 2.1 specification here
    http://download.oracle.com/otndocs/jcp/jaxws-2.1-mrel2-eval-oth-JSpec/
    but I found only a clue when speaking about how to publish a webservice using the Endpoint class by hand (section 5.2.2 "Publishing", page 69):
    "An endpoint consists of an object that acts as the Web service implementation (called here implementor) plus some configuration information...
    An Endpoint will be typically invoked to serve concurrent requests, so its implementor should be written so as to support multiple threads. The synchronized keyword may be used as usual to control access to critical sections of code. For finer control over the threads used to dispatch incoming requests, an application can directly set the executor to be used..."
    This note is present even in Jax-WS 2.2 specification (used by Glassfish 3).
    Actually, if I build a webservice using only JavaSE 7 (which includes Jax-WS 2.2), this description is true because there is only one instance of the webservice. Is there any reason why JavaEE doesn't follow this policy?
    Thanks a lot for your help,
    Nico

    Hi, I found the answers on this specification (JSR-109):
    http://jcp.org/aboutJava/communityprocess/mrel/jsr109/index3.html
    It describes how Jax-WS works on JavaEE:
    "4.1 Client Programming model (page 18)
    a client must assume that the methods of a Web service have no state that is persistent across multiple Web service method invocations. A client can treat the Web service implementation as stateless.
    The client has no control over the life cycle of the Web service implementation on the server. A client does not create or destroy instances of a Web service, which is referred to as a Port. The client only accesses the Port. The life cycle of the Ports, or instances of a Web service implementation, are managed by the run-time that hosts the Web service. A Port has no identity. This means that a client cannot compare a Port to other Ports to see if they are the same or identical, nor can a client access a specific Port instance.
    5.3.2.4.2 Web container programming model for JAX-WS (page 42)
    A Service Implementation must be a stateless object. A Service Implementation Bean must not save client specific state across method calls either within the bean instance’s data members or external to the instance. A container may use any bean instance to service a request.
    5.3.4 Service Implementation Bean Life Cycle (page 43)
    Before a request can be serviced, the container must instantiate a Service Implementation Bean and ready it for method requests.
    A container may pool method ready instances of a Service Implementation Bean and dispatch a method request on any instance in a method ready state."
    Moreover, the specification states that JavaEE must not use the Endpoint class to publish a webservice:
    "5.3.3 Publishing Endpoints – javax.xml.ws.Endpoint (page 43)
    JAX-WS provides functionality for creating and publishing Web Service endpoints dynamically using javax.xml.ws.Endpoint API. The use of this functionality is considered non-portable in a managed environment. It is required that both the Servlet and the EJB container disallow the publishing of the Endpoint dynamically, by not granting the publishEndpoint security permission."

  • (261680070) Q SYNCH-11 How do my web service methods accees EJBs and java classes?

    A<SYNCH-11> How do my web service methods accees EJBs and java classes?
    A<SYNCH-11> It is simple to use java classes, just do it as you would ordinarily.
    The .jws file really contains a simple class so you can program with it in the same
    way that you would use a regular Java class.
    To use an EJB you can go and access it directly as you would with any EJB remote
    client (lookup home stub, create, etc) or if the EJB is deployed to WLS you can use
    a control to provide a very simple wrapper to the EJB. We will see this in detail
    on Thursday in the ADVC module.

    Futher information about the possibility of callback:
    It may be possible for a synchronous only web service (i.e. MS .net) to even paticipant
    in the callback functionality of asynchronous web services. If the client implements
    the appropriate methods for the callback but listens for them on a different port
    or binding than the SOAP request, then web service may be able to build a response
    if the client's "callback URL" is submitted as the beginning part of a conversation.
    Watch the BEA developer forum (http://dev2dev.bea.com) for more information about
    this approach and other tips and techniques for building web services.
    "Adam FitzGerald" <[email protected]> wrote:
    >
    Q<SYNCH-03> I heard that MS .net only implements synchrnonus method? If
    this is true.
    Does it means my async methods will only work with J2EE clients?
    A<SYNCH-03> I do not know the limitations of .net but let me point out that
    is very
    difficult to provide asynchronous web service method invocation (this is
    different
    from an asynchronous web service). HTTP as a general communication protocol
    is based
    on a request and response paradigm so your client libraries will mostly
    likely be
    expecting a response even if it is empty (check the asynchronous example
    from today
    to see that the start method still returns an empty response). You must
    distinguish
    this from the notion of an asynchronous web service which is a business
    operation
    that occurs on the server whose return value/result is not directly associated
    with
    building response to the client. An asynchronous web service can (and generally
    will)
    be started and stopped with web service operations that are invoked synchronously.
    Thus MS .net clients can still be client to WLS hosted web services.

  • New Web Services and UDDI  Sample

    New Web Services and UDDI sample has been hosted on OTN site.
    In this sample learn how to invoke web services dynamically. You will also learn how to publish and look up Web Services registered in Oracle UDDI registry. This sample application implements an insurance portal where the user can look out for the best insurance deals.
    http://otn.oracle.com/sample_code/tech/java/web_services/content.html
    Regards
    -- Abhijeet

    bump

  • Multiple references to web services in EJBs

    Hi
    Would like to know if its possible to reference EJB web services dynamically from fields in a database. Basically, I would have the EJB installed on multiple servers and need to be able to invoke it after looking up the address of the server in the database. Currently I'm using a NetBeans Web Service Reference in a JSP project to call the EJB.
    Regards
    Lionel

    Here [it is|http://blog.vinodsingh.com/2008/09/building-jax-ws-web-service.html] with source code.

Maybe you are looking for

  • Oracle Portal & BI 10g on Windows XP Professional

    Hi, I'm planning to install 10gAS (Portal, BI) on XP Professional. But while installing it says it is not Certified. Does anyone using it on XP? If I ignore warning and go ahead will it work? Thanks & Regards Santos B

  • Hi.. imac 27" 2012 as display / TV

    Does imac 27" late 2012 accept Video input through MDP from non-apple source. Basically want to play blue-ray/DVD/cable tv with imac as display?

  • How to store multiple child nodes using dbms_xmlstore

    Hi, I'm using oracle 10g environment. In DBMS_XMLSTORE package I cannot able to insert the multiple child node value into db table. Here I have given the xml value <DATAPACKET REQUEST-ID="10001094">   <HEADER>     <SEARCH-RESULT-LIST>       <SEARCH-R

  • Sound works from one headphone only

    Dear all, I can hear sound from one headphone only. I can confirm I have tried with three different headsets including the one provided by Sony. I can also confirm the problem happens with all applications (Spotify, Walkman, SoundCloud) including the

  • No Business Area on Tax segment of BSEG-GSBER since upgrade to 4.7

    Hello everyone- We upgraded our system in 2005 to 4.7 Since that time accounting documents, BSEG entries that represent sales tax charged to the customer does not have the Business Area filled in, ie. BSEG-GSBER is blank for Tax lines. This causes a