You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Dennis Sosnoski <dm...@sosnoski.com> on 2007/09/27 07:14:26 UTC

[Axis2] Enabling Fast Infoset

I wanted to do some performance tests with Fast Infoset, but can't find 
anything about how to use this feature. There should probably be 
something added to the documentation, since this was one of the new 
features listed for the 1.3 release.

Anyone know how to turn this on?

  - Dennis

-- 
Dennis M. Sosnoski
SOA and Web Services in Java
Axis2 Training and Consulting
http://www.sosnoski.com - http://www.sosnoski.co.nz
Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Srinath Perera <he...@gmail.com>.
My gut feeling says binary XML must be faster, as Eran said both
parsing and writing should be faster. (otherwise all those people
justifying binary protocols are in serious trouble ).

One simple test  is to do a performance evaluation of XML reading and
writing using fast infoset and a conventional xml parser. I believe
there is a OM perf test case , we should be able to switch to fast
infoset stax implementation and run that test case to compare the
results. However another possibility is for smaller documents SOAP
container overhead take over and no real difference can be seen.

Thanks
Srinath



On 9/29/07, Eran Chinthaka <ch...@opensource.lk> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Sanjaya Karunasena wrote:
> >
> > The advantage it should have over gzip is the fact that FI parsers read/write
> > the XML in its binary format.
>
> Fast infoset has only two advantages, IIUC. It must have better
> performance it terms of reading and writing and also it should be
> smaller in size to the XML the that it represents.
>
> Even though gzip compresses data, what it gives to the application is an
> XML. There won't be an advantage over gzip in-terms of compression when
> we use binary xml, but binary xml should perform better when it is
> serializing and de-serializing. Being them in binary format has no
> advantage except some one being not able to see them in a text editor.
>
> If what Dennis claims is true (binary xml is slow in Axis2) in his
> earlier mail, then we have a serious problem of using fast infoset.
> Either our implementation is not correct (I don't think so) or fast
> infoset readers and writers are slow.
>
> Thanks,
> Eran Chinthaka
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFG/vExjON2uBzUhh8RAhhkAKCS7ton+Z7JQGJ3XXS1hQLH93flpgCgsEes
> bbhuMCW6KRHM/YdXYLwjyog=
> =inc8
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>


-- 
============================
Srinath Perera:
   Indiana University, Bloomington
   http://www.cs.indiana.edu/~hperera/
   http://www.bloglines.com/blog/hemapani

Beauty of style and harmony and grace and good rhythm depend on
simplicity -- Plato

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Thilina Gunarathne <cs...@gmail.com>.
Hi,
> Fast infoset has only two advantages, IIUC. It must have better
> performance it terms of reading and writing and also it should be
> smaller in size to the XML the that it represents.
Well.. Depending on the performance of the FI encoder & decoder it
might even be slow in terms of reading and writing...

> Even though gzip compresses data, what it gives to the application is an
> XML. There won't be an advantage over gzip in-terms of compression when
> we use binary xml,
I don't understand why... There will be an advantage if the
compression is better than the encoding of FI..  Resulting message
size can be smaller depending on the content.. (I'm not a expert in
compression, but this is how I feel).

In the real transmissions over the net, message size can become the
crucial factor for speed.

>but binary xml should perform better when it is
> serializing and de-serializing. Being them in binary format has no
> advantage except some one being not able to see them in a text editor.
IMHO it has an advantage.. AFAIK FI puts it's indexes using integers,
which can be represented much efficiently using a binary format than
using a text format..

IMHO eventhough it's less efficient than GZIP it will still be
valuable, in order to support transports which do not support GZIP..

thanks,
Thlina
>
> If what Dennis claims is true (binary xml is slow in Axis2) in his
> earlier mail, then we have a serious problem of using fast infoset.
> Either our implementation is not correct (I don't think so) or fast
> infoset readers and writers are slow.
>
> Thanks,
> Eran Chinthaka
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFG/vExjON2uBzUhh8RAhhkAKCS7ton+Z7JQGJ3XXS1hQLH93flpgCgsEes
> bbhuMCW6KRHM/YdXYLwjyog=
> =inc8
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>


-- 
Thilina Gunarathne  - http://thilinag.blogspot.com

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Eran Chinthaka <ch...@opensource.lk>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Sanjaya Karunasena wrote:
> 
> The advantage it should have over gzip is the fact that FI parsers read/write 
> the XML in its binary format.

Fast infoset has only two advantages, IIUC. It must have better
performance it terms of reading and writing and also it should be
smaller in size to the XML the that it represents.

Even though gzip compresses data, what it gives to the application is an
XML. There won't be an advantage over gzip in-terms of compression when
we use binary xml, but binary xml should perform better when it is
serializing and de-serializing. Being them in binary format has no
advantage except some one being not able to see them in a text editor.

If what Dennis claims is true (binary xml is slow in Axis2) in his
earlier mail, then we have a serious problem of using fast infoset.
Either our implementation is not correct (I don't think so) or fast
infoset readers and writers are slow.

Thanks,
Eran Chinthaka
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFG/vExjON2uBzUhh8RAhhkAKCS7ton+Z7JQGJ3XXS1hQLH93flpgCgsEes
bbhuMCW6KRHM/YdXYLwjyog=
=inc8
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Saturday 29 September 2007, Dennis Sosnoski wrote:
> Sanjaya Karunasena wrote:
> > On Friday 28 September 2007, Dennis Sosnoski wrote:
> >> From my testing so far, it
> >> looks like "Fast Infoset" actually runs a little /*slower*/ than text
> >> XML when client and server are on the same system.
> >
> > Well, the advantage here is the size of the message. That of course when
> > you go over the wire + for large messages. I didn't got a chance to
> > evaluate and see what that threshold since I got busy with some client
> > engagements.
>
> For message size gzip is going to do a much better job than "Fast
> Infoset", but I'll checkout the performance across a network with both
> FI and gzip to see how they compare.
>
>   - Dennis
>

The advantage it should have over gzip is the fact that FI parsers read/write 
the XML in its binary format. But I am still stating theory here :-). Your 
test will tell us the reality.

/Sanjaya

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Dennis Sosnoski <dm...@sosnoski.com>.
Sanjaya Karunasena wrote:
> On Friday 28 September 2007, Dennis Sosnoski wrote:
>   
>> From my testing so far, it
>> looks like "Fast Infoset" actually runs a little /*slower*/ than text
>> XML when client and server are on the same system.
>>     
>
> Well, the advantage here is the size of the message. That of course when you 
> go over the wire + for large messages. I didn't got a chance to evaluate and 
> see what that threshold since I got busy with some client engagements.
>   

For message size gzip is going to do a much better job than "Fast 
Infoset", but I'll checkout the performance across a network with both 
FI and gzip to see how they compare.

  - Dennis


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Friday 28 September 2007, Dennis Sosnoski wrote:
> Thanks for the info, Sanjaya.
>
> Did you run any performance tests with this? From my testing so far, it
> looks like "Fast Infoset" actually runs a little /*slower*/ than text
> XML when client and server are on the same system. That's not exactly an
> impressive result. :-)
>
>   - Dennis

Well, the advantage here is the size of the message. That of course when you 
go over the wire + for large messages. I didn't got a chance to evaluate and 
see what that threshold since I got busy with some client engagements.

May be you can enlighten us with your findings and that will lead us to 
research any required improvements.

Thanks
Sanjaya

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Dennis Sosnoski <dm...@sosnoski.com>.
Thanks for the info, Sanjaya.

Did you run any performance tests with this? From my testing so far, it 
looks like "Fast Infoset" actually runs a little /*slower*/ than text 
XML when client and server are on the same system. That's not exactly an 
impressive result. :-)

  - Dennis

-- 
Dennis M. Sosnoski
SOA and Web Services in Java
Axis2 Training and Consulting
http://www.sosnoski.com - http://www.sosnoski.co.nz
Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117



Sanjaya Karunasena wrote:
> On Thursday 27 September 2007, Dennis Sosnoski wrote:
>   
>> I wanted to do some performance tests with Fast Infoset, but can't find
>> anything about how to use this feature. There should probably be
>> something added to the documentation, since this was one of the new
>> features listed for the 1.3 release.
>>
>> Anyone know how to turn this on?
>>
>>   - Dennis
>>     
>
> In the "axis2.xml" under the section "messageFormatters" add the following 
> Message Formatter.
>
> <!-- POX Message Formatter -->
> <messageFormatter contentType="application/fastinfoset" 
> class="org.apache.axis2.fastinfoset.FastInfosetPOXMessageFormatter"/>
>
> <!-- SOAP Message Formatter -->
> <messageFormatter contentType="application/soap+fastinfoset" 
> class="org.apache.axis2.fastinfoset.FastInfosetMessageFormatter"/>
>
> Under the section "messageBuilders" add the following Message Builder.
>
> <!-- POX Message Builder -->
> <messageBuilder contentType="application/fastinfoset" 
> class="org.apache.axis2.fastinfoset.FastInfosetPOXBuilder"/>
>
> <!-- SOAP Message Builder -->
> <messageBuilder contentType="application/soap+fastinfoset" 
> class="org.apache.axis2.fastinfoset.FastInfosetBuilder"/>
>
> If you want to use SOAP set the content type of the message 
> to "application/soap+fastinfoset" and if you want to use POX set the content 
> type to of the message to "application/fastinfoset".
>
> Thanks
> Sanjaya
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] Enabling Fast Infoset

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Thursday 27 September 2007, Dennis Sosnoski wrote:
> I wanted to do some performance tests with Fast Infoset, but can't find
> anything about how to use this feature. There should probably be
> something added to the documentation, since this was one of the new
> features listed for the 1.3 release.
>
> Anyone know how to turn this on?
>
>   - Dennis

In the "axis2.xml" under the section "messageFormatters" add the following 
Message Formatter.

<!-- POX Message Formatter -->
<messageFormatter contentType="application/fastinfoset" 
class="org.apache.axis2.fastinfoset.FastInfosetPOXMessageFormatter"/>

<!-- SOAP Message Formatter -->
<messageFormatter contentType="application/soap+fastinfoset" 
class="org.apache.axis2.fastinfoset.FastInfosetMessageFormatter"/>

Under the section "messageBuilders" add the following Message Builder.

<!-- POX Message Builder -->
<messageBuilder contentType="application/fastinfoset" 
class="org.apache.axis2.fastinfoset.FastInfosetPOXBuilder"/>

<!-- SOAP Message Builder -->
<messageBuilder contentType="application/soap+fastinfoset" 
class="org.apache.axis2.fastinfoset.FastInfosetBuilder"/>

If you want to use SOAP set the content type of the message 
to "application/soap+fastinfoset" and if you want to use POX set the content 
type to of the message to "application/fastinfoset".

Thanks
Sanjaya

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org