Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 21185 invoked from network); 21 Mar 2005 18:30:55 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 21 Mar 2005 18:30:55 -0000 Received: (qmail 3008 invoked by uid 500); 21 Mar 2005 18:30:53 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 2975 invoked by uid 500); 21 Mar 2005 18:30:53 -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: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 2957 invoked by uid 99); 21 Mar 2005 18:30:52 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from ajax-1.apache.org (HELO ajax.apache.org) (192.87.106.226) by apache.org (qpsmtpd/0.28) with ESMTP; Mon, 21 Mar 2005 10:30:52 -0800 Received: from ajax.apache.org (ajax.apache.org [127.0.0.1]) by ajax.apache.org (8.12.11/8.12.11) with ESMTP id j2LIUmPv017956 for ; Mon, 21 Mar 2005 19:30:48 +0100 Message-ID: <11312465.1111429848654.JavaMail.jira@ajax.apache.org> Date: Mon, 21 Mar 2005 19:30:48 +0100 (CET) From: "Florin Cremenescu (JIRA)" To: axis-dev@ws.apache.org Subject: [jira] Created: (AXIS-1894) Problems using axis 1.1 and 1.2 with attachments Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Problems using axis 1.1 and 1.2 with attachments ------------------------------------------------ Key: AXIS-1894 URL: http://issues.apache.org/jira/browse/AXIS-1894 Project: Axis Type: Bug Versions: 1.1, 1.2RC2 =20 Environment: Java Reporter: Florin Cremenescu Hello,=20 =20 I am trying to use Axis as a client for a web service with attachments. I h= ave several problems, but I'm not sure that they are due to axis bugs, so I= ask you for advice.=20 Skim of the wsdl service description :=20 The service returns general information in a classic SOAP message plus an a= ttached document. The attached document is referenced from the general info= rmation by the REP field (the entire wsdl can be found at the end of the me= ssage).=20 The output message has the form :=20 =09 =09 The binding has the form :=20 =09 =09=09 =09=09=09 =09=09 =09=09 =09=09=09 =09=09 =09 Somewhere in the REP_PROTECTEL_IBDF element there is an element REP contain= ing :=20 =09 =09 This element points to the attached document.=20 Questions : do you see something unusual with this specification ? Are ther= e any reasons to encounter problems with wsdl2java and axis ? Does wsdl2jav= a take into account attachments ?=20 First problem : Null pointer exception with axis 1.1, but ok with axis 1.2= RC2 =09We have succeeded to call the service and get the attachment using axis = 1.2RC2 but not with axis 1.1. In axis 1.1 we get the following NullPointerE= xception :=20 java.lang.NullPointerException =09at java.io.FilterInputStream.available(FilterInputStream.java:146) =09at org.apache.xerces.impl.XMLEntityManager$RewindableInputStream.availab= le(XMLEntityManager.java:2644) =09at sun.nio.cs.StreamDecoder$CharsetSD.inReady(StreamDecoder.java:487) =09at sun.nio.cs.StreamDecoder$CharsetSD.implRead(StreamDecoder.java:448) =09at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:182) =09at java.io.InputStreamReader.read(InputStreamReader.java:167) =09at org.apache.xerces.impl.XMLEntityScanner.load(XMLEntityScanner.java:17= 40) =09at org.apache.xerces.impl.XMLEntityScanner.skipSpaces(XMLEntityScanner.j= ava:1259) =09at org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispat= ch(XMLDocumentScannerImpl.java:756) =09at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM= LDocumentFragmentScannerImpl.java:338) =09at org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration= .java:828) =09at org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration= .java:758) =09at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148) =09at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j= ava:1178) =09at javax.xml.parsers.SAXParser.parse(SAXParser.java:345) =09at org.apache.axis.encoding.DeserializationContextImpl.parse(Deserializa= tionContextImpl.java:242) =09at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:538) =09at org.apache.axis.Message.getSOAPEnvelope(Message.java:376) =09at org.apache.axis.client.Call.invokeEngine(Call.java:2583) =09at org.apache.axis.client.Call.invoke(Call.java:2553) =09at org.apache.axis.client.Call.invoke(Call.java:2248) =09at org.apache.axis.client.Call.invoke(Call.java:2171) =09at org.apache.axis.client.Call.invoke(Call.java:1691) =09Analyzing this problem we have found that the MultiPartRelatedInputStrea= m in 1.2 has its definition of the method available() :=20 public int available() throws java.io.IOException { return (closed || eos) ? 0 : soapStream.available(); } =09This does not exist in axis 1.1 so the super method is used. But the sup= er class is initialized with a super(null) in the constructor, so NullPoint= erException.=20 =09 =09Questions : Is it normal that the attachment part does not fonction corr= ectly in 1.1 or am I doing something wrong ? Are there other people using a= ttachments with axis ? I would like to use axis 1.1, what possibilities I h= ave to correct the problem (beyond patching axis) ? Is axis 1.2 RC 2-3 stab= le enough to use it in a production mode ? Do you know the release date of = axis 1.2 ?=20 =09 Second problem : Wsdl2java generator It seems to me that the WSDL2Java generator does not treat the attachment= s. The generated code of the REP class no place attribute to put the attach= ment. Is this a bug or the declaration of the REP element is wrong ?=20 Also, the deserializer used for the REP object is generated as the BeanDes= erializer (so I get a class cast exception when axis tries to put the Attac= hmentPart object in the object containing REP). I wrote a new deserializer = which gets the content of the AttachmentPart and creates a REP object with = this content. What bothers me is the fact that I modified the generated cod= e (class REP_Helper). Is there a possibility to avoid this (maybe rewrite t= he wsdl such that wsdl2java can take into account the attachment) ?=20 Thank you for your answers.=20 Here is the entire wsdl :=20 =09 =09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Service Banque de France interrog=E9 =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Num=E9ro du Module FIBEN, Type de Relev= =E9 FCC ou FICP =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09R=E9ferences du dossier =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Utilisateur de la passerelle PROTECTEL-iB= DF =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Donn=E9es attach=E9es =E0 l'utilisateur =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Code de l'=E9tablissement sp=E9cifi=E9 po= ur l'acc=E8s POBI =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Code agence sp=E9cifi=E9 pour l'acc=E8s P= OBI =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Priorit=E9 de la requ=EAte =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Forcer ou non une interrogation alors que= la r=E9ponse existe en cache =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09"BDF" =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09"1" =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Identifiant de la r=E9ponse enregistr=E9e= dans la base de PROTECTEl-iBDF =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Sous-Identifiant de la r=E9ponse enregist= r=E9e dans la base de PROTECTEl-iBDF =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Etat dans lequel se trouve la requ=EAte d= ans la base de PROTECTEL-iBDF =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Validit=E9 de la r=E9ponse =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Longueur de la r=E9ponse "brute" de la Ba= nque de France =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Date de soumission de la requ=EAte =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Heure de soumission de la requ=EAte =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Date de reception de la requ=EAte =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Heure de reception de la requ=EAte =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09"Fraicheur" de la r=E9ponse =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Code erreur propre =E0 PROTECTEL-iBDF =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09 =09=09 =09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Elements sp=E9cifique au type de service = interrog=E9 =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Cleanque de France ou Num=E9ro SIRE= N =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Module FIBEN 07 : Nom recherch=E9 <= /xsd:documentation> =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Module FIBEN 07 : Type de nom =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Module FIBEN 07 : Indicateur de rec= herche =E9tendue (O ou N). =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Module FIBEN 07 : code APE =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur le code post= al. =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Elements sp=E9cifique au type de service = interrog=E9 et permettant d'effectuer un filtre sur la r=E9ponse =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur le nom de fa= mille =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur la date de n= aissance =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur le pr=E9nom<= /xsd:documentation> =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur le sexe =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur la ville =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09Filtre FCC ou FICP sur le code post= al. =09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09=09=09 =09=09=09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Regroupement des informations sur la requ= =EAte =E9mise =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Regroupement des informations sur la r=E9= ponse =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Regroupement des informations sur la requ= =EAte =E0 emettre =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09Regroupement des informations sur la r=E9= ponse, et requ=EAte =E9mise. =09=09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09 =09 =09 =09=09 =09=09 =09 =09 =09=09 =09 =09 =09=09 =09=09=09 =09=09=09 =09=09 =09 =09 =09=09 =09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09 =09=09=09 =09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09 =09=09=09=09=09=09 =09=09=09=09=09 =09=09=09=09 =09=09=09 =09=09 =09 =09 =09=09 =09=09=09 =09=09 =09 --=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 - If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira