I took a look at the test code. The problem is at,

OMElement element = new StAXOMBuilder(inputFile).getDocumentElement();

The OMElement you receive at this point doesn't fire the start document event 
but interestingly fires the end document event. So the workaround manually 
call start document before serializing.

Interestingly, when you get the SOAP envelop, that fires start document event 
but does not fire the end document event. If you look at the message 
formatter you will see that I have done a workaround for that.

Thanks
Sanjaya

On Friday 11 May 2007 10:56, Thilina Gunarathne wrote:
> Hi,
> I can remember Sanjaya was dealing with a issue like that... AFAIC
> remember the NP was due to not setting a thing called vocabulary to
> the FastInforset parser.. The FI parser expects a startDocument event
> or something similar which instantiates that vocabulary and our Axiom
> is not throwing that event...  Sanjaya is the best person to answer
> how he overcome that...
>
> Thanks,
> Thilina
>
> On 5/11/07, Eran Chinthaka <[EMAIL PROTECTED]> wrote:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > Hi,
> >
> > I wanted to test the interoperability of fastinfoset with Axiom and
> > wstx. So I wrote and committed a small test case in to
> > org.apache.axis2.fastinfoset.FastInfosetInputOutputTest.
> > It reads an xml file into Axiom using wstx, serializes in to a binary
> > file using FI, reads the serialized file using FI in to Axiom, serialize
> > Axiom in to a file using wstx. The test simply compares input and output
> > XML files. When I did that I encountered an NPE from FI code. I did the
> > same thing some time back and found this error. But since FI seems to be
> > integrated in to Axis2, I did the same thing and the problem seems to be
> > still there.
> >
> > I opened an issue in JIRA [1] for this.
> >
> > This is somewhat related to Axiom also, so cc'ed to commons-dev list as
> > well.
> >
> > Thanks,
> > Chinthaka
> >
> > https://issues.apache.org/jira/browse/AXIS2-2653
> > -----BEGIN PGP SIGNATURE-----
> > Version: GnuPG v1.4.3 (GNU/Linux)
> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
> >
> > iD8DBQFGQ/LSjON2uBzUhh8RAjW1AJ9nDKNvPj5A5rXEi4W3u8QddeaV7QCfTVKf
> > jeiwvwX6jqv6UfEgxok8iU8=
> > =wrSZ
> > -----END PGP SIGNATURE-----
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]

-- 
Senior Software Architect
WSO2 Inc. www.wso2.com
"Oxygenating the Web Service Platform."
==================================================
“Opportunity is missed by most people because it is dressed in overalls and 
looks like work.”
- Thomas Edison

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to