XML Deserialization Error when calling WebService from WebDynrpo

Hi all,
when calling a WebService-method from my WebDynpro-application, I get the following error message:
"Deserializing fails. Nested message: XML Deserialization Error. Can not create instance of class [com.karmann.ApplMan.dto.SoftwareKomponenteDTO] when deserializing XML type [urn:com.karmann.ApplMan.dto][SoftwareKomponenteDTO].."
SoftwareKomponenteDTO is a class that I have implemented. It implements Serializable and overwrites the methods "equals()" and "hashcode()". It contains members of types long, String and java.sql.Date.
The method I call needs an argument of type SoftwareKomponenteDTO. Other methods which return something of type SoftwareKomponenteDTO do not make any problems.
The same error message appears when I test the WebService-method in the WebService-navigator. So I assume that the problem is not the way I call the method from WebDynpro.
Thanks for help,
Christoph

Thanks for this hint, Amar. But this points directly to my next problem: How can I set this parameter. I know how to set flat parameters (e.g. of type long, boolean, etc.). But how can I set a parameter of a complex type?
For example I can call
    wdContext.currentSaveElement().setIdFather(long id)
in order to set the parameter idFather of type long for the WebService-method save(). But there is no method
     wdContext.currentSaveElement().setIdFather(SoftwareKomponenteDTO aKomp)
Could you please help me on more time?
Kind regards,
Christoph

Similar Messages

  • XML Deserialization Error when calling WebService-method

    Hi all,
    when calling a WebService-method from my WebDynpro-application, I get the following error message:
    "Deserializing fails. Nested message: XML Deserialization Error. Can not create instance of class [com.karmann.ApplMan.dto.SoftwareKomponenteDTO] when deserializing XML type [urn:com.karmann.ApplMan.dto][SoftwareKomponenteDTO].."
    SoftwareKomponenteDTO is a class that I have implemented. It implements Serializable and overwrites the methods "equals()" and "hashcode()". It contains members of types long, String and java.sql.Date.
    The method I call needs an argument of type SoftwareKomponenteDTO. Other methods which return something of type SoftwareKomponenteDTO do not make any problems.
    The same error message appears when I test the WebService-method in the WebService-navigator. So I assume that the problem is not the way I call the method from WebDynpro.
    Thanks for help,
    Christoph

    Hi all,
    I found what my problem was. The complex type that I deliver to my method (i.e. SoftwareKomponenteDTO) must have a public constructor without parameters. I think that this is slightly confusing, because in the other direction (method delivers complex type as return value) this is not neccessary. Anyway, my problem's solved now.
    Regards,
    Christoph

  • Error when calling webservice from oracle function.

    Hi,
    I am getting following error when i am trying to call webserivce from oracle function. Please can anyone suggest the required solution. Below is the error obtained.
    Thanks.
    ERROR at line 1:
    ORA-31011: XML parsing failed
    ORA-19202: Error occurred in XML processing
    LPX-00225: end-element tag "UL" does not match start-element tag "P"
    Error at line 15
    ORA-06512: at "SYS.XMLTYPE", line 54
    ORA-06512: at "SCOTT.DEMO_SOAP", line 87
    ORA-06512: at "SCOTT.WEB_SERVICE", line 17

    The error message implies that the web service is returning something that is not well formed xml. Can you verify what is being returned by the web service call

  • Error When Call WebService from WebDynpro

    Hi,
    I´m with this error when i execute* the web service that i created on my WebAS:
    Request_CalculatorWSViDocument_add req = new Request_CalculatorWSViDocument_add();
    wdContext.nodeRequest_CalculatorWSViDocument_add().bind(req);
    wdContext.currentRequest_CalculatorWSViDocument_addElement().modelObject().setX(x);
    wdContext.currentRequest_CalculatorWSViDocument_addElement().modelObject().setY(y);
    wdContext.currentRequest_CalculatorWSViDocument_addElement().modelObject().execute();
    java.lang.NoSuchMethodError: com.sap.engine.services.webservices.jaxrpc.wsdl2java.BaseGeneratedStub._initParameter(Lcom/sap/engine/services/webservices/jaxrpc/wsdl2java/ServiceParam;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Class;)V
         at br.com.softtek.model.proxies.Config1BindingStub.add(Config1BindingStub.java:58)
         at br.com.softtek.model.proxies.Config1BindingStub.add(Config1BindingStub.java:101)
         at br.com.softtek.model.Request_CalculatorWSViDocument_add.execute(Request_CalculatorWSViDocument_add.java:91)
         at br.com.softtek.comp.CalculatorComp.executeOperation(CalculatorComp.java:217)
         at br.com.softtek.comp.wdp.InternalCalculatorComp.executeOperation(InternalCalculatorComp.java:214)
         at br.com.softtek.comp.CalculatorCompView.onActionAdd(CalculatorCompView.java:143)
         at br.com.softtek.comp.wdp.InternalCalculatorCompView.wdInvokeEventHandler(InternalCalculatorCompView.java:173)
         at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.invokeEventHandler(DelegatingView.java:87)
         at com.sap.tc.webdynpro.progmodel.controller.Action.fire(Action.java:67)
         at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.doHandleActionEvent(WindowPhaseModel.java:420)
         at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.processRequest(WindowPhaseModel.java:132)
         at com.sap.tc.webdynpro.clientserver.window.WebDynproWindow.processRequest(WebDynproWindow.java:335)
         at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:143)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:299)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessingStandalone(ClientSession.java:711)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:665)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:232)
         at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:152)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:62)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doPost(DispatcherServlet.java:53)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:390)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:264)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:347)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:325)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:887)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:241)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Any idea?
    Regards,
    Bruno

    Hi tulasi,
    My WebService uses "Simple SOAP".
    Naga Raju Meesala,
    The WebService type is "WebService Mode"l.
    Any idea?
    Regards,
    Bruno

  • XML Error while calling webservice from oracle function.

    I am getting an error while I am trying to call webservice from oracle function. Any ideas? Thanks.
    select get_new_string ('proxy:80', 'http://xxx/PatternVariations/SourceTest/WebMethods','Scott') from dual
    ERROR at line 1:
    ORA-31011: XML parsing failed
    ORA-19202: Error occurred in XML processing
    LPX-00225: end-element tag "H4" does not match start-element tag "P"
    Error at line 9
    ORA-06512: at "SYS.XMLTYPE", line 0
    ORA-06512: at "DORSBP00.DEMO_SOAP", line 82
    ORA-06512: at "DORSBP00.GET_NEW_STRING", line 11

    The error message implies that the web service is returning something that is not well formed xml. Can you verify what is being returned by the web service call

  • Error when call webservice on servlet

    Hi All,
    I'm having a problem when calling webservice inside the servlet on the WebLogic environment.
    My code:
    * Webservice:
    package ws;
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.PreparedStatement;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.util.Date;
    import javax.jws.WebMethod;
    import javax.jws.WebParam;
    import javax.jws.WebService;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    import javax.sql.DataSource;
    @WebService
    public class getData {
    public getData() {
    super();
    @WebMethod
    public String getHello() {
    return "HELLO HELLO";
    private Connection getConn() throws NamingException, SQLException {
    InitialContext ic = new InitialContext();
    DataSource ds = (DataSource)ic.lookup("jdbc/hnxwebsite");
    //System.out.println("POOL !!!!");
    Connection con = ds.getConnection();
    con.setAutoCommit(false);
    return con;
    @WebMethod
    public String getIndexData(@WebParam(name="param") String param) {
    StringBuffer sb = new StringBuffer();
    String sql =
    "Select * From idx_index_info iii where iii.index_code= ?";
    Connection con = null;
    PreparedStatement pstmt = null;
    ResultSet rs = null;
    try {
    con = getConn();
    pstmt = con.prepareStatement(sql);
    pstmt.setString(1, param);
    rs = pstmt.executeQuery();
    int columnCount = rs.getMetaData().getColumnCount();
    Object val;
    while (rs.next()) {
    for (int i = 1; i < columnCount; i++) {
    //System.out.println(i);
    val = rs.getObject(i);
    if (val != null)
    sb.append(val.toString() + "\n");
    } catch (SQLException e) {
    e.printStackTrace();
    } catch (NamingException e) {
    e.printStackTrace();
    } finally {
    try {
    if (rs != null)
    rs.close();
    if (pstmt != null)
    pstmt.close();
    if (con != null)
    con.close();
    } catch (Exception e) {
    e.printStackTrace();
    String str = sb.toString();
    int len = str.length();
    //System.out.println("LENGTH >>>>"+len);
    return str;
    public static void main(String[] arg) {
    Date date = new Date();
    System.out.println(date.toGMTString());
    getData gd = new getData();
    System.out.println(date.toGMTString());
    //System.out.println(gd.getIndexData("ACB"));
    * WebClient:
    package hnx;
    import java.util.Date;
    import java.util.Map;
    import javax.xml.namespace.QName;
    import javax.xml.soap.MessageFactory;
    import javax.xml.soap.SOAPBody;
    import javax.xml.soap.SOAPBodyElement;
    import javax.xml.soap.SOAPElement;
    import javax.xml.soap.SOAPMessage;
    import javax.xml.ws.BindingProvider;
    import javax.xml.ws.Dispatch;
    import javax.xml.ws.Service;
    import javax.xml.ws.WebServiceException;
    import javax.xml.ws.soap.SOAPBinding;
    public class wsClient {
    public wsClient() {
    super();
    public String procWeb() {
    String strmsg = null;
    try {
    QName serviceName = new QName("http://192.168.60.18:7001/","getDataService");
    // QName for Port As defined in wsdl.
    QName portName = new QName("http://192.168.60.18:7001/","getDataPort");
    // //Endpoint Address
    String endpointAddress = "http://192.168.60.18:7001/WsIndex/getDataPort?wsdl";
    // Create a dynamic Service instance
    Service service = Service.create(serviceName);
    service.addPort(portName, SOAPBinding.SOAP11HTTP_BINDING,
    endpointAddress);
    // Create a dispatch instance
    Dispatch<SOAPMessage> dispatch = service.createDispatch(portName,
    SOAPMessage.class, Service.Mode.MESSAGE);
    // Use Dispatch as BindingProvider
    BindingProvider bp = (BindingProvider) dispatch;
    // Optionally Configure RequestContext to send SOAPAction HTTP Header
    Map<String, Object> rc = bp.getRequestContext();
    rc.put(BindingProvider.SOAPACTION_USE_PROPERTY, Boolean.TRUE);
    rc.put(BindingProvider.SOAPACTION_URI_PROPERTY, "http://ws/");
    // Obtain a preconfigured SAAJ MessageFactory
    MessageFactory factory = ((SOAPBinding) bp.getBinding())
    .getMessageFactory();
    // Create SOAPMessage Request
    SOAPMessage request = factory.createMessage();
    // Request Body
    SOAPBody body = request.getSOAPBody();
    // Compose the soap:Body payload
    QName payloadName = new QName("http://ws/", "getIndexData","ns1");
    SOAPBodyElement payload = body.addBodyElement(payloadName);
    SOAPElement message = payload.addChildElement( "param");
    message.addTextNode("HNX302");
    request.saveChanges();
    // Invoke the endpoint synchronously
    System.out.println(message);
    SOAPMessage reply = null;
    try { // Invoke Endpoint Operation and read response
    reply = dispatch.invoke(request);
    } catch (WebServiceException wse) {
    wse.printStackTrace();
    // process the reply
    SOAPBody bodyRes = reply.getSOAPBody();
    SOAPBodyElement nextSoapBodyElement = (SOAPBodyElement) bodyRes
    .getChildElements().next();
    SOAPElement soapElement = (SOAPElement) nextSoapBodyElement
    .getChildElements().next();
    strmsg = soapElement.getValue();
    System.out.println("AAA >>"+strmsg);
    } catch (Exception wse) {
    wse.printStackTrace();
    return strmsg;
    public static void main(String[] arg) {
    wsClient ws = new wsClient();
    Date date = new Date();
    System.out.println(date.toGMTString());
    System.out.println(ws.procWeb());
    System.out.println(date.toGMTString());
    * Servlet:
    package hnx;
    import java.io.IOException;
    import java.io.PrintWriter;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import ws.GetData;
    import ws.GetDataPortClient;
    import ws.GetDataService;
    public class getIndex extends HttpServlet {
    private static final String CONTENT_TYPE = "text/html; charset=UTF-8";
    public void init(ServletConfig config) throws ServletException {
    super.init(config);
    public void doPost(HttpServletRequest request,
    HttpServletResponse response) throws ServletException,
    IOException {
    doGet(request, response);
    public void doGet(HttpServletRequest request,
    HttpServletResponse response) throws ServletException,
    IOException {
    response.reset();
    response.flushBuffer();
    response.setContentType(CONTENT_TYPE);
    PrintWriter out = response.getWriter();
    // GetDataService service = new GetDataService();
    // GetData getData = service.getGetDataPort();
    // String str = getData.getIndexData("HNX302");
    // int length = str.length();
    // response.setContentLength(length);
    wsClient ws = new wsClient();
    String str = ws.procWeb();
    try {
    out.println(str);
    } catch (Exception e) {
    e.printStackTrace();
    out.close();
    ERROR: >>>>>[Another instance of the application is running on the server.  JDeveloper redeploy the application.]
    [Application SClient stopped but not undeployed from Server Instance IntegratedWebLogicServer]
    [Running application SClient on Server Instance IntegratedWebLogicServer...]
    [03:41:48 PM] ---- Deployment started. ----
    [03:41:48 PM] Target platform is (Weblogic 10.3).
    [03:41:48 PM] Retrieving existing application information
    [03:41:48 PM] Running dependency analysis...
    [03:41:48 PM] Deploying 2 profiles...
    [03:41:48 PM] Wrote Web Application Module to C:\Users\W7\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\o.j2ee\drs\SClient\sgetDataWebApp.war
    [03:41:48 PM] Wrote Enterprise Application Module to C:\Users\W7\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\o.j2ee\drs\SClient
    [03:41:49 PM] Redeploying Application...
    [03:41:49 PM] Application Redeployed Successfully.
    [03:41:49 PM] The following URL context root(s) were defined and can be used as a starting point to test your application:
    [03:41:49 PM] http://192.168.9.100:7101/SClient
    [03:41:49 PM] Elapsed time for deployment: 1 second
    [03:41:49 PM] ---- Deployment finished. ----
    Run startup time: 1380 ms.
    [Application SClient deployed to Server Instance IntegratedWebLogicServer]
    Target URL -- http://127.0.0.1:7101/SClient/getindex
    [param: null]
    javax.xml.ws.WebServiceException: com.ctc.wstx.exc.WstxIOException: Exceeding stated content length of 228
         at com.sun.xml.ws.encoding.StreamSOAPCodec.encode(StreamSOAPCodec.java:117)
         at com.sun.xml.ws.encoding.SOAPBindingCodec.encode(SOAPBindingCodec.java:258)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:165)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:101)
         at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:604)
         at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:563)
         at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:548)
         at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:445)
         at com.sun.xml.ws.client.Stub.process(Stub.java:248)
         at com.sun.xml.ws.client.dispatch.DispatchImpl.doInvoke(DispatchImpl.java:189)
         at com.sun.xml.ws.client.dispatch.DispatchImpl.invoke(DispatchImpl.java:215)
         at hnx.wsClient.procWeb(wsClient.java:75)
         at hnx.getIndex.doGet(getIndex.java:40)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:326)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: com.ctc.wstx.exc.WstxIOException: Exceeding stated content length of 228
         at com.ctc.wstx.sw.BaseStreamWriter.finishDocument(BaseStreamWriter.java:1687)
         at com.ctc.wstx.sw.BaseStreamWriter.writeEndDocument(BaseStreamWriter.java:585)
         at com.sun.xml.ws.message.saaj.SAAJMessage.writeTo(SAAJMessage.java:396)
         at com.sun.xml.ws.encoding.StreamSOAPCodec.encode(StreamSOAPCodec.java:114)
         ... 29 more
    Caused by: java.net.ProtocolException: Exceeding stated content length of 228
         at weblogic.net.http.ContentLengthOutputStream.write(ContentLengthOutputStream.java:39)
         at com.ctc.wstx.io.UTF8Writer.flush(UTF8Writer.java:96)
         at com.ctc.wstx.sw.BufferingXmlWriter.flush(BufferingXmlWriter.java:214)
         at com.ctc.wstx.sw.BufferingXmlWriter.close(BufferingXmlWriter.java:194)
         at com.ctc.wstx.sw.BaseStreamWriter.finishDocument(BaseStreamWriter.java:1685)
         ... 32 more
    java.lang.NullPointerException
         at hnx.wsClient.procWeb(wsClient.java:82)
         at hnx.getIndex.doGet(getIndex.java:40)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:326)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Can anyone help?
    Thanks in advance.
    LTThoi

    I'm no webservices/servlet expert , but can you check the obvious out here -
    javax.xml.ws.WebServiceException: com.ctc.wstx.exc.WstxIOException: Exceeding stated content length of 228
    at ......
    at hnx.wsClient.procWeb(wsClient.java:75)+ // check if you are passign something thats more than 228 chars
    at hnx.getIndex.doGet(getIndex.java:40)

  • An error when calling DAQmx from TestStand

    Hi,
    I get very mystic error when calling DAQmx Create Channel (Digital input) and DAQmx Read (Digital Bool 1Line 1Point) vis. Difficulty is that it does not occur every time. It is random. Any ideas what might cause this error? I uninstalled Traditional DAQ drives because they are not in use but it does not help.
    Please, see attachment.
    BR,
    Jick
    Attachments:
    daqerror.PNG ‏80 KB

    Here is some additional information. See attachments.
    I can not get that error using MAX or looping it only. There is something else outside which causes the error. It can not be Traditional DAQ because I uninstalled it. These vis are running in a loop during the test in the batchmodel.
    BR,
    Jick
    Attachments:
    daqerror2.PNG ‏33 KB
    daqerror3.PNG ‏15 KB

  • Getting deserialization error when calling a secured webservice

    Hi All,
    I am getting deserialization error: java.lang.ClassCastException: oracle.xml.parser.v2.XMLElement when I am calling my secured web service through a proxy client.
    I have secured my webservice using a keystore, I had created using keytool . In key store I have created keys using RSA algorithm.
    when I am doing all this for a webservice in which input is a string variable, then it is working.
    But if I am passing a document then it is giving me ERROR OWS-04045 Malformed Request Message: deserialization error: java.lang.ClassCastException: oracle.xml.parser.v2.XMLElement .
    Below is the code of java class, I have exposed as webservice :
    import java.io.StringWriter;
    import javax.xml.transform.Transformer;
    import javax.xml.transform.TransformerConfigurationException;
    import javax.xml.transform.TransformerException;
    import javax.xml.transform.TransformerFactory;
    import javax.xml.transform.dom.DOMSource;
    import javax.xml.transform.stream.StreamResult;
    import org.w3c.dom.Document;
    public class READXML {
    public String getXML(Document xmlDocument) {
    TransformerFactory tFactory = TransformerFactory.newInstance();
    Transformer transformer = null;
    try {
    transformer = tFactory.newTransformer();
    } catch (TransformerConfigurationException e) {
    e.printStackTrace();
    StringWriter writer = new StringWriter();
    try {
    transformer.transform(new DOMSource(xmlDocument),
    new StreamResult(writer));
    } catch (TransformerException e) {
    e.printStackTrace();
    return writer.toString();
    Appreciate if any body can help me to resolve the issue.
    thanks in advance

    Mike,
    I have tried by validating xml, again it is giving same error.
    when I am not securing my webservice then it is working fine.
    The problem is coming only when i am securing my webservice.

  • Error when invoking WebService from WTK 2.5 client

    hi all,
    i have developend an EJB3 webservice using JBoss4.0.5.GA...
    i wrote a java client using wstools and it worked fine
    Then i used StubGenerator from WTK , it generated stubs....
    i then tried tocall the jbossws.. the jbossws received the call, but in i got a disaster error when i received back the response from the webservice.
    this was the response from the webservice (as i checked in the WTK network monitor)
    <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'>
    <env:Header/>
    <env:Body><ns1:loginResponse xmlns:ns1='http://org.jboss.ws/ejb3ws' xmlns:xsi='http://www.w3.org/2001/XMLSchema
    -instance'/>
    </env:Body>
    </env:Envelope>and this was the exception that i was able to see in the WTK
    javax.xml.rpc.JAXRPCException: java.rmi.MarshalException: (1)Missing end tag for Body or Envelope
         at com.sun.j2mews.xml.rpc.SOAPDecoder.decode(+243)
         at com.sun.j2mews.xml.rpc.OperationImpl.invoke(+90)
         at com.mm.j2me.ws.WSRemoteSEI_Stub.login(+48)
         at com.mm.j2me.midp.model.HTTPCommunicationHandler.createAccount(+36)
         at com.mm.j2me.midp.model.RemoteModelRequestHandler.createAccount(+16)
         at com.mm.j2me.midp.model.RemoteModelProxy.createAccount(+16)
         at com.mm.j2me.midp.model.ModelFacade.createAccount(+16)
         at com.mm.j2me.midp.ui.UIController$EventDispatcher.run(+277)Well, i can see both Body and Envelopen in the message that has been sent back, so can anyone tell me what's wrong with WTK??
    thanks in advance and regards
    marco

    Hi all,
    as many developers I have encountered the famous "java.rmi.MarshallException:(1)Missing end tag for Body or Envelope" during the development of my WS app for J2ME (JSR 172).
    It is correct that is the empty tag <soapenv:Header /> causing this error.
    To fix this error, it is necessary to stop the server to generate this empty header in the response stream.
    I have fixed this error for Axis2: unfortunaly it is necessary to modify a class in Axiom library. This library is used in Axis2 to produce the SOAP response, you can download the source code at http://ws.apache.org/commons/axiom/source-repository.html.
    Here the class to modify:
    axiom\modules\axiom-impl\src\main\java\org\apache\axiom\soap\impl\llom\soap11\SOAP11Factory.java
    by commenting the line 273 in the method called getDefaultEnvelope() to prevent the empty header insertion in SOAP response:
    public SOAPEnvelope getDefaultEnvelope() throws SOAPProcessingException {
            OMNamespace ns =
                    new OMNamespaceImpl(
                            SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI,
                            SOAP11Constants.SOAP_DEFAULT_NAMESPACE_PREFIX);
            SOAPEnvelopeImpl env = new SOAPEnvelopeImpl(ns, this);
            //createSOAPHeader(env); the line to be commented
            createSOAPBody(env);
            return env;
        }Finally you have to recompile Axiom using Maven to obtain the fixed package axiom-impl.jar and to replace this package on the lib repository of your Axis2 server.
    A little tricky to fix this bug but now my app runs perfectly ;)
    Enjoy!
    Romain Pellerin
    http://www.gasp-mobilegaming.org

  • Error while calling webservice from oracle8i

    Hi,
    i am trying to call a webservice from a stored procedure in Oracle 8i.
    I am getting the following error.
    ORA-31011: XML Parsing failed
    ORA-19202: Error occurred in XML processing
    LPX-00225: end-element tag "body" does not match start element tag "br"
    Kinldy help me in knowing the cause of this issue. Also i wanted to know if
    webservices will work in oracle 8i enterprise edition release 8.1.7.4.0
    or do we need to add any patches for it.
    Thanks,
    Sathia

    This forum is for XML DB issues. XML DB is a feature of 9iR2 and later.You need t look in the XML Technology forum

  • Error when call fmx from browser

    I have used OAS 4.0.7 with yt40.dll upgraded, NT 4.0
    SP4 and Developer 6.
    I have configured application cartridge according Developer6
    Server doc instructions.
    When I call fmx from browser Netscape 4.6
    (http://hostname/webforms?module=fmx_name) the error "Applet
    oracle.forms.engine.Main class oracle.forms.engine.Main could not
    be loaded".
    OAS inserts in file \orant\ows\website40\log the message
    "Parameter module is missing from URL and cartridge settings"
    Can anybody help me please?.
    Ruy Chicaco
    null

    Hi Adnan
    I have configured my apps similary the example in
    \orant\tools\devdem60\web then it rans fine.
    Thanks,
    Ruy Chicaco.
    Adnan Imtiaz (guest) wrote:
    : Hi there,
    : I'm facing the same problem myself...but mine goes into doing
    : something & returns an "Internal Error" message in the
    : browser....
    : Try running the static HTML file from its directory & see
    whether
    : that even runs or not....
    : Any helpp would be greatly appreciated.....
    : Thanks.
    : Ruy chicaco (guest) wrote:
    : : I have used OAS 4.0.7 with yt40.dll upgraded, NT 4.0
    : : SP4 and Developer 6.
    : : I have configured application cartridge according Developer6
    : : Server doc instructions.
    : : When I call fmx from browser Netscape 4.6
    : : (http://hostname/webforms?module=fmx_name) the error "Applet
    : : oracle.forms.engine.Main class oracle.forms.engine.Main could
    : not
    : : be loaded".
    : : OAS inserts in file \orant\ows\website40\log the message
    : : "Parameter module is missing from URL and cartridge settings"
    : : Can anybody help me please?.
    : : Ruy Chicaco
    null

  • Getting ie error when calling event from code.

    Hi all!
    I've got an application (running on 6.40 sp8, ep6 sp2) that is pretty basic by all means. Since I want to implement some way to tell the user when he/she has made an error or just to inform him/her about something, I decided to use the ConfirmationDialog.
    I've created an action called onActionShowErrorMessage in my view. This action is tied to my controller and an event defined in the controller.
    Hence, when I want to show the ConfirmationDialog to show the user an error message, I call the controller method and in the method I fire the event that my view method is looking for.
    So far so good..
    When I call my controller method from a button action in the view everything works nicely, but when I try to call it from the wdInit method it fails?! I do get the ConfirmationDialog up but I also get an IE error window telling me that IE is trying to open a page it cannot find. I have no idea why it tries to open any page at all, since there is no navigation defined for this action.
    Anyone got an idea? I couldn't find any good stuff in the system logs either
    Best regards,
    Andreas

    Hello Sam!
    Thanks for your answer! I would like to use something more of a pop thing, since i want to make sure the user sees it. The MessageManager does not work as good as it used to anymore, since it puts all messages in the bottom of the page. This page needs to be scrolled in order to see the error message..
    Anyone got an idea of a workaround? I'm reading a propsfile, and in case I'm not able to read it I want to display this to the user.
    B.R
    Andreas

  • Getting 500 Error when calling XI from Siebel

    Hi,
      We have generated a WSDL file from XI and gave it to Siebel team. They are getting a 500 Error when they try to call us using that WSDL file. Below is the error message they are getting.
    "[1] Error Invoking service 'MI_SIEBEL_WS_ORDER_TOXI_OUT', method 'MI_SIEBEL_WS_ORDER_TOXI_OUT' at step 'Call Web Service'. (SBL-BPR-00162).
    [2] HTTP Request error during 'Submitting Data Send HTTP request': 'Status code -500'(SBL-EAI-04117)"
    Thanks in advance for the help.
    Thanks
    Kumar

    Hi,
    Are you sure your Sender SOAP adapter is configured properly. Also ensure that the SIEBEL team is using the right URL to communicate to the SOAP adapter.
    First try using SOAP Client and see if the scenario is working fine. If so then the problem lies in SIEBEL.
    Check this link for confiuring SOAP sender
    http://help.sap.com/saphelp_nw04/helpdata/en/fc/5ad93f130f9215e10000000a155106/content.htm
    Thanks,
    Pakash

  • Error when calling WebService

    Hi friends,
    I am trying to consume a WebService and the WSDL that I try to consume passes the test performed with report RSSIDL_DESERIALIZE_DEMO.
    But when I try to execute the WebService, I get the following error:
    Error (id=SOAP:1.001): CX_ST_GROUP_MISSING_CASE:XSLT exception.Element 'cn' missing
    Can anybody help me ? Thanks

    Please Check the  following note
    Error when indexing data provider services (next by time)
    SAP Note Number: 1377473 
    Symptom
    When you index data from the data provider services,
    the termination "Error occurred in the next by timestamp data service at last timestamp" or "SOAP:1.001 CX_ST_GROUP_MISSING_CASE:XSLT exception.Element 'NamespaceID' missing" occurs (see the job log in the cockpit of the
    Enterprise Search).
    Thie exception occurs if the service is implemented for the complete indexing but not for the delta indexing.

  • Error when call javabean from form6i

    I try to call javabean from Form6i. I have downlaoded four excample from Oracle Sample Code. But I can't run the example whenever from Form Builder or browser. When I run the html in IE or Natscape browser, I meet a eorror message :
    java.lang.NoClassDefFound Error: sun/applet/AppletViewer
    I have copy all example classes into e:\orant\forms60\java\oracle\forms\demos\ directory and the jar file copy into e:\orant\forms60\java directory.
    Inside the html I set the codebase to e:\orant\forms60\java.
    Is there any error or I still need to set some anothers settings?
    Help please?
    null

    Hi Adnan
    I have configured my apps similary the example in
    \orant\tools\devdem60\web then it rans fine.
    Thanks,
    Ruy Chicaco.
    Adnan Imtiaz (guest) wrote:
    : Hi there,
    : I'm facing the same problem myself...but mine goes into doing
    : something & returns an "Internal Error" message in the
    : browser....
    : Try running the static HTML file from its directory & see
    whether
    : that even runs or not....
    : Any helpp would be greatly appreciated.....
    : Thanks.
    : Ruy chicaco (guest) wrote:
    : : I have used OAS 4.0.7 with yt40.dll upgraded, NT 4.0
    : : SP4 and Developer 6.
    : : I have configured application cartridge according Developer6
    : : Server doc instructions.
    : : When I call fmx from browser Netscape 4.6
    : : (http://hostname/webforms?module=fmx_name) the error "Applet
    : : oracle.forms.engine.Main class oracle.forms.engine.Main could
    : not
    : : be loaded".
    : : OAS inserts in file \orant\ows\website40\log the message
    : : "Parameter module is missing from URL and cartridge settings"
    : : Can anybody help me please?.
    : : Ruy Chicaco
    null

Maybe you are looking for