Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 70902 invoked from network); 24 Jun 2005 02:22:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 24 Jun 2005 02:22:30 -0000 Received: (qmail 31332 invoked by uid 500); 24 Jun 2005 02:22:28 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 31270 invoked by uid 500); 24 Jun 2005 02:22:28 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 31257 invoked by uid 99); 24 Jun 2005 02:22:28 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [192.87.106.226] (HELO ajax.apache.org) (192.87.106.226) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Jun 2005 19:22:27 -0700 Received: from ajax.apache.org (ajax.apache.org [127.0.0.1]) by ajax.apache.org (Postfix) with ESMTP id DEDE113 for ; Fri, 24 Jun 2005 04:22:25 +0200 (CEST) Message-ID: <1848301020.1119579745895.JavaMail.jira@ajax.apache.org> Date: Fri, 24 Jun 2005 04:22:25 +0200 (CEST) From: "Srinath Perera (JIRA)" To: axis-dev@ws.apache.org Subject: [jira] Resolved: (AXIS2-23) I've writen two clients to access Google and Amazon Web APIs, After recieving the Response I get the following Exception. In-Reply-To: <2125807922.1117775226685.JavaMail.jira@ajax.apache.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/AXIS2-23?page=3Dall ] =20 Srinath Perera resolved AXIS2-23: --------------------------------- Resolution: Fixed According to the Gayan the issue is fixed .. closing the Issue > I've writen two clients to access Google and Amazon Web APIs, After recie= ving the Response I get the following Exception. > -------------------------------------------------------------------------= ------------------------------------------------ > > Key: AXIS2-23 > URL: http://issues.apache.org/jira/browse/AXIS2-23 > Project: Apache Axis 2.0 (Axis2) > Type: Bug > Components: om > Environment: Windows XP sp1, > Reporter: L.P.Gayan Asanka > Assignee: Srinath Perera > > Hi All, > I have built a programs to access Google Web API and Amazon Web API via A= XIS2. The operation is ?doGoogleSearch? in Google WSDL and ?search? in Amaz= on WSDL, I can set the number of search results that should be included in = the response message. In Google When the number of results is 1 or 2 it is = working almost properly, But when the number of results are getting higher = (that means the SOAP msg is big) I am getting an exception. When the result= s count is 10, most probably this exception is thrown. In the case of Amazo= n, the exception is always thrown. This programs worked with M1 successfull= y. > I guess the problem is with OM and Stax, I hope your aid to solve this pr= oblem. > Exception thrown is:- > org.apache.axis.om.OMException: javax.xml.stream.XMLStreamException > =09at org.apache.axis.soap.impl.llom.builder.StAXSOAPModelBuilder.next(St= AXSOAPModelBuilder.java:295) > =09at org.apache.axis.om.impl.llom.OMNodeImpl.build(OMNodeImpl.java:272) > =09at org.apache.axis.om.impl.llom.OMSerializerUtil.serializeNormal(OMSer= ializerUtil.java:166) > =09at org.apache.axis.om.impl.llom.OMElementImpl.serialize(OMElementImpl.= java:660) > =09at org.apache.axis.om.impl.llom.OMElementImpl.serializeWithCache(OMEle= mentImpl.java:610) > =09at org.apache.axis.om.impl.llom.OMTextImpl.serializeWithCache(OMTextIm= pl.java:91) > =09at org.apache.axis.om.impl.llom.OMTextImpl.serialize(OMTextImpl.java:9= 6) > =09at org.apache.axis.om.impl.llom.OMElementImpl.serialize(OMElementImpl.= java:634) > =09at org.apache.axis.om.impl.llom.OMElementImpl.serialize(OMElementImpl.= java:681) > =09at samples.google.search.ClientCallbackHandler.extractDetails(ClientCa= llbackHandler.java:96) > =09at samples.google.search.ClientCallbackHandler.onComplete(ClientCallba= ckHandler.java:76) > =09at org.apache.axis.clientapi.InOutMEPClient$1.run(InOutMEPClient.java:= 218) > =09at java.lang.Thread.run(Thread.java:534) > Caused by: javax.xml.stream.XMLStreamException > =09at com.bea.xml.stream.MXParser.fillBuf(MXParser.java:3346) > =09at com.bea.xml.stream.MXParser.more(MXParser.java:3361) > =09at com.bea.xml.stream.MXParser.parseAttribute(MXParser.java:2368) > =09at com.bea.xml.stream.MXParser.parseStartTag(MXParser.java:2176) > =09at com.bea.xml.stream.MXParser.nextImpl(MXParser.java:1700) > =09at com.bea.xml.stream.MXParser.next(MXParser.java:1249) > =09at org.apache.axis.soap.impl.llom.builder.StAXSOAPModelBuilder.next(St= AXSOAPModelBuilder.java:256) > =09... 12 more > SOAP message is:- > > > > > > > true > 9 > false > 11 > > > http://www.radinks.n= et/ftp/faq.php > 8k > > > > > > > true=09=09=09=09 > <b>...<= /b> You need to have the <b>Java</b> <b>Runtime</b&= gt; <b>Enviorenment</b> installed. the JRE is <b>...</= b><br> X Window system installed and you will need the <b>J= ava</b> <b>Runtime</b> <b>Enviorenment</b> as= <b>...</b> > > What is FTP</title= > > </item> > <item xsi:type=3D"ns1:ResultElement"> > <URL xsi:type=3D"xsd:string">http://forums.devshe= d.com/archive/t-132738/What-are-these</URL> > <cachedSize xsi:type=3D"xsd:string">16k</cachedSi= ze> > <directoryCategory xsi:type=3D"ns1:DirectoryCateg= ory"> > <fullViewableName xsi:type=3D"xsd:string"></f= ullViewableName> > <specialEncoding xsi:type=3D"xsd:string"></sp= ecialEncoding> > </directoryCategory> > <directoryTitle xsi:type=3D"xsd:string"></directo= ryTitle> > <hostName xsi:type=3D"xsd:string"></hostName> > <relatedInformationPresent xsi:type=3D"xsd:boolea= n">true</relatedInformationPresent> > <snippet xsi:type=3D"xsd:string"><b>...<= /b> 3 - <b>java</b> run time <b>enviorenment</b>= 4 - Software Development Kit <b>...</b> The JRE is<br> = the <b>Java</b> <b>Runtime</b> Environment, and con= sists of the JVM, core <b>Java</b> libraries, <b>...</= b></snippet> > <summary xsi:type=3D"xsd:string"></summary> > <title xsi:type=3D"xsd:string">What are these?</t= itle> > </item> > <item xsi:type=3D"ns1:ResultElement"> > <URL xsi:type=3D"xsd:string">http://forums.devshe= d.com/t119864/sc080f62a8ebb741eb05e19e780435bf3.html</URL> > <cachedSize xsi:type=3D"xsd:string">60k</cachedSi= ze> > <directoryCategory xsi:type=3D"ns1:DirectoryCateg= ory"> > <fullViewableName xsi:type=3D"xsd:string"></f= ullViewableName> > <specialEncoding xsi:type=3D"xsd:string"></sp= ecialEncoding> > </directoryCategory> > <directoryTitle xsi:type=3D"xsd:string"></directo= ryTitle> > <hostName xsi:type=3D"xsd:string">forums.devshed.= com</hostName> > <relatedInformationPresent xsi:type=3D"xsd:boolea= n">true</relatedInformationPresent> > <snippet xsi:type=3D"xsd:string"><b>...<= /b> if the variables are set as USER or SYSTEM <b>enviorenment<= /b> variables <b>...</b> Registry key<br> &#39;Sof= tware\JavaSoft\<b>Java</b> <b>Runtime</b> Environme= nt\CurrentVersion&#39; has value &#39;1.3&#39;, but <b>..= .</b> </snippet> > <summary xsi:type=3D"xsd:string"></summary> > <title xsi:type=3D"xsd:string">TextPad.. > > > http://www.vovida.or= g/pipermail/vocal/2002-November/007361.html > 9k > > > > > > > true > <b>...<= /b> Next message: [Vocal] <b>Java</b> Provisioning for Vocal= 1.4; Messages sorted by:<br> <b>...</b> the &gt; &l= t;b>java</b> run time <b>enviorenment</b> jre1.3.1_06 = before deploying &gt; vocal). <b>...</b> > > [Vocal] Problems d= eploying vocal 1.4.0 > > > http://www.vovida.or= g/pipermail/vocal/2002-November/007358.html > 9k > > > > > > www.vovida.org<= /hostName> > true > <b>...<= /b> (though I have installed the &gt; &gt; <b>java</b&g= t; run time <b>enviorenment</b> jre1.3.1_06 before<br> d= eploying <b>...</b> And there is no &gt; &gt; <b>= Java</b> <b>Runtime</b> in configurations. <b>...&l= t;/b> > > [Vocal] Problems d= eploying vocal 1.4.0 > > > http://www.javadeskt= op.org/forums/thread.jspa?threadID=3D8796&tstart=3D120 > 31k > > > > > > > true > <b>...<= /b> It works, but I got some <b>runtime</b> errors that I ca= n=C2=B4t fix. <b>...</b> installation app<br> to set up = all the server and client <b>enviorenment</b> will be very help= ful. <b>...</b> > > JavaDesktop Forums= > > > http://www.desktopia= n.org/news/onews0200.html > 198k > > > > > > > true > <b>...<= /b> Faster and smaller?516k. no <b>runtime</b>? b) New mail = engine. <b>...</b> C Headers,<br> includes, <b>JAV= A</b>, JavaScript, CSS and PHP/PHP3, x86 Assembly, HP48, CA-Clipper, = <b>...</b> > > desktopian.org : O= ld News > > > http://www.database-= forum.com/forum14.html > 62k > > > > > > > true > <b>...<= /b> No new posts, Static BerkeleyDB with Dynamic <b>Runtime</b&= gt; on Win32? <b>...</b> No new posts,<br> DB-&gt;as= sociate in multithreaded <b>enviorenment</b> <b>...</b= > > > Berkeley DB</title= > > </item> > <item xsi:type=3D"ns1:ResultElement"> > <URL xsi:type=3D"xsd:string">http://mail-archives= .apache.org/mod_mbox/jakarta-tomcat-user/200209.mbox/authors.html</URL> > <cachedSize xsi:type=3D"xsd:string">513k</cachedS= ize> > <directoryCategory xsi:type=3D"ns1:DirectoryCateg= ory"> > <fullViewableName xsi:type=3D"xsd:string"></f= ullViewableName> > <specialEncoding xsi:type=3D"xsd:string"></sp= ecialEncoding> > </directoryCategory> > <directoryTitle xsi:type=3D"xsd:string"></directo= ryTitle> > <hostName xsi:type=3D"xsd:string"></hostName> > <relatedInformationPresent xsi:type=3D"xsd:boolea= n">true</relatedInformationPresent> > <snippet xsi:type=3D"xsd:string"><b>...<= /b> how to prevent JSP getting compiled at <b>runtime</b> Ba= yi Peng (Thu, 19 Sep 2002<br> 18:06:02 <b>...</b> refern= cing <b>enviorenment</b> variable in server.xml Katz, Adi (Wed,= <b>...</b></snippet> > <summary xsi:type=3D"xsd:string"></summary> > <title xsi:type=3D"xsd:string">/mod_mbox/jakarta-= tomcat-user/200209.mbox/authors.html > > > > java runtime enviore= nment > 0.02838 > > 1 > > > > > this is part of the code in my ClientCallbackHandler that process the SOA= P envelope:- > private void extractDetails(AsyncResult result) { > Iterator iterator,iterator2; > OMNode node; > OMElement body, operation, elem; > SOAPEnvelope resEnvelope; > try { > XMLStreamWriter writer =3D XMLOutputFactory.newInstance().cre= ateXMLStreamWriter( > System.out); > result.getResponseEnvelope().serialize(writer); > //part.serialize(writer,false); > writer.flush(); > } catch (XMLStreamException e) { > System.out.println("Error occured after responce is received"= ); > e.printStackTrace(); > } catch (FactoryConfigurationError e) { > System.out.println("Error occured after responce is received"= ); > e.printStackTrace(); > } > resEnvelope =3D result.getResponseEnvelope(); > body =3D resEnvelope.getBody(); > operation =3D body.getFirstElement(); > String opLocalName =3D operation.getLocalName(); > if (opLocalName.equals("Fault")) { > System.out.println("A Fault message recieved, Check your Lice= nce key"); > snippet =3D > snippet + > "A Fault message recieved, Check your Licence key. El= se you have reached the" + > " daily limit of 1000 requests"; > } else { > OMElement part =3D operation.getFirstElement(); > iterator =3D part.getChildren(); > while (iterator.hasNext()) { > node =3D (OMNode) iterator.next(); > if (node.getType() =3D=3D OMNode.ELEMENT_NODE) { > elem =3D (OMElement) node; > String str =3D elem.getLocalName(); > System.out.println(str); > if (str.equals("resultElements")) { > System.out.println("Got the Result Elements"); > Iterator iterator0 =3D elem.getChildren(); > while (iterator0.hasNext()) { > node =3D (OMNode) iterator0.next(); > if (node.getType() =3D=3D OMNode.ELEMENT_NODE= ) { > elem =3D (OMElement) node; > if (elem.getLocalName().equals("item")) { > iterator2 =3D elem.getChildren(); > while (iterator2.hasNext()) { > node =3D (OMNode) iterator2.next(= ); > if (node.getType() =3D=3D OMNode.= ELEMENT_NODE) { > elem =3D (OMElement) node; > String str3 =3D elem.getLocal= Name(); > System.out.println(str3); > if (elem.getLocalName().equal= s("snippet")) { > System.out.println("Got t= he snippet"); > tempStr =3D elem.getText(= ); > System.out.println(tempSt= r); > snippet =3D snippet + tem= pStr; > } > if (elem.getLocalName().equal= s("URL")) { > System.out.println("Got t= he URL"); > strURL =3D elem.getText()= ; > } > } > } > } > snippet =3D snippet + "
URL:-" + strURL + > "

"; > } > } > } > } > } > } > snippet =3D snippet + endHTML; > System.out.println(snippet); > //text.setText(snippet); > GUIHandler.showResults(snippet); > } > Gayan --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira