Results 1 to 3 of 3
  1. #1
    Felissa is offline Member
    Join Date
    Jun 2007
    Posts
    95
    Rep Power
    0

    Default create a Java Client to consume WEBSERVICES XML SOAP

    Greetings. I must create a client java to invoke webservices SOAP, with User and key.I' ve read a lot of the API of apache axis, but not yet I still have the problem. This giving to an exception saxParserException me when creating soap envelope, that use the method call.invoke (soapEnvelope). ; if somebody has some client for webservices soap. it would be a serious helpful.

    Please see the code.

    Java Code:
    package com.ibi.agents;
    
    import java.io.BufferedReader; 
    import java.io.DataInputStream; 
    import java.io.FileInputStream; 
    import java.io.FileReader; 
    import java.io.IOException; 
    import java.io.InputStream; 
    import java.io.ObjectInputStream; 
    import java.io.Reader; 
    import java.io.StringBufferInputStream; 
    import java.net.MalformedURLException; 
    import java.net.URL; 
    import java.net.URLConnection; 
    import java.nio.IntBuffer; 
    import java.util.List;
    
    import javax.naming.InitialContext; 
    import javax.xml.soap.SOAPBody;
    
    import org.apache.axis.AxisFault; 
    import org.apache.axis.client.Call; 
    import org.apache.axis.message.SOAPEnvelope; 
    import org.apache.axis.utils.ByteArray; 
    import org.apache.soap.Body; 
    import org.xml.sax.SAXException;
    
    import com.ibi.edaqm.XDDocument; 
    import com.sun.web.server.WebService;
    
    public class PruebaMain { 
     public static DataInputStream dis; 
     /** 
      * @param args 
      */ 
     public static void main(String[] args) { 
      
       
      //URLConnection urlConection = new URLConnection("http://rmcadev.cantv.com.ve:8000/sap/bc/soap/rfc"); 
      // TODO Auto-generated method stub 
    //   URL url= new URL(""); 
      Call call; 
        
        
         try { 
          call = new Call("http://rmcadev.cantv.com.ve:8000/sap/bc/soap/rfc"); 
          call.setTargetEndpointAddress(new URL("http://rmcadev.cantv.com.ve:8000/sap/bc/soap/rfc"));
    
          call.setOperation("Z_F2V3_ASC_RMCA_OBTENERSALDOCU"); 
          call.setSOAPActionURI("http://www.sap.com/Z_F2V3_ASC_RMCA_OBTENERSALDOCU"); 
          call.setUseSOAPAction(true); 
          String soapString=new String("<SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"><SOAP-ENV:Header>  <sapsess:Session xmlns:sapsess=\"http://www.sap.com/webas/630/soap/features/session/\"><enableSession>true</enableSession></sapsess:Session></SOAP-ENV:Header><SOAP-ENV:Body><ns1:Z_F2V3_ASC_RMCA_OBTENERSALDOCU xmlns:ns1=\"urn:sap-com:document:sap:rfc:functions\"><APLICACION>CTC</APLICACION><CEDULARIF/><CODIGOAREA>212</CODIGOAREA><CODIGOIC/><CTACONTRATO/><LISTANEGRA/><TELEFONO>2379999</TELEFONO></ns1:Z_F2V3_ASC_RMCA_OBTENERSALDOCU></SOAP-ENV:Body></SOAP-ENV:Envelope>"); 
          SOAPEnvelope soap; 
            InputStream is; 
    StringBufferInputStream ibis = new StringBufferInputStream(soapString);   
    
          soap = new SOAPEnvelope(ibis); 
    System.out.println(soapString); 
    call.invoke(soap); 
    List li = call.getOutputValues(); 
         } catch (AxisFault e) { 
          // TODO Auto-generated catch block 
          e.printStackTrace(); 
         } catch (MalformedURLException e) { 
          // TODO Auto-generated catch block 
          e.printStackTrace(); 
         /*} catch (SAXException e) { 
          // TODO Auto-generated catch block 
          e.printStackTrace(); 
       */ 
         } catch (SAXException e) { 
          // TODO Auto-generated catch block 
          e.printStackTrace(); 
         } 
        
        
     
    
     } 
    }
    Felissa:p

  2. #2
    Eric is offline Senior Member
    Join Date
    Jun 2007
    Posts
    111
    Rep Power
    0

    Default

    This is an example about calling a WS using Axis with password and user
    Java Code:
    Call call = null;
    Service service = new Service();
    
    try {
    call = (Call) service.createCall();
    call.setTargetEndpointAddress("URL");
    call.setUsername("user");
    call.setPassword("pass"));
    call.setOperationName(
    new QName ("name of the webservice", "service"));
    org.w3c.dom.Element test =
    (org.w3c.dom.Element) call.invoke(array of objects)
    
    } catch (ServiceException e) {
    e.printstacktrace();
    System.err.println("Algo malo pas&#243;");
    }
    you have to write in url, user,pass,name of the webservice, service,array of objects your proper information

  3. #3
    keshari is offline Member
    Join Date
    May 2008
    Posts
    7
    Rep Power
    0

    Default

    Hi All,

    Me facing a problem related to java web services.I am using jdk-6u3,Eclipse and Tomcat 5.0.I am making the web service of WsEpp Class shown below

    @WebService

    public class WsEpp
    {
    EppService objcls;

    @WebMethod

    public int registerDomain(String ACTIVITY_ID,String DOMAIN_NAME,String DOMHOSTNAME1,
    String DOMSERVER_IP_ADDRESS1,String DOMHOSTNAME2,String DOMSERVER_IP_ADDRESS2,
    String DOM_MX ,String DOM_MX_IP,String DOM_REGISTRAR,String DOM_RCONTACTID,
    String DOM_ACONTACTID,String DOM_BCONTACTID,String DOM_TCONTACTID,String DOM_AUTHCODE,
    String DOM_CURRENT_REGISTRAR,String DOM_AUTHORIZATION_CODE,String DOM_REG_FIRSTNAME,
    String DOM_REG_LASTNAME,String DOM_REG_EMAIL,String DOM_REG_COMPANY_NAME,String DOM_REG_ADDRESS,String DOM_REG_CITY,String DOM_REG_COUNTRY,String DOM_REG_STATE,String DOM_REG_ZIP,String DOM_REG_PHONE,String DOM_REG_COUNTRY_CODE,String DOM_REG_AREA_CODE,String DOM_REG_FAX,String DOM_REG_MOBILE,String DOM_ADM_FIRST_NAME,String DOM_ADM_LAST_NAME,String DOM_ADM_EMAIL,String DOM_ADM_ADDRESS,String DOM_ADM_CITY,String DOM_ADM_COUNTRY,String DOM_ADM_STATE,String DOM_ADM_ZIP,String DOM_ADM_PHONE,String DOM_ADM_COUNTRY_CODE ,String DOM_ADM_AREA_CODE,String DOM_ADM_FAX,String DOM_ADM_MOBILE,String DOM_BILL_FIRST_NAME,String DOM_BILL_LAST_NAME,String DOM_BILL_EMAIL,String DOM_BILL_ADDRESS,String DOM_BILL_CITY,String DOM_BILL_COUNTRY,String DOM_BILL_STATE,String DOM_BILL_ZIP,String DOM_BILL_PHONE,String DOM_BILL_COUNTRY_CODE,String DOM_BILL_AREA_CODE,String DOM_BILL_FAX ,
    String DOM_BILL_MOBILE,String DOM_TECH_FIRST_NAME,String DOM_TECH_LAST_NAME,String DOM_TECH_EMAIL,String DOM_TECH_ADDRESS,String DOM_TECH_CITY,String DOM_TECH_COUNTRY,String DOM_TECH_STATE,String DOM_TECH_ZIP,String DOM_TECH_PHONE,String DOM_TECH_COUNTRY_CODE,String DOM_TECH_AREA_CODE,String DOM_TECH_FAX,String DOM_TECH_MOBILE ,int DURATION)
    {
    objcls=new EppService();
    int result=objcls.createDomain(ACTIVITY_ID,DOMAIN_NAME ,DOMHOSTNAME1,DOMSERVER_IP_ADDRESS1,
    DOMHOSTNAME2,DOMSERVER_IP_ADDRESS2,DOM_MX,DOM_MX_I P,DOM_REGISTRAR,
    DOM_RCONTACTID,DOM_ACONTACTID,DOM_BCONTACTID,DOM_T CONTACTID,
    DOM_AUTHCODE,DOM_CURRENT_REGISTRAR,DOM_AUTHORIZATI ON_CODE,
    DOM_REG_FIRSTNAME,DOM_REG_LASTNAME,DOM_REG_EMAIL,D OM_REG_COMPANY_NAME,
    DOM_REG_ADDRESS,DOM_REG_CITY,DOM_REG_COUNTRY,DOM_R EG_STATE,DOM_REG_ZIP,
    DOM_REG_PHONE,DOM_REG_COUNTRY_CODE,DOM_REG_AREA_CO DE,DOM_REG_FAX,
    DOM_REG_MOBILE,DOM_ADM_FIRST_NAME,DOM_ADM_LAST_NAM E,DOM_ADM_EMAIL,
    DOM_ADM_ADDRESS,DOM_ADM_CITY,DOM_ADM_COUNTRY,DOM_A DM_STATE,
    DOM_ADM_ZIP,DOM_ADM_PHONE,DOM_ADM_COUNTRY_CODE,DOM _ADM_AREA_CODE,
    DOM_ADM_FAX,DOM_ADM_MOBILE,DOM_BILL_FIRST_NAME,DOM _BILL_LAST_NAME,
    DOM_BILL_EMAIL,DOM_BILL_ADDRESS,DOM_BILL_CITY,DOM_ BILL_COUNTRY,
    DOM_BILL_STATE,DOM_BILL_ZIP,DOM_BILL_PHONE,DOM_BIL L_COUNTRY_CODE,
    DOM_BILL_AREA_CODE,DOM_BILL_FAX,DOM_BILL_MOBILE,DO M_TECH_FIRST_NAME,
    DOM_TECH_LAST_NAME,DOM_TECH_EMAIL,DOM_TECH_ADDRESS ,DOM_TECH_CITY,
    DOM_TECH_COUNTRY,DOM_TECH_STATE,DOM_TECH_ZIP,DOM_T ECH_PHONE,DOM_TECH_COUNTRY_CODE,
    DOM_TECH_AREA_CODE,DOM_TECH_FAX,DOM_TECH_MOBILE,DU RATION);
    return result;
    }
    }


    The EppService Class is shown below

    public class EppService {

    public int createDomain(String ACTIVITY_ID,String DOMAIN_NAME,String DOMHOSTNAME1,
    String DOMSERVER_IP_ADDRESS1,String DOMHOSTNAME2,String DOMSERVER_IP_ADDRESS2,
    String DOM_MX ,String DOM_MX_IP,String DOM_REGISTRAR,String DOM_RCONTACTID,
    String DOM_ACONTACTID,String DOM_BCONTACTID,String DOM_TCONTACTID,String DOM_AUTHCODE,
    String DOM_CURRENT_REGISTRAR,String DOM_AUTHORIZATION_CODE,String DOM_REG_FIRSTNAME,
    String DOM_REG_LASTNAME,String DOM_REG_EMAIL,String DOM_REG_COMPANY_NAME,String DOM_REG_ADDRESS,String DOM_REG_CITY,String DOM_REG_COUNTRY,String DOM_REG_STATE,String DOM_REG_ZIP,String DOM_REG_PHONE,
    String DOM_REG_COUNTRY_CODE,String DOM_REG_AREA_CODE,String DOM_REG_FAX,String DOM_REG_MOBILE,String DOM_ADM_FIRST_NAME,String DOM_ADM_LAST_NAME,String DOM_ADM_EMAIL,String DOM_ADM_ADDRESS,String DOM_ADM_CITY,String DOM_ADM_COUNTRY,String DOM_ADM_STATE,String DOM_ADM_ZIP,String DOM_ADM_PHONE,
    String DOM_ADM_COUNTRY_CODE ,String DOM_ADM_AREA_CODE,String DOM_ADM_FAX,String DOM_ADM_MOBILE,String DOM_BILL_FIRST_NAME,String DOM_BILL_LAST_NAME,String DOM_BILL_EMAIL,String DOM_BILL_ADDRESS,String DOM_BILL_CITY,String DOM_BILL_COUNTRY,String DOM_BILL_STATE,String DOM_BILL_ZIP,String DOM_BILL_PHONE,String DOM_BILL_COUNTRY_CODE,String DOM_BILL_AREA_CODE,String DOM_BILL_FAX ,
    String DOM_BILL_MOBILE,String DOM_TECH_FIRST_NAME,String DOM_TECH_LAST_NAME,String DOM_TECH_EMAIL,String DOM_TECH_ADDRESS,String DOM_TECH_CITY,String DOM_TECH_COUNTRY,String DOM_TECH_STATE,String DOM_TECH_ZIP,String DOM_TECH_PHONE,String DOM_TECH_COUNTRY_CODE,String DOM_TECH_AREA_CODE,String DOM_TECH_FAX,String DOM_TECH_MOBILE ,int DURATION)

    {
    int x;
    n4i.PrintClass obj_PrintClass= new n4i.PrintClass();
    x =obj_PrintClass.printData(DURATION);
    System.out.println(x);
    return x;
    }
    }

    The PrintClass is as shown below


    public class PrintClass {
    public int printData(int type)
    {
    int str = 0;
    PrintLib obj_PrintLib = new PrintLib();
    switch (type)
    {
    case 1: str = obj_PrintLib.returnTest1("","","","","","","","",
    "","","","","","","","","","","","","","",""," ","" ,
    "","","","","","","","","","","","","","","",
    "","","","","","","","","","","","","","",""," ",
    "","","","","","","","","","","","","",0);
    break;

    case 2: str = obj_PrintLib.returnTest2("","","","","","","","",
    "","","","","","","","","","","","","","",""," ","" ,
    "","","","","","","","","","","","","","","",
    "","","","","","","","","","","","","","",""," ",
    "","","","","","","","","","","","","",0);
    break;

    case 3: str = obj_PrintLib.returnData(3);
    break;

    default: str = 9;

    }
    return str;
    }
    }

    The PrintLib is as shown below



    public class PrintLib {

    private static epp_Command command_data = null;
    private static epp_CheckResult[] check_results = null;

    private static Format df = new SimpleDateFormat(Globals.DATE_TIME_FORMAT);

    public PrintLib()
    {

    System.out.println("CONSTRUCTOR 1");
    this.command_data = new epp_Command();
    System.out.println("CONSTRUCTOR 2");

    }


    public int returnTest1(String ACTIVITY_ID,String DOMAIN_NAME,String DOMHOSTNAME1,
    String DOMSERVER_IP_ADDRESS1,String DOMHOSTNAME2,String DOMSERVER_IP_ADDRESS2,
    String DOM_MX ,String DOM_MX_IP,String DOM_REGISTRAR,String DOM_RCONTACTID,
    String DOM_ACONTACTID,String DOM_BCONTACTID,String DOM_TCONTACTID,String DOM_AUTHCODE,
    String DOM_CURRENT_REGISTRAR,String DOM_AUTHORIZATION_CODE,String DOM_REG_FIRSTNAME,
    String DOM_REG_LASTNAME,String DOM_REG_EMAIL,String DOM_REG_COMPANY_NAME,String DOM_REG_ADDRESS,String DOM_REG_CITY,String DOM_REG_COUNTRY,String DOM_REG_STATE,String DOM_REG_ZIP,String DOM_REG_PHONE,
    String DOM_REG_COUNTRY_CODE,String DOM_REG_AREA_CODE,String DOM_REG_FAX,String DOM_REG_MOBILE,String DOM_ADM_FIRST_NAME,String DOM_ADM_LAST_NAME,String DOM_ADM_EMAIL,String DOM_ADM_ADDRESS,String DOM_ADM_CITY,String DOM_ADM_COUNTRY,String DOM_ADM_STATE,String DOM_ADM_ZIP,String DOM_ADM_PHONE,
    String DOM_ADM_COUNTRY_CODE ,String DOM_ADM_AREA_CODE,String DOM_ADM_FAX,String DOM_ADM_MOBILE,String DOM_BILL_FIRST_NAME,String DOM_BILL_LAST_NAME,String DOM_BILL_EMAIL,String DOM_BILL_ADDRESS,String DOM_BILL_CITY,String DOM_BILL_COUNTRY,String DOM_BILL_STATE,String DOM_BILL_ZIP,String DOM_BILL_PHONE,String DOM_BILL_COUNTRY_CODE,String DOM_BILL_AREA_CODE,String DOM_BILL_FAX ,
    String DOM_BILL_MOBILE,String DOM_TECH_FIRST_NAME,String DOM_TECH_LAST_NAME,String DOM_TECH_EMAIL,String DOM_TECH_ADDRESS,String DOM_TECH_CITY,String DOM_TECH_COUNTRY,String DOM_TECH_STATE,String DOM_TECH_ZIP,String DOM_TECH_PHONE,String DOM_TECH_COUNTRY_CODE,String DOM_TECH_AREA_CODE,String DOM_TECH_FAX,String DOM_TECH_MOBILE,int DURATION)
    {
    return 1;
    }

    public int returnTest2(String ACTIVITY_ID,String DOMAIN_NAME,String DOMHOSTNAME1,
    String DOMSERVER_IP_ADDRESS1,String DOMHOSTNAME2,String DOMSERVER_IP_ADDRESS2,
    String DOM_MX ,String DOM_MX_IP,String DOM_REGISTRAR,String DOM_RCONTACTID,
    String DOM_ACONTACTID,String DOM_BCONTACTID,String DOM_TCONTACTID,String DOM_AUTHCODE,
    String DOM_CURRENT_REGISTRAR,String DOM_AUTHORIZATION_CODE,String DOM_REG_FIRSTNAME,
    String DOM_REG_LASTNAME,String DOM_REG_EMAIL,String DOM_REG_COMPANY_NAME,String DOM_REG_ADDRESS,String DOM_REG_CITY,String DOM_REG_COUNTRY,String DOM_REG_STATE,String DOM_REG_ZIP,String DOM_REG_PHONE,
    String DOM_REG_COUNTRY_CODE,String DOM_REG_AREA_CODE,String DOM_REG_FAX,String DOM_REG_MOBILE,String DOM_ADM_FIRST_NAME,String DOM_ADM_LAST_NAME,String DOM_ADM_EMAIL,String DOM_ADM_ADDRESS,String DOM_ADM_CITY,String DOM_ADM_COUNTRY,String DOM_ADM_STATE,String DOM_ADM_ZIP,String DOM_ADM_PHONE,
    String DOM_ADM_COUNTRY_CODE ,String DOM_ADM_AREA_CODE,String DOM_ADM_FAX,String DOM_ADM_MOBILE,String DOM_BILL_FIRST_NAME,String DOM_BILL_LAST_NAME,String DOM_BILL_EMAIL,String DOM_BILL_ADDRESS,String DOM_BILL_CITY,String DOM_BILL_COUNTRY,String DOM_BILL_STATE,String DOM_BILL_ZIP,
    String DOM_BILL_PHONE,String DOM_BILL_COUNTRY_CODE,String DOM_BILL_AREA_CODE,String DOM_BILL_FAX ,String DOM_BILL_MOBILE,String DOM_TECH_FIRST_NAME,String DOM_TECH_LAST_NAME,String DOM_TECH_EMAIL,String DOM_TECH_ADDRESS,String DOM_TECH_CITY,String DOM_TECH_COUNTRY,String DOM_TECH_STATE,
    String DOM_TECH_ZIP,String DOM_TECH_PHONE,String DOM_TECH_COUNTRY_CODE,
    String DOM_TECH_AREA_CODE,String DOM_TECH_FAX,String DOM_TECH_MOBILE,int DURATION)
    {
    return 2;
    }

    public int returnData(int data)
    {
    return data;
    }
    }



    The generated WSDL is as shown below
    <?xml version="1.0" encoding="UTF-8"?>
    <wsdl:definitions targetNamespace="http://DefaultNamespace" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://DefaultNamespace" xmlns:intf="http://DefaultNamespace" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <!--WSDL created by Apache Axis version: 1.4
    Built on Apr 22, 2006 (06:55:48 PDT)-->
    <wsdl:types>
    <schema elementFormDefault="qualified" targetNamespace="http://DefaultNamespace" xmlns="http://www.w3.org/2001/XMLSchema">
    <element name="registerDomain">
    <complexType>
    <sequence>
    <element name="ACTIVITY_ID" type="xsd:string"/>
    <element name="DOMAIN_NAME" type="xsd:string"/>
    <element name="DOMHOSTNAME1" type="xsd:string"/>
    <element name="DOMSERVER_IP_ADDRESS1" type="xsd:string"/>
    <element name="DOMHOSTNAME2" type="xsd:string"/>
    <element name="DOMSERVER_IP_ADDRESS2" type="xsd:string"/>
    <element name="DOM_MX" type="xsd:string"/>
    <element name="DOM_MX_IP" type="xsd:string"/>
    <element name="DOM_REGISTRAR" type="xsd:string"/>
    <element name="DOM_RCONTACTID" type="xsd:string"/>
    <element name="DOM_ACONTACTID" type="xsd:string"/>
    <element name="DOM_BCONTACTID" type="xsd:string"/>
    <element name="DOM_TCONTACTID" type="xsd:string"/>
    <element name="DOM_AUTHCODE" type="xsd:string"/>
    <element name="DOM_CURRENT_REGISTRAR" type="xsd:string"/>
    <element name="DOM_AUTHORIZATION_CODE" type="xsd:string"/>
    <element name="DOM_REG_FIRSTNAME" type="xsd:string"/>
    <element name="DOM_REG_LASTNAME" type="xsd:string"/>
    <element name="DOM_REG_EMAIL" type="xsd:string"/>
    <element name="DOM_REG_COMPANY_NAME" type="xsd:string"/>
    <element name="DOM_REG_ADDRESS" type="xsd:string"/>
    <element name="DOM_REG_CITY" type="xsd:string"/>
    <element name="DOM_REG_COUNTRY" type="xsd:string"/>
    <element name="DOM_REG_STATE" type="xsd:string"/>
    <element name="DOM_REG_ZIP" type="xsd:string"/>
    <element name="DOM_REG_PHONE" type="xsd:string"/>
    <element name="DOM_REG_COUNTRY_CODE" type="xsd:string"/>
    <element name="DOM_REG_AREA_CODE" type="xsd:string"/>
    <element name="DOM_REG_FAX" type="xsd:string"/>
    <element name="DOM_REG_MOBILE" type="xsd:string"/>
    <element name="DOM_ADM_FIRST_NAME" type="xsd:string"/>
    <element name="DOM_ADM_LAST_NAME" type="xsd:string"/>
    <element name="DOM_ADM_EMAIL" type="xsd:string"/>
    <element name="DOM_ADM_ADDRESS" type="xsd:string"/>
    <element name="DOM_ADM_CITY" type="xsd:string"/>
    <element name="DOM_ADM_COUNTRY" type="xsd:string"/>
    <element name="DOM_ADM_STATE" type="xsd:string"/>
    <element name="DOM_ADM_ZIP" type="xsd:string"/>
    <element name="DOM_ADM_PHONE" type="xsd:string"/>
    <element name="DOM_ADM_COUNTRY_CODE" type="xsd:string"/>
    <element name="DOM_ADM_AREA_CODE" type="xsd:string"/>
    <element name="DOM_ADM_FAX" type="xsd:string"/>
    <element name="DOM_ADM_MOBILE" type="xsd:string"/>
    <element name="DOM_BILL_FIRST_NAME" type="xsd:string"/>
    <element name="DOM_BILL_LAST_NAME" type="xsd:string"/>
    <element name="DOM_BILL_EMAIL" type="xsd:string"/>
    <element name="DOM_BILL_ADDRESS" type="xsd:string"/>
    <element name="DOM_BILL_CITY" type="xsd:string"/>
    <element name="DOM_BILL_COUNTRY" type="xsd:string"/>
    <element name="DOM_BILL_STATE" type="xsd:string"/>
    <element name="DOM_BILL_ZIP" type="xsd:string"/>
    <element name="DOM_BILL_PHONE" type="xsd:string"/>
    <element name="DOM_BILL_COUNTRY_CODE" type="xsd:string"/>
    <element name="DOM_BILL_AREA_CODE" type="xsd:string"/>
    <element name="DOM_BILL_FAX" type="xsd:string"/>
    <element name="DOM_BILL_MOBILE" type="xsd:string"/>
    <element name="DOM_TECH_FIRST_NAME" type="xsd:string"/>
    <element name="DOM_TECH_LAST_NAME" type="xsd:string"/>
    <element name="DOM_TECH_EMAIL" type="xsd:string"/>
    <element name="DOM_TECH_ADDRESS" type="xsd:string"/>
    <element name="DOM_TECH_CITY" type="xsd:string"/>
    <element name="DOM_TECH_COUNTRY" type="xsd:string"/>
    <element name="DOM_TECH_STATE" type="xsd:string"/>
    <element name="DOM_TECH_ZIP" type="xsd:string"/>
    <element name="DOM_TECH_PHONE" type="xsd:string"/>
    <element name="DOM_TECH_COUNTRY_CODE" type="xsd:string"/>
    <element name="DOM_TECH_AREA_CODE" type="xsd:string"/>
    <element name="DOM_TECH_FAX" type="xsd:string"/>
    <element name="DOM_TECH_MOBILE" type="xsd:string"/>
    <element name="DURATION" type="xsd:int"/>
    </sequence>
    </complexType>
    </element>
    <element name="registerDomainResponse">
    <complexType>
    <sequence>
    <element name="registerDomainReturn" type="xsd:int"/>
    </sequence>
    </complexType>
    </element>
    </schema>
    </wsdl:types>

    <wsdl:message name="registerDomainResponse">

    <wsdlart element="impl:registerDomainResponse" name="parameters"/>

    </wsdl:message>

    <wsdl:message name="registerDomainRequest">

    <wsdlart element="impl:registerDomain" name="parameters"/>

    </wsdl:message>

    <wsdlortType name="WsEpp">

    <wsdlperation name="registerDomain">

    <wsdl:input message="impl:registerDomainRequest" name="registerDomainRequest"/>

    <wsdlutput message="impl:registerDomainResponse" name="registerDomainResponse"/>

    </wsdlperation>

    </wsdlortType>

    <wsdl:binding name="WsEppSoapBinding" type="impl:WsEpp">

    <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>

    <wsdlperation name="registerDomain">

    <wsdlsoapperation soapAction=""/>

    <wsdl:input name="registerDomainRequest">

    <wsdlsoap:body use="literal"/>

    </wsdl:input>

    <wsdlutput name="registerDomainResponse">

    <wsdlsoap:body use="literal"/>

    </wsdlutput>

    </wsdlperation>

    </wsdl:binding>

    <wsdl:service name="WsEppService">

    <wsdl port binding="impl:WsEppSoapBinding" name="WsEpp">

    <wsdlsoap:address location="http://localhost:8080/WebServiceProject/services/WsEpp"/>

    </wsdlort>

    </wsdl:service>

    </wsdl:definitions>

    And when I am sending the request the response comes like below


    - <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> - <soapenv:Body> - <soapenv:Fault> <faultcode>soapenv:Server.userException</faultcode> <faultstring>java.lang.reflect.InvocationTargetE xc eption</faultstring> - <detail> <ns1:hostname xmlns:ns1="http://xml.apache.org/axis/">net-df0ab1ca865</ns1:hostname> </detail> </soapenv:Fault> </soapenv:Body> </soapenv:Envelope>


    The faultcode and faultstring is the field which I am not getting.
    And the most funny thing is that,when I make a simple Test.java file which uses the object of PrintLib,then its running perfectally without web service,on the other hand in webservice The object of PrintLib is not instantiated.Means on the console the message printed "CONSTRUCTER 1"
    which I have used in PrintLib.


    Kindally provide me help,Thanks in advance

Similar Threads

  1. SOAP Client
    By sathish_2111 in forum Advanced Java
    Replies: 2
    Last Post: 01-27-2010, 08:08 AM
  2. java webServices
    By renukadevi.karri in forum New To Java
    Replies: 0
    Last Post: 01-10-2008, 01:09 PM
  3. Replies: 0
    Last Post: 11-13-2007, 11:13 AM
  4. Java GForge SOAP Interface 0.0.7
    By JavaBean in forum Java Software
    Replies: 0
    Last Post: 07-09-2007, 05:41 PM
  5. Java GForge SOAP Interface 0.0.4
    By JavaBean in forum Java Software
    Replies: 0
    Last Post: 06-26-2007, 10:50 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •