Return-Path: X-Original-To: apmail-axis-java-dev-archive@www.apache.org Delivered-To: apmail-axis-java-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DEE917B5F for ; Fri, 22 Jul 2011 13:44:46 +0000 (UTC) Received: (qmail 11640 invoked by uid 500); 22 Jul 2011 13:44:45 -0000 Delivered-To: apmail-axis-java-dev-archive@axis.apache.org Received: (qmail 11549 invoked by uid 500); 22 Jul 2011 13:44:45 -0000 Mailing-List: contact java-dev-help@axis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@axis.apache.org Delivered-To: mailing list java-dev@axis.apache.org Received: (qmail 11541 invoked by uid 99); 22 Jul 2011 13:44:44 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 22 Jul 2011 13:44:44 +0000 X-ASF-Spam-Status: No, hits=4.8 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,FREEMAIL_REPLY,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of zhangyx395@hotmail.com designates 65.54.190.156 as permitted sender) Received: from [65.54.190.156] (HELO bay0-omc3-s18.bay0.hotmail.com) (65.54.190.156) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 22 Jul 2011 13:44:36 +0000 Received: from BAY158-W46 ([65.54.190.189]) by bay0-omc3-s18.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.4675); Fri, 22 Jul 2011 06:44:16 -0700 Message-ID: Content-Type: multipart/alternative; boundary="_dc1bd881-86cf-428e-808d-349d42193e56_" X-Originating-IP: [109.153.41.144] From: Yunxi Zhang To: Subject: RE: org.apache.axis2.AxisFault: org.apache.axiom.om.impl.llom.OMTextImpl cannot be cast to org.apache.axiom.om.OMElement Date: Fri, 22 Jul 2011 21:44:14 +0800 Importance: Normal In-Reply-To: References: , MIME-Version: 1.0 X-OriginalArrivalTime: 22 Jul 2011 13:44:16.0555 (UTC) FILETIME=[730DA7B0:01CC4875] --_dc1bd881-86cf-428e-808d-349d42193e56_ Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: 8bit Hi, Andreas, How can provide you the server side stack trace? In my service implementation, i used Exception.printStackTrace to catch the exception to print out error messages, and these error messages are actually printed out from the server side. Regards, Yunxi > From: andreas.veithen@gmail.com > Date: Fri, 22 Jul 2011 09:55:03 +0200 > Subject: Re: org.apache.axis2.AxisFault: org.apache.axiom.om.impl.llom.OMTextImpl cannot be cast to org.apache.axiom.om.OMElement > To: java-dev@axis.apache.org > > The exception is from the client side but indicates that the actual > error is occurring on the server side. We would need the server side > stack trace to see what is going on here. > > Andreas > > On Thu, Jul 21, 2011 at 19:13, Yunxi Zhang wrote: > > Hi, guys, > > I've tried parsing an XML file to OMElement structure to be embedded into > > other OMElement element. The codes I used to do the parse are listed below: > > public OMElement parseXMLToOMElement(String sourceFile) throws > > FileNotFoundException,XMLStreamException{ > > File file=new File(sourceFile); > > OMElement element=null; > > FileInputStream fis=new FileInputStream(file); > > XMLInputFactory xif=XMLInputFactory.newInstance(); > > XMLStreamReader reader=xif.createXMLStreamReader(fis); > > StAXOMBuilder builder=new StAXOMBuilder(reader); > > element=builder.getDocumentElement(); > > return element; > > > > } > > However, When sending the parsed messages to the target service, I got the > > error messages there as follows: > > org.apache.axis2.AxisFault: org.apache.axiom.om.impl.llom.OMTextImpl cannot > > be cast to org.apache.axiom.om.OMElement > > at > > org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(Utils.java:531) > > at > > org.apache.axis2.description.RobustOutOnlyAxisOperation$RobustOutOnlyOperationClient.handleResponse(RobustOutOnlyAxisOperation.java:91) > > at > > org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:421) > > at > > org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229) > > at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165) > > at org.apache.axis2.client.ServiceClient.sendRobust(ServiceClient.java:475) > > at org.apache.axis2.client.ServiceClient.sendRobust(ServiceClient.java:456) > > at > > portalB.ReceivingRequestForSharedResources.decisionMaking(ReceivingRequestForSharedResources.java:442) > > at > > portalB.ReceivingRequestForSharedResources.receivingSOAPMessage(ReceivingRequestForSharedResources.java:359) > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > at > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > > at > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > > at java.lang.reflect.Method.invoke(Method.java:597) > > at > > org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver.invokeBusinessLogic(RawXMLINOnlyMessageReceiver.java:90) > > at > > org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:110) > > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181) > > at > > org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:172) > > at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:146) > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:641) > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) > > at > > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:306) > > at > > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) > > at > > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:240) > > at > > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161) > > at > > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164) > > at > > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100) > > at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:550) > > at > > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) > > at > > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:380) > > at > > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:243) > > at > > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:188) > > at > > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:166) > > at > > org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:288) > > at > > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) > > at > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) > > at java.lang.Thread.run(Thread.java:680) > > > > Has anyone got any idea about it? Thank you! > > Best regards, > > Yunxi > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org > For additional commands, e-mail: java-dev-help@axis.apache.org > --_dc1bd881-86cf-428e-808d-349d42193e56_ Content-Type: text/html; charset="gb2312" Content-Transfer-Encoding: 8bit
Hi, Andreas,

How can provide you the server side stack trace?

In my service implementation, i used Exception.printStackTrace to catch the exception to print out error messages, and these error messages are actually printed out from the server side.

Regards,

Yunxi

> From: andreas.veithen@gmail.com
> Date: Fri, 22 Jul 2011 09:55:03 +0200
> Subject: Re: org.apache.axis2.AxisFault: org.apache.axiom.om.impl.llom.OMTextImpl cannot be cast to org.apache.axiom.om.OMElement
> To: java-dev@axis.apache.org
>
> The exception is from the client side but indicates that the actual
> error is occurring on the server side. We would need the server side
> stack trace to see what is going on here.
>
> Andreas
>
> On Thu, Jul 21, 2011 at 19:13, Yunxi Zhang <zhangyx395@hotmail.com> wrote:
> > Hi, guys,
& gt; > I've tried parsing an XML file to OMElement structure to be embedded into
> > other OMElement element. The codes I used to do the parse  are listed below:
> > public OMElement parseXMLToOMElement(String sourceFile) throws
> > FileNotFoundException,XMLStreamException{
> > File file=new File(sourceFile);
> > OMElement element=null;
> > FileInputStream fis=new FileInputStream(file);
> > XMLInputFactory xif=XMLInputFactory.newInstance();
> > XMLStreamReader reader=xif.createXMLStreamReader(fis);
> > StAXOMBuilder builder=new StAXOMBuilder(reader);
> > element=builder.getDocumentElement();
> > return element;
> >
> > }
> > However, When sending the parsed messages to the target service, I got the
> > error messages there as follows:
> > org.apache.axis2.AxisFault: org.apache.axiom.om.impl.llom.OMTextImpl cannot
> > be cast to org.apache.axiom.om.OMElement
> > at
> > org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(Utils.java:531)
> > at
> > org.apache.axis2.description.RobustOutOnlyAxisOperation$RobustOutOnlyOperationClient.handleResponse(RobustOutOnlyAxisOperation.java:91)
> > at
> > org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:421)
> > at
> > org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)
> > at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)
> > at org.apache.axis2.client.ServiceClient.sendRobust(ServiceClient.java:475)
> > at org.apache.axis2.client.ServiceClient.sendRobust(ServiceClient.java:456)
> > at
> > portalB.ReceivingRequestForSharedResources.decisionMaking(ReceivingRequestForSharedResources.java:442)
> > at
> & gt; portalB.ReceivingRequestForSharedResources.receivingSOAPMessage(ReceivingRequestForSharedResources.java:359)
> > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > at
> > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> > at
> > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> > at java.lang.reflect.Method.invoke(Method.java:597)
> > at
> > org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver.invokeBusinessLogic(RawXMLINOnlyMessageReceiver.java:90)
> > at
> > org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:110)
> > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181)
> > at
> > org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:172)
> > at org.apache.axis2.trans port.http.AxisServlet.doPost(AxisServlet.java:146)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
> > at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:306)
> > at
> > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
> > at
> > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:240)
> > at
> > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161)
> > at
> > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
> > at
> > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
> > at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:550)
> > at
> > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
> > at
> > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:380)
> > at
> > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:243)
> > at
> > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:188)
> > at
> > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:166)
> > at
> > org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:288)
> > at
> > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> > at
> > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
> > at java.lang.Thread.run(Thread.java:680)
> >
> > Has anyone go t any idea about it? Thank you!
> > Best regards,
> > Yunxi
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
> For additional commands, e-mail: java-dev-help@axis.apache.org
>
--_dc1bd881-86cf-428e-808d-349d42193e56_--