Using DII in JAX-RPC

I've been trying to connect (unsuccessfully so far) to a webservice using DII in JAX-RPC. Was able to connect to the said webservice successfully using static stubs. But our requirement is for dynamic invocation. Sorry if a topic like this has been posted already. I did search the forums but couldn't find the answer to my problem.
The WSDL for the web service is as follows:
<?xml version="1.0" encoding="utf-8"?>
<definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:s0="http://secure.yehey.com/2003/01/PayPlus" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" targetNamespace="http://secure.yehey.com/2003/01/PayPlus" xmlns="http://schemas.xmlsoap.org/wsdl/">
<types>
<s:schema elementFormDefault="qualified" targetNamespace="http://secure.yehey.com/2003/01/PayPlus">
<s:element name="Process">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="inpData" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="ProcessResponse">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="ProcessResult" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="GetStatus">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="inxml" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="GetStatusResponse">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="GetStatusResult" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="GetRedirectURL">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="inpURL" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="GetRedirectURLResponse">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="GetRedirectURLResult" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:element name="string" nillable="true" type="s:string" />
</s:schema>
</types>
<message name="ProcessSoapIn">
<part name="parameters" element="s0:Process" />
</message>
<message name="ProcessSoapOut">
<part name="parameters" element="s0:ProcessResponse" />
</message>
<message name="GetStatusSoapIn">
<part name="parameters" element="s0:GetStatus" />
</message>
<message name="GetStatusSoapOut">
<part name="parameters" element="s0:GetStatusResponse" />
</message>
<message name="GetRedirectURLSoapIn">
<part name="parameters" element="s0:GetRedirectURL" />
</message>
<message name="GetRedirectURLSoapOut">
<part name="parameters" element="s0:GetRedirectURLResponse" />
</message>
<message name="ProcessHttpGetIn">
<part name="inpData" type="s:string" />
</message>
<message name="ProcessHttpGetOut">
<part name="Body" element="s0:string" />
</message>
<message name="GetStatusHttpGetIn">
<part name="inxml" type="s:string" />
</message>
<message name="GetStatusHttpGetOut">
<part name="Body" element="s0:string" />
</message>
<message name="GetRedirectURLHttpGetIn">
<part name="inpURL" type="s:string" />
</message>
<message name="GetRedirectURLHttpGetOut">
<part name="Body" element="s0:string" />
</message>
<message name="ProcessHttpPostIn">
<part name="inpData" type="s:string" />
</message>
<message name="ProcessHttpPostOut">
<part name="Body" element="s0:string" />
</message>
<message name="GetStatusHttpPostIn">
<part name="inxml" type="s:string" />
</message>
<message name="GetStatusHttpPostOut">
<part name="Body" element="s0:string" />
</message>
<message name="GetRedirectURLHttpPostIn">
<part name="inpURL" type="s:string" />
</message>
<message name="GetRedirectURLHttpPostOut">
<part name="Body" element="s0:string" />
</message>
<portType name="PayplusSoap">
<operation name="Process">
<input message="s0:ProcessSoapIn" />
<output message="s0:ProcessSoapOut" />
</operation>
<operation name="GetStatus">
<input message="s0:GetStatusSoapIn" />
<output message="s0:GetStatusSoapOut" />
</operation>
<operation name="GetRedirectURL">
<input message="s0:GetRedirectURLSoapIn" />
<output message="s0:GetRedirectURLSoapOut" />
</operation>
</portType>
<portType name="PayplusHttpGet">
<operation name="Process">
<input message="s0:ProcessHttpGetIn" />
<output message="s0:ProcessHttpGetOut" />
</operation>
<operation name="GetStatus">
<input message="s0:GetStatusHttpGetIn" />
<output message="s0:GetStatusHttpGetOut" />
</operation>
<operation name="GetRedirectURL">
<input message="s0:GetRedirectURLHttpGetIn" />
<output message="s0:GetRedirectURLHttpGetOut" />
</operation>
</portType>
<portType name="PayplusHttpPost">
<operation name="Process">
<input message="s0:ProcessHttpPostIn" />
<output message="s0:ProcessHttpPostOut" />
</operation>
<operation name="GetStatus">
<input message="s0:GetStatusHttpPostIn" />
<output message="s0:GetStatusHttpPostOut" />
</operation>
<operation name="GetRedirectURL">
<input message="s0:GetRedirectURLHttpPostIn" />
<output message="s0:GetRedirectURLHttpPostOut" />
</operation>
</portType>
<binding name="PayplusSoap" type="s0:PayplusSoap">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
<operation name="Process">
<soap:operation soapAction="http://secure.yehey.com/2003/01/PayPlus/Process" style="document" />
<input>
<soap:body use="literal" />
</input>
<output>
<soap:body use="literal" />
</output>
</operation>
<operation name="GetStatus">
<soap:operation soapAction="http://secure.yehey.com/2003/01/PayPlus/GetStatus" style="document" />
<input>
<soap:body use="literal" />
</input>
<output>
<soap:body use="literal" />
</output>
</operation>
<operation name="GetRedirectURL">
<soap:operation soapAction="http://secure.yehey.com/2003/01/PayPlus/GetRedirectURL" style="document" />
<input>
<soap:body use="literal" />
</input>
<output>
<soap:body use="literal" />
</output>
</operation>
</binding>
<binding name="PayplusHttpGet" type="s0:PayplusHttpGet">
<http:binding verb="GET" />
<operation name="Process">
<http:operation location="/Process" />
<input>
<http:urlEncoded />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
<operation name="GetStatus">
<http:operation location="/GetStatus" />
<input>
<http:urlEncoded />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
<operation name="GetRedirectURL">
<http:operation location="/GetRedirectURL" />
<input>
<http:urlEncoded />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
</binding>
<binding name="PayplusHttpPost" type="s0:PayplusHttpPost">
<http:binding verb="POST" />
<operation name="Process">
<http:operation location="/Process" />
<input>
<mime:content type="application/x-www-form-urlencoded" />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
<operation name="GetStatus">
<http:operation location="/GetStatus" />
<input>
<mime:content type="application/x-www-form-urlencoded" />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
<operation name="GetRedirectURL">
<http:operation location="/GetRedirectURL" />
<input>
<mime:content type="application/x-www-form-urlencoded" />
</input>
<output>
<mime:mimeXml part="Body" />
</output>
</operation>
</binding>
<service name="Payplus">
<port name="PayplusSoap" binding="s0:PayplusSoap">
<soap:address location="https://secured.teamyehey.com/payplus/services/payplus.asmx" />
</port>
<port name="PayplusHttpGet" binding="s0:PayplusHttpGet">
<http:address location="https://secured.teamyehey.com/payplus/services/payplus.asmx" />
</port>
<port name="PayplusHttpPost" binding="s0:PayplusHttpPost">
<http:address location="https://secured.teamyehey.com/payplus/services/payplus.asmx" />
</port>
</service>
</definitions>
My code to access the above webservice (for Process method) is as follows (which is almost an exact copy from the sample code in JWSDP tutorial) :
String qnameService = "Payplus";
String qnamePort = "PayplusSoap";
String BODY_NAMESPACE_VALUE = "http://secure.yehey.com/2003/01/PayPlus";
String ENCODING_STYLE_PROPERTY = "javax.xml.rpc.encodingstyle.namespace.uri";
String NS_XSD = "http://www.w3.org/2001/XMLSchema";
String URI_ENCODING = "http://schemas.xmlsoap.org/soap/encoding/";
ServiceFactory factory = ServiceFactory.newInstance();
Service service = factory.createService(new QName(qnameService));
QName port = new QName(qnamePort);
Call call = service.createCall(port);
call.setTargetEndpointAddress(urlstring);
call.setProperty(Call.SOAPACTION_USE_PROPERTY, new Boolean(true));
call.setProperty(Call.SOAPACTION_URI_PROPERTY, "http://secure.yehey.com/2003/01/PayPlus/Process");
call.setProperty(ENCODING_STYLE_PROPERTY, URI_ENCODING);
QName QNAME_TYPE_STRING = new QName(NS_XSD, "string");
call.setReturnType(QNAME_TYPE_STRING);
call.setOperationName(new QName(BODY_NAMESPACE_VALUE, "Process"));
call.addParameter("inpData", QNAME_TYPE_STRING, ParameterMode.IN);
String[] params = { getProcessString() }; // getProcessString here returns the parameter required
String result = (String)call.invoke(params);
System.out.println(result);
The error that I keep on getting is this:
java.rmi.RemoteException: System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.ArgumentNullException: Value cannot be null.
Parameter name: s
at System.IO.StringReader..ctor(String s)
at Payplus.Payplus.Process(String inpData)
Any help would be greatly appreciated. Thanks!

