> Hello folks,
>
> Unfortunately Im experiencing performance problems by transoforiming big
xml
> files (>1MB). Right now the configuration I have is Xalan-C1.4/Xerces 2.1
> AND by transoforming the xml files I dont use the xerces apis. The bigger
> the xml file the slower it gets (exponentially).

This can happen for multiple reasons.  For example, you may have some
construct in your stylesheet which does not scale well.

> It happend to use XML SPY 4.4/ MSXML 4.0 and noticed that transoforming
> takes less (~2 times) (probably because the characters method of
> FormatterListener is rewritten (I cannt do any profiling to compare the
old
> with the new charachters() - any help?)).

I don't understand what you mean by "(probably because the characters
method of FormatterListener is rewritten (I cannt do any profiling to
compare the old with the new charachters() - any help?))."  Can you explain
in more detail what you think was rewritten?  FormatterListener does not
have an implementation of the characters() member function.  What were you
profiling before that you are unable to profile now?

> What I do?
>
> After compiling the Stylesheets
> int
>            compileStylesheet(
>                                    const XSLTInputSource&
> theStylesheetSource,
>                                    const XalanCompiledStylesheet*&
> theCompiledStylesheet);
>
> and build an xml file(using the XalanSourceTreeContentHandler)...

Are you using XalanTransformer::parseSource() to parse and XML stream to
build the tree?

>
> the XalanTransformer.compileStylesheet(...) is called (with its own
> FormatterListener.charachters() ).

I don't understand what you mean by this.  There is no parameter that is in
any way related to FormatterListener when compiling a stylesheet.

> Can anyone suggests what the reasons for this performance burst could be?

Do you mean degradation?  There could be any number of reasons why you are
seeing a performance degradation as the size of the input document grows.
As I stated before, there could be a construct in your stylesheet which
does not scale well, or Xalan does not handle well.  There could be issues
with memory usage as the size of the document grows.

> P.S. It might be that the information given is not enough but I want to
open
> a discussion in that case for what to do and what is reasonable by
dealing
> with transforming of big xml files.

It's definitely not enough information.  At the very least, a sample
stylesheet and a sample input document are necessary to really diagnose a
problem.  The input document does not need to be large, but the stylesheet
should be the exact stylesheet you're using.

Dave

Reply via email to