You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by Guillaume Nodet <gn...@gmail.com> on 2010/02/19 15:56:54 UTC

[Heads up][OBR] Stax based parser

I've just committed a new stax based parser into the OBR service.  It
will be used automatically if possible (meaning if the
javax.xml.stream package is available) else the default one will be
used.  I've seen a parsing time divided by 10 on my computer.  To test
it a bit, you can uncomment the StaxParserTest#testPerfs method and
run it from maven using
     mvn test -Dtest=StaxParserTest
It will run a loop and parse your ~/.m2/repository/repository.xml file.

The results on my computer are the following:

Running org.apache.felix.bundlerepository.StaxParserTest
Woodstox: 5924 ms
DefStax: 7154 ms
KXmlParser: 55368 ms
Woodstox: 4583 ms
DefStax: 5374 ms
KXmlParser: 51820 ms
...

The first run of test is longer because you need to let the JIT warm up.
But this shows that when using the default stax parser (from the JRE),
the parsing time is down to 10.3 % and  down to 8.9 % when using
Woodstox !

The parsing is entirely new, so please take some time to test it with
your real use cases and make sure i haven't forgotten anything in the
parser.

-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com

Re: [Heads up][OBR] Stax based parser

Posted by Guillaume Nodet <gn...@gmail.com>.
I've done further optimizations on OBR and the repository parsing has
been further improved  (490 ms instead of 33.6 s for a xml of 7.8 Mo).
The resolution has also been improved a lot too.

On Fri, Feb 19, 2010 at 15:56, Guillaume Nodet <gn...@gmail.com> wrote:
> I've just committed a new stax based parser into the OBR service.  It
> will be used automatically if possible (meaning if the
> javax.xml.stream package is available) else the default one will be
> used.  I've seen a parsing time divided by 10 on my computer.  To test
> it a bit, you can uncomment the StaxParserTest#testPerfs method and
> run it from maven using
>     mvn test -Dtest=StaxParserTest
> It will run a loop and parse your ~/.m2/repository/repository.xml file.
>
> The results on my computer are the following:
>
> Running org.apache.felix.bundlerepository.StaxParserTest
> Woodstox: 5924 ms
> DefStax: 7154 ms
> KXmlParser: 55368 ms
> Woodstox: 4583 ms
> DefStax: 5374 ms
> KXmlParser: 51820 ms
> ...
>
> The first run of test is longer because you need to let the JIT warm up.
> But this shows that when using the default stax parser (from the JRE),
> the parsing time is down to 10.3 % and  down to 8.9 % when using
> Woodstox !
>
> The parsing is entirely new, so please take some time to test it with
> your real use cases and make sure i haven't forgotten anything in the
> parser.
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com

Re: [Heads up][OBR] Stax based parser

Posted by Guillaume Nodet <gn...@gmail.com>.
Soon hopefully, but I'm sure there'll be more fixes / enhancements
coming in the next days.  And I'd like a bit of feedback in case I've
introduced some problems with this new parser.

On Fri, Feb 19, 2010 at 16:33, Alasdair Nottingham <no...@apache.org> wrote:
> Looks very interesting, any idea when it'll be in a release :)
>
> Alasdair
>
> On 19 February 2010 15:08, Guillaume Nodet <gn...@gmail.com> wrote:
>> Forwarding here as it may interesting for you.
>>
>>
>> ---------- Forwarded message ----------
>> From: Guillaume Nodet <gn...@gmail.com>
>> Date: Fri, Feb 19, 2010 at 15:56
>> Subject: [Heads up][OBR] Stax based parser
>> To: dev <de...@felix.apache.org>
>>
>>
>> I've just committed a new stax based parser into the OBR service.  It
>> will be used automatically if possible (meaning if the
>> javax.xml.stream package is available) else the default one will be
>> used.  I've seen a parsing time divided by 10 on my computer.  To test
>> it a bit, you can uncomment the StaxParserTest#testPerfs method and
>> run it from maven using
>>     mvn test -Dtest=StaxParserTest
>> It will run a loop and parse your ~/.m2/repository/repository.xml file.
>>
>> The results on my computer are the following:
>>
>> Running org.apache.felix.bundlerepository.StaxParserTest
>> Woodstox: 5924 ms
>> DefStax: 7154 ms
>> KXmlParser: 55368 ms
>> Woodstox: 4583 ms
>> DefStax: 5374 ms
>> KXmlParser: 51820 ms
>> ...
>>
>> The first run of test is longer because you need to let the JIT warm up.
>> But this shows that when using the default stax parser (from the JRE),
>> the parsing time is down to 10.3 % and  down to 8.9 % when using
>> Woodstox !
>>
>> The parsing is entirely new, so please take some time to test it with
>> your real use cases and make sure i haven't forgotten anything in the
>> parser.
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>> ------------------------
>> Open Source SOA
>> http://fusesource.com
>>
>>
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>> ------------------------
>> Open Source SOA
>> http://fusesource.com
>>
>
>
>
> --
> Alasdair Nottingham
> not@apache.org
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com

Re: [Heads up][OBR] Stax based parser

Posted by Alasdair Nottingham <no...@apache.org>.
Looks very interesting, any idea when it'll be in a release :)

Alasdair

On 19 February 2010 15:08, Guillaume Nodet <gn...@gmail.com> wrote:
> Forwarding here as it may interesting for you.
>
>
> ---------- Forwarded message ----------
> From: Guillaume Nodet <gn...@gmail.com>
> Date: Fri, Feb 19, 2010 at 15:56
> Subject: [Heads up][OBR] Stax based parser
> To: dev <de...@felix.apache.org>
>
>
> I've just committed a new stax based parser into the OBR service.  It
> will be used automatically if possible (meaning if the
> javax.xml.stream package is available) else the default one will be
> used.  I've seen a parsing time divided by 10 on my computer.  To test
> it a bit, you can uncomment the StaxParserTest#testPerfs method and
> run it from maven using
>     mvn test -Dtest=StaxParserTest
> It will run a loop and parse your ~/.m2/repository/repository.xml file.
>
> The results on my computer are the following:
>
> Running org.apache.felix.bundlerepository.StaxParserTest
> Woodstox: 5924 ms
> DefStax: 7154 ms
> KXmlParser: 55368 ms
> Woodstox: 4583 ms
> DefStax: 5374 ms
> KXmlParser: 51820 ms
> ...
>
> The first run of test is longer because you need to let the JIT warm up.
> But this shows that when using the default stax parser (from the JRE),
> the parsing time is down to 10.3 % and  down to 8.9 % when using
> Woodstox !
>
> The parsing is entirely new, so please take some time to test it with
> your real use cases and make sure i haven't forgotten anything in the
> parser.
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com
>
>
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com
>



-- 
Alasdair Nottingham
not@apache.org

Fwd: [Heads up][OBR] Stax based parser

Posted by Guillaume Nodet <gn...@gmail.com>.
Forwarding here as it may interesting for you.


---------- Forwarded message ----------
From: Guillaume Nodet <gn...@gmail.com>
Date: Fri, Feb 19, 2010 at 15:56
Subject: [Heads up][OBR] Stax based parser
To: dev <de...@felix.apache.org>


I've just committed a new stax based parser into the OBR service.  It
will be used automatically if possible (meaning if the
javax.xml.stream package is available) else the default one will be
used.  I've seen a parsing time divided by 10 on my computer.  To test
it a bit, you can uncomment the StaxParserTest#testPerfs method and
run it from maven using
    mvn test -Dtest=StaxParserTest
It will run a loop and parse your ~/.m2/repository/repository.xml file.

The results on my computer are the following:

Running org.apache.felix.bundlerepository.StaxParserTest
Woodstox: 5924 ms
DefStax: 7154 ms
KXmlParser: 55368 ms
Woodstox: 4583 ms
DefStax: 5374 ms
KXmlParser: 51820 ms
...

The first run of test is longer because you need to let the JIT warm up.
But this shows that when using the default stax parser (from the JRE),
the parsing time is down to 10.3 % and  down to 8.9 % when using
Woodstox !

The parsing is entirely new, so please take some time to test it with
your real use cases and make sure i haven't forgotten anything in the
parser.

--
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com