Are you using the JAXRPC implementation from java.sun.com
for your client invocations? IThis may be an implementation problem
and if you are not using the sun implementation, then I can not explain
the exception-
kathy

Similar Messages

  • Web Service  Stateless Session request using JDeveloepr 11g (JAX-RPC)

    I have been trying to consume web Service by sending Stateless Session request to the system.
    I generated the Java Proxy using JDeveloepr 11g, using JAX-RPC.
    As it is Stateless I need to add following SOAP Header for authentication
    <soap:Header>
    <wsse:Security soap:mustUnderstand="1">
    <wsse:UsernameToken>
    <wsse:Username>[email protected]</wsse:Username>
    <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wssusername-
    token-profile-1.0#PasswordText">adminOnDemand</wsse:Password>
    </wsse:UsernameToken>
    </wsse:Security>
    </soap:Header>
    To do this I tried clientuntcredentialprovider as suggested by most of the post online, but found of little help as the server complained of not be able to find the User Name and Password.
    To add to the mess problem I hit was I was not able to View the SOAP Request or Response sent by JDeveloper hence not helping me in debugging the same
    I have tried it on XML SPY by manually adding SOAP Header to the SOAP request and was able to find the response, but I have not been able to do the same using the JDeveloper 11g IDE.
    I have tried HTTP Analyzer assuming it might help, but unfortunately due to the huge size of WSDL, tool hanged my PC each time I loaded it.
    I know it should be fairly straight forward but just feel like missing something.
    Has anybody has got this thing working ?
    Regards,
    Deepak

    What exactly you mean that since your request is stateless you must send a Username token?
    Also, can you put here the code you used to populate the UNT.
    Finally, if possible, can you zip and email your wsdl, the http analyzer should be able to handle wsdls, even if they are huge.
    Thanks,
    Vishal

  • Use Array in JAX-RPC

    I want to send an array as parameter in the client of the JAX-RPC,how can I write the code?
    Here is my code,but it has some errors.
    int[] temp=new int[2];
    temp[0]=1;
    temp[1]=2;
    QName QNAME_TYPE_OBJECT = new QName("http://schemas.xmlsoap.org/soap/encoding/", "Array");
    call.addParameter("param", QNAME_TYPE_OBJECT,temp.getClass(), ParameterMode.PARAM_MODE_IN);
    Object[] params = {temp};
    String result = (String)call.invoke(params);
    How can I send the temp array correctly?
    thank you very much!

    In addition ,I find that if I change the parameter from int[] to String[],everything is ok!
    here is the code:
    String[] words = {"it", "was", "a", "dark", "and",     
    "stormy", "night"};
    QName QNAME_TYPE_OBJECT = new QName("http://schemas.xmlsoap.org/soap/encoding/", "Array");
    call.addParameter("param", QNAME_TYPE_OBJECT,words.getClass(), ParameterMode.PARAM_MODE_IN);
    Object[] params = {words};
    String result = (String)call.invoke(params);
    why?what I happenend?And I find that the error is that ClassCastError,i.e.
    String[] can be casted into Object[],but int[] can't,so the error occured.(I know this process by decompiling the class file).
    but the tutorial says JAX-rpc supports the int[],is it wrong?

  • Using MIME with JAX-RPC

    Hi,
    I am trying to send simple MIME body part using RPC.
    Where can I find a working code sample ?
    My problem is that I don't know how to pass the SOAPContext to the server side.
    Or failing while trying to deliver an activation DataHandler as parameter to my server side method.
    What is the correct way to do that (without using messaging) ?
    Thanks,
    Eran B.

    Please do not refer me to:
    http://xml.apache.org/soap samples/mime/MimeTest*.java
    The sample does not implement fully this feature.

  • Can i use SAX,DOM or JDOM within JAX-RPC ?

    Dear all,
    Im trying to create a web service , with methods that recive Element parameters (which i changed to strings) , and then parsing my xml node and returning objects. Im facing this error while creating the web service files: "java.loang.StackTraceElement does not have a public accessible empty constructor" .... This error appears with using one of the XML parsers ... an example of one method:
    public QuizInfo readXmlFile(int id, String clientId, String distId) throws RemoteException,org.jdom.JDOMException, Exception
          QuizInfo QuizObj = new QuizInfo();
           SAXBuilder builder = new SAXBuilder();
           Document doc = builder.build(new File( "c:quiz.xml"));
           Element firstNode = doc.getRootElement();
    .....can I use any xml parser within a method that i will use in my JAX-RPC web service ? and if , can anyone show me how ?
    thanx in advance

    Dear all ..... I found it !!!
    first of all , make sure that all the names of your methods used in your web service begins with a small letter !! thats one ... another thing is that i made another class that only calls the methods of the original class with the implementation , example of what im saying , remember the readXmlFile in the original class ... ok .. make another class, lets say its called CallServiceClass , with a method that calls the readXmlFile method in the originalService
    public QuizInfo readXmlFile(int id, String clientId, String distId) throws Exception{
              return originalService.readXmlFile( id,  clientId,  distId);
         }and then create the web service from the new class CallServiceClass !
    note that i threw an Exception , not a JDomException ... also note that for some IDEs , it will require that the method is a static method.

  • Web Service JAX-RPC/SOAP with JAXB

    Hello,
    During my research on JAX-RPC/SOAP as web service technology. I found only simple "helloworld" sample type what using simple String as aurgment. For my task, I required a more complex aurgment such as a complete contact info. I then did some sample code for JAXB and found it to be very useful as a XML/JAVA binding tool. It seems logical to use JAXB to parse and bind the complex aurgment. Though I have not seen any reference to this using it with JAX-RPC. Does JAX-RPC have the tool set to accomplish the same thing? JAX-RPC may have such thing, but using this JAXB seem logical, thus would I still "conform" to the JAX-RPC if I go this route. Any info would be much appreciative.
    Thanks in Advance,
    Mike

    The two JAX-RPC tools that I have used, the reference implementation and Apache Axis both have tools for mappiing XML to classes and vice-versa. Having used JAXB also, I have to say that both of these tools are much easier to use than JAXB.
    As far as whether it will conform, you can make a valid SOAP message using any tool you like.

  • SAAJ  vs JAX-RPC

    Hi Team,
    Whats the differences implementing web service clients  using SAAJ and JAX-RPC ?
    Do we have any performance related differences between these two ?
    If I am not worng, SAAJ dynamic way of calling web services which means that it will create SOAP message on fly for every request.
    So SAAJ  may take more time comapred to implementing the clients using JAX-RPC.
    Please correct me if my assumption is wrong.
    Thanks,Anil
    Edited by: Anilkumar Vippagunta on Jan 29, 2008 1:50 AM
    Edited by: Anilkumar Vippagunta on Jan 29, 2008 1:50 AM

    Hi Anil
    For more details have  alook on these links
    http://help.sap.com/saphelp_nw04/helpdata/en/d6/f9bc3d52f39d33e10000000a11405a/frameset.htm
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/c0bbd890-0201-0010-51bd-97029689f44b
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f98c731d-0e01-0010-dfa5-dfb8f49dac6e
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/ede71ec7-0701-0010-c08c-e284d530f384
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/3b28e590-0201-0010-968f-e10ed5328191
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/90a5266f-f721-2a10-7fb1-cefceb106ecf
    Regds
    Abhishek

  • How to create JAX-RPC WS manually

    I have a static WSDL file. Do you have any step by step instructions that show how to generate a JAX-RPC artifacts manually please? I can't do it using JDeveloper because my WSDL file is big so I got out of memory error when I tried to use JDev even though I increased the VM memory for JDev to 1024M already.
    That's why I have no choice but to generate the JAX-RPC artifacts manually.
    I'm using 10.3.1 WL.
    Thanks

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

  • How to generate JAX-RPC web services instead of JAX-WS webservices withOEPE

    How to generate JAX-RPC web services instead of JAX-WS webservices withOEPE? I am asking this because I need to pass xmlbeans generated objects as arguments in the web method. For JAX-WS there has to be a no argument constructor for it to be able to pass in theweb method. The workshop 10.3 was able to pass the xmlbeans generated object as the web service was implemented as a JAX-RPC web service....

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

  • JDeveloper JAX-RPC vs AXIS

    Hi everybody,
    I find that working with Axis and it's tools (wsdl2java) is easier than working with Oracle's SOAP implementation(webservicesassembler.jar).
    One advantadge of using oracle's solution is that ws that
    returns an Element type does not need a custom deserializer and Axis needs.
    Which more advantages do you think oracle's solution has?
    Why should we use jDev10's JAX/RPC web services?
    Thank you.

    Hello
    The first thing is you should really say "JAX-RPC vs AXIS", since both of them are Web Services Runtime/Development APIs. And Jdeveloper is just a tools that simnplifies the development and developmen of Web Services using JAX-RPC.
    So what about JAX-RPC vs Axis?
    I would say that Axis is/was a de-facto standard fro developing WS, since it is running in most of the application servers - OracleAS 10g included-. Where JAX-RPC is the standard defines by the Java Community Process (JCP) and is a mandatory features of J2EE 1.4 specifications. So by using JAX-RPC you will be able to use a set of API that are really standard based. Also as part of your decision you should take a look in more details about the services provided by JAX-RPC: http://java.sun.com/xml/jaxrpc/index.jsp and the different standards involved.
    Also I think that one important thing to take in consideration when you will make your decision is the future of Axis as we know it today release 1.0 If you see the Axis 2.0 Web site, it says that:
    "Axis2 is an effort to re-design and totally re-implement both Axis/Java and (eventually) Axis/C++ on a new architecture."
    Other considerations:
    Some of the important things to watch when you select your framework are also related to:
    - how you can interop with other framework (consuming or providing a service that is created with another stack)
    - how to handle attachement (size, types, performances, ..)
    When you will start to use Web Services in your system you may need to add different quality of services for example adding security (authentication, encryption, ...) or reliability (how I can be sure that my response has been received by my client application)
    All the Web Service Management (security, reliability, etc etc) is not currently well integrated in the Axis stack, so you will have to use a third party solution to have this type of features. (you can for example use Oracle Web Services Manager for that purpose)
    All these, and more, are more than just the 'SOAP' stack.
    Oracle, JAX-RPC, and more:
    First of all OC4J 10.1.3 support JAX-RPC as any J2EE 1.4, in addition we support WS-Security, WS-Reliability to integrate them to your enterprise, and a full integration with Oracle Web Services Manager.
    Oracle JAX-RPC implementation has also specific focus to ensure interoperability firs WS-Interoperability compliant -[url=http://www.ws-i.org/]WS-I is an open organization that defines the interoperability around WS.- services, but also based on 'real life validation scenarios' -especially with .Net- where we use our customer applications to validate our platform interoperability.
    Also, on the tooling side, our Web Services stack is fully integrated to Oracle JDevelope that allow you to develop easily JAX-RPC base Web Services (client or provider), based on several type of object/business logic (simple Java class, EJB, PL/SQL, SQL, ...); and deploy them very quickly to your application server
    Regards
    Tugdual Grall

  • Sending attachments using JAX-RPC

    Hi,
    can anyone give me an example for sending an attachment using JAX-RPC. I want to create a webservice that will expect an attachment. Also once the client snds the attachment how can i access it in the service?
    any help will be apreciated. Thanks.

    Did anyone test this?
    I am using a DataHandler in the server
    public String sendDocument(String name, DataHandler dh)
    DataHandler rdh = (DataHandler) dh;
         if (dh == null)
              return message+ "Received null attachment";
         DataSource ds = rdh.getDataSource();
         try
              dh.writeTo(new FileOutputStream("D:\\temp\\" + name));
         catch(java.io.IOException e)
         return message + " Processed attachment " + ":Stream Error: " + e.getMessage();
         return message + " Processed attachment" ;
    In the client I use Proxy which works fine:
    FileDataSource fs = new FileDataSource(fileName);
    if (fs == null)
         System.out.println("Invalid File Source");
    DataHandler dhSource = new DataHandler(fs);
         System.out.println(up.sendDocument(dhSource.getName(), dhSource));
    THIS WORKS FINE. I see the attachment is saved properly.
    When I try using DII:
    call.setOperationName(new QName(BODY_NAMESPACE_VALUE,"sendDocument"));
    QName QNAME_TYPE_DH = new QName(NS_XSD, "DataHandler");
    call.addParameter("String_1", QNAME_TYPE_STRING,ParameterMode.IN);
    call.addParameter("DataHandler_1", QNAME_TYPE_DH,ParameterMode.IN);
    FileDataSource fs = new FileDataSource(fileName);
    if (fs == null)
         System.out.println("Invalid File Source");
    else
              DataHandler dhSource = new DataHandler(fs);
              String dhName = dhSource.getName();
         Object[] params = new Object[] {dhName,dhSource};
         String result = (String)call.invoke(params);
         System.out.println(result);
    THIS DOES NOT WORK. I get an error.
    [java] serialization error: no serializer is registered for (class javax.activation.DataHandler, {http://www.w3.org/2001/XMLSchema}DataHandler)
    ANY POINTERS??????
    I even tried this:
    QName qnameAttachment = new QName(NS_XSD, "DataHandler");
    TypeMappingRegistry tr = service.getTypeMappingRegistry();
    TypeMapping tm = tr.createTypeMapping();
    tm.register(DataHandler.class,
    qnameAttachment,
    new JAFDataHandlerSerializerFactory(),
    new JAFDataHandlerDeserializerFactory());
         tr.registerDefault(tm);
    NO SUCCESS!
    Appreciate any responses....

  • Jax-RPC Client side: How to use multiple X509 client certs ?

    hi, (excuse me for my english)
    i'm looking for an answer to this question:
    I'm using the JAX-RPC libraries (JWSDP 2.0) for a web services client application in my app server (tomcat 4 under 1.4 Sun JVM) with HTTPS connection. All works fine when i'm using system.Setproperties for keystore and trustore.
    Buk now, I want to use different client SSL keys for the same app to consume the web service (one SSL client key for a group of users).
    Is it possible ?
    i've tried using custom SSLSocketFactory and custom KeyManager but it won't works: when the SSL connection is well established once, i can connect to the app with an invalide client cert ! (it seems SSL connection is in cache and i dont't know how to disable this cache).
    I have read some threads on this problem without answers ! (http://forum.java.sun.com/thread.jspa?forumID=331&threadID=333010 and http://forum.java.sun.com/thread.jspa?forumID=331&threadID=600372)
    Thanks
    Edited by: Buck007 on May 26, 2008 9:14 AM

    I have the same problem. If you find the solution please post it here :)
    thanks

  • XML Parser Error while creating Web service Client using JAX RPC

    hello evryone,
    Im facing XML Parser Error while creating web service client using JAX RPC. Im using Net Beans IDE for development purpose. I have wrote configuration file for client. Now i want to create Client stub. However i dont know how to do this in Net Beans. So i tried to do it from Command promt using command :
    wscompile -gen:client -d build -classpath build config-wsdl.xml
    here im getting Error:
    error parsing configuration file: XML parsing error: com.sun.xml.rpc.sp.ParseException:10: XML declaration may only begin entities
    Please help me out.
    Many thanks in advance,
    Kacee

    Can i use the client generated using jdeveloper 11g to import into the oracle forms 10g, i.e., form builder 10g. Currently this is the version we have in our office.

  • Using JAX-RPC handlers to proxy web service traffic

    Hi,
    I want to use JAX-RPC handlers to proxy web service traffic. In some instances the handler should modifiy / verify the message before forwarding the request to the remote web service end-point. Hence, the handler should forward the call by invoking the remote web service. In some cases the result from invoking the remove service should be post-processed by another proxy handler. To ensure that the result from invoking the remote service is available for post-processing I assume that the handler invoking the remote service must add the response message to the message context ( e g setProperty method) in the handler. Is this correctly understood?
    I would like to understand that this is a technically feasible and reasonable approach of using JAX-RPC. I'd really appreciate some feedback here.
    Many thanks,
    Tom

    Hi Eric,
    Thanks for your response. we are trying to access WSRR( manages end point urls for 7 different environments) and generate the end point dynamically at the design time. As we figured out WSRR is not compatible with OSB we are trying to implement these client side (OSB Proxy service) handlers which would get the dynamic endpoint depending on the environment used. I was able to create the handlers for this and set the jar in the classpath but the client service which should be using these handlers have to have these handlers defined in the deployment descriptor(web.xml) which am unable to see with a OSB project.
    Will there be a deployment descriptor(web.xml/webservices.xml) associated with Proxy services on OSB? Or Is there any other way to add custom JAX-RPC Handlers to a proxy service? Or is there any way to connect to WSRR directly?
    Thanks,
    Swetha

  • How to use user-defined packages in JAX-RPC web service

    I am trying to use Object of my class located in my package in jax-rpc webservice,the code is
    package supercomputer;
    import Hello.*;
    public class SuperImpl implements SuperIF
    public String sendParam(String data)
    Temp ob=new Temp();
    int i=ob.get1(10000);
    return data+"returned by supercomputer";
    Temp is located in Hello package,I have jar the Hello package as Hello.jar and has set its classpath in targets.xml of Ant tool.
    The code compiles well and service is deployed successfully,but when i try to call the service from the client its gives me following error.
    [echo] Running the supercomputer.SuperClient program....
    [java] java.rmi.ServerException: Missing port information
    [java] at com.sun.xml.rpc.client.StreamingSender._raiseFault(StreamingSender.java:357)
    [java] at com.sun.xml.rpc.client.StreamingSender._send(StreamingSender.java:228)
    [java] at supercomputer.SuperIF_Stub.sendParam(SuperIF_Stub.java:60)
    [java] at supercomputer.SuperClient.main(Unknown Source)
    I dont know if it deploys why it gives error on client side.
    Please tell how to use user-defined packages and class in jax-rpc service code ,i am not talking about passing user-defined parameters i am just talking about making objects of user defined classes in jax-rpc service.I think there is some problem in classpath.
    Please guide me in doing that.
    Thanks,
    Farrukh

    Farrukh,
    I don't know if your error is about a missing class from your custom package, ... what track did you followed to say that?
    To use your package in the implementation of you web service, you should only follow the rules of making a web application: put your package jar in your \lib directory inside WEB-INF/ or your package classes unjared in classes (also in WEB-INF/).
    As I already said, I have doubts that your error should be originated from a missing class from your package, but:
    -try to see the logs (errors?) when you deploy your web service that could give a hint about the problem.
    -try to see if you can access your endpoint through your browser to see if there is a online status
    -display your config/WSDL file, and the steps you did to build your web service.
    regards,
    Pedro Salazar.

Maybe you are looking for

  • Text clustering using kmeans & other classified algorithm

    Hi, Few questions: 1. How can we tweak Kmean_clustering algorithm to improve quality of clustering results? The current arguments the algorithm accepts are: MAX_DOCTERMS, MAX_FEATURES, THEME_ON , TOKEN_ON, STEM_ON, MEMORY_SIZE, SECTION_WEIGHT, CLUSTE

  • CANNOT_START-UP: Stars in Command-Line-Mode: "Deallocation of a pointer not

    HELLO EVERYONE, PLEASE CAN YOU HELP ME... My computer: Mac OS X (10.3.9) had froze, couldn't force quit..and i forced started it by holding the power button. Restarted it, came on: the grey-screen and apple, spinning-gear...satayed like that long tim

  • Call a Java API inside a java mapping

    Hi, I have a web service in SAP PI 7.0 that recives a PDF coded in base64. I need to call an external Java API provided by a partner for extract its digital signature and return it as Web Service Response. It's possible to do the call to a Java API i

  • AppleWorks and OS X 10.4.6

    After installing OS X 10.4.6, AppleWorks (v 6.2.9) seems intent upon crashing every single time I attempt to use it. I can launch A.W., and get to the Starting Points screen. I can even open a new Word Processing document. However, as soon as I touch

  • Move perfect external hd / iTunes to different Mac

    I have a 1tb external firewire drive on my iMac dedicated to iTunes. Everything is tagged, has artwork, just perfect, but my iMac is getting too slow. I want to move the drive to my MacBook Pro. Ideally, I'd like to keep my playlists too. If I hook t