You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Mark Gordon <fr...@markgordon.org> on 2007/06/07 23:50:03 UTC

Slow XML Parsing.

I am upgrading ofbiz framework from a version from about two years ago 
and xml parsing is about 25 times slower on my new install.

If I swap the xercesImpl.jar files the old release is still just as fast 
and the new is just as slow.

Is there some flag that is set that would slow down parsing?  Extra XML 
validation?
I set my test xml dtd to be local but no change.

All the time is spent where you would expect,
org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
Looping in the dispatch method.

Thanks in advance....  THIS IS DRIVING ME NUTS!

-mark

Re: Slow XML Parsing.

Posted by Jacopo Cappellato <ti...@sastau.it>.
Maybe a dns issue?

Jacopo


David E Jones wrote:
> 
> Has anyone else noticed anything like this? Without looking at a 
> specific environment where this is happening it is hard to comment on.
> 
> Do you have any other details you could share? Things like OS, Java, etc 
> versions, which XML file is being parsed, etc?
> 
> -David
> 
> 
> Mark Gordon wrote:
>> I am upgrading ofbiz framework from a version from about two years ago 
>> and xml parsing is about 25 times slower on my new install.
>>
>> If I swap the xercesImpl.jar files the old release is still just as 
>> fast and the new is just as slow.
>>
>> Is there some flag that is set that would slow down parsing?  Extra 
>> XML validation?
>> I set my test xml dtd to be local but no change.
>>
>> All the time is spent where you would expect,
>> org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
>> Looping in the dispatch method.
>>
>> Thanks in advance....  THIS IS DRIVING ME NUTS!
>>
>> -mark


Re: Slow XML Parsing.

Posted by Mark Gordon <fr...@markgordon.org>.
It appears to be part of the log4j.xml  I commented out the async 
appender and it was back to acceptable speed.

-Mark


Mark Gordon wrote:
>
> Here is some more information:
>
> http://docs.ofbiz.org/display/~mcg1103/Home
>
> I could not send the detail of my test case to the list so David 
> suggested a wiki page.
>
> If any ofbiz expert is interested in a bugger of a problem.
>
> Thanks
>
>
> Mark Gordon wrote:
>> Thanks for the reply David.  I have been out of town.
>>
>> The OS is Linux and java I have used both 1.5.0_11 and 1.6.0_01.
>>
>> Sometimes when I startup ofbiz, the startup will hang while parsing 
>> some larger XML documents causing the startup to be delayed by a few 
>> seconds.
>> Any large XML document takes much longer to parse.  The specific XML 
>> is a jasper report file unloaded to XML.  It does seem as though some 
>> network connection is slowing things down (as Jacopo suggested DNS).
>> It is a very odd issue.  I have been swapping out jar files trying to 
>> see what is causing the issue and the problem does not move around.  
>> I can't get the old version to go slow and I can't get the new 
>> version to go fast.  I also wrote a small command line program to 
>> just call the parsing routine and point to the libraries in both 
>> version and I can't get that to go slow.
>>
>> Any insights would be appreciated!
>>
>> -Mark
>>
>>
>> David E Jones wrote:
>>>
>>> Has anyone else noticed anything like this? Without looking at a 
>>> specific environment where this is happening it is hard to comment on.
>>>
>>> Do you have any other details you could share? Things like OS, Java, 
>>> etc versions, which XML file is being parsed, etc?
>>>
>>> -David
>>>
>>>
>>> Mark Gordon wrote:
>>>> I am upgrading ofbiz framework from a version from about two years 
>>>> ago and xml parsing is about 25 times slower on my new install.
>>>>
>>>> If I swap the xercesImpl.jar files the old release is still just as 
>>>> fast and the new is just as slow.
>>>>
>>>> Is there some flag that is set that would slow down parsing?  Extra 
>>>> XML validation?
>>>> I set my test xml dtd to be local but no change.
>>>>
>>>> All the time is spent where you would expect,
>>>> org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
>>>> Looping in the dispatch method.
>>>>
>>>> Thanks in advance....  THIS IS DRIVING ME NUTS!
>>>>
>>>> -mark


Re: Slow XML Parsing.

Posted by Mark Gordon <fr...@markgordon.org>.
Here is some more information:

http://docs.ofbiz.org/display/~mcg1103/Home

I could not send the detail of my test case to the list so David 
suggested a wiki page.

If any ofbiz expert is interested in a bugger of a problem.

Thanks


Mark Gordon wrote:
> Thanks for the reply David.  I have been out of town.
>
> The OS is Linux and java I have used both 1.5.0_11 and 1.6.0_01.
>
> Sometimes when I startup ofbiz, the startup will hang while parsing 
> some larger XML documents causing the startup to be delayed by a few 
> seconds.
> Any large XML document takes much longer to parse.  The specific XML 
> is a jasper report file unloaded to XML.  It does seem as though some 
> network connection is slowing things down (as Jacopo suggested DNS).
> It is a very odd issue.  I have been swapping out jar files trying to 
> see what is causing the issue and the problem does not move around.  I 
> can't get the old version to go slow and I can't get the new version 
> to go fast.  I also wrote a small command line program to just call 
> the parsing routine and point to the libraries in both version and I 
> can't get that to go slow.
>
> Any insights would be appreciated!
>
> -Mark
>
>
> David E Jones wrote:
>>
>> Has anyone else noticed anything like this? Without looking at a 
>> specific environment where this is happening it is hard to comment on.
>>
>> Do you have any other details you could share? Things like OS, Java, 
>> etc versions, which XML file is being parsed, etc?
>>
>> -David
>>
>>
>> Mark Gordon wrote:
>>> I am upgrading ofbiz framework from a version from about two years 
>>> ago and xml parsing is about 25 times slower on my new install.
>>>
>>> If I swap the xercesImpl.jar files the old release is still just as 
>>> fast and the new is just as slow.
>>>
>>> Is there some flag that is set that would slow down parsing?  Extra 
>>> XML validation?
>>> I set my test xml dtd to be local but no change.
>>>
>>> All the time is spent where you would expect,
>>> org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
>>> Looping in the dispatch method.
>>>
>>> Thanks in advance....  THIS IS DRIVING ME NUTS!
>>>
>>> -mark


Re: Slow XML Parsing.

Posted by Mark Gordon <fr...@markgordon.org>.
Thanks for the reply David.  I have been out of town.

The OS is Linux and java I have used both 1.5.0_11 and 1.6.0_01.

Sometimes when I startup ofbiz, the startup will hang while parsing some 
larger XML documents causing the startup to be delayed by a few seconds. 

Any large XML document takes much longer to parse.  The specific XML is 
a jasper report file unloaded to XML.  It does seem as though some 
network connection is slowing things down (as Jacopo suggested DNS). 

It is a very odd issue.  I have been swapping out jar files trying to 
see what is causing the issue and the problem does not move around.  I 
can't get the old version to go slow and I can't get the new version to 
go fast.  I also wrote a small command line program to just call the 
parsing routine and point to the libraries in both version and I can't 
get that to go slow.

Any insights would be appreciated!

-Mark


David E Jones wrote:
>
> Has anyone else noticed anything like this? Without looking at a 
> specific environment where this is happening it is hard to comment on.
>
> Do you have any other details you could share? Things like OS, Java, 
> etc versions, which XML file is being parsed, etc?
>
> -David
>
>
> Mark Gordon wrote:
>> I am upgrading ofbiz framework from a version from about two years 
>> ago and xml parsing is about 25 times slower on my new install.
>>
>> If I swap the xercesImpl.jar files the old release is still just as 
>> fast and the new is just as slow.
>>
>> Is there some flag that is set that would slow down parsing?  Extra 
>> XML validation?
>> I set my test xml dtd to be local but no change.
>>
>> All the time is spent where you would expect,
>> org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
>> Looping in the dispatch method.
>>
>> Thanks in advance....  THIS IS DRIVING ME NUTS!
>>
>> -mark


Re: Slow XML Parsing.

Posted by David E Jones <jo...@hotwaxmedia.com>.
Has anyone else noticed anything like this? Without looking at a specific environment where this is happening it is hard to comment on.

Do you have any other details you could share? Things like OS, Java, etc versions, which XML file is being parsed, etc?

-David


Mark Gordon wrote:
> I am upgrading ofbiz framework from a version from about two years ago 
> and xml parsing is about 25 times slower on my new install.
> 
> If I swap the xercesImpl.jar files the old release is still just as fast 
> and the new is just as slow.
> 
> Is there some flag that is set that would slow down parsing?  Extra XML 
> validation?
> I set my test xml dtd to be local but no change.
> 
> All the time is spent where you would expect,
> org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher
> Looping in the dispatch method.
> 
> Thanks in advance....  THIS IS DRIVING ME NUTS!
> 
> -mark