You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by goat <go...@gmail.com> on 2012/03/27 04:28:36 UTC
dynamically loading the stylesheet has bad performance
hi,
I use SAXON as following for dynamically loading the stylesheet
according to PropertyExpression:
Case1:
<saxon:xslt service="test:xslt-dynamic" endpoint="endpoint">
<saxon:expression>
<bean class="org.apache.servicemix.expression.PropertyExpression">
<property name="property" value="xslt.source" />
</bean>
</saxon:expression>
</saxon:xslt>
It was found that the performance was very bad while big load on it.
But when I replace it with statically loading as following:
Case2:
<saxon:xslt service="test:xslt" endpoint="endpoint"
resource="classpath:transform.xsl" />
It was found that the performance is improved dramaticlly!
It seems that SAXON load stylesheet everytime even if the xsl is same
in Case1.
Could anyone help me explain this?
Thanks!
--
View this message in context: http://servicemix.396122.n5.nabble.com/dynamically-loading-the-stylesheet-has-bad-performance-tp5596806p5596806.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.
Re: dynamically loading the stylesheet has bad performance
Posted by "ajs6f@virginia.edu" <aj...@virginia.edu>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm not sure that the Saxon component even supports that functionality. I understand it as a more-or-less stateless engine, but perhaps one of the ServiceMix developers can speak to that.
- ---
A. Soroka
Software & Systems Engineering :: Online Library Environment
the University of Virginia Library
On Mar 29, 2012, at 1:28 AM, goat wrote:
> OK, thanks.
> Is there any configuration for forcing Saxon loading stylesheets only
> once(cache them in memory)?
>
> --
> View this message in context: http://servicemix.396122.n5.nabble.com/dynamically-loading-the-stylesheet-has-bad-performance-tp5596806p5602707.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
iQEcBAEBAgAGBQJPdF8mAAoJEATpPYSyaoIk7xcIAMVAlsq32dPyK0pNuncvPrJD
QZmP/vzf2cY2gva40jwcYHvI5ul8XEiQ33dXK3hez2ftSFNV7TxoYJx7Hy6yAWSR
kbx8hm0HEsfmiH7ZXS/2y9fwu+4RB2Zra4C71h7jdVV8wvZrxms2JjZ6RWXngDJz
jR8gWDd/EakiTBUabHECvhgxZ+QJAj6O6Ln18CQkLhanKBJYCkpD4hAXecebS8Y3
mSXI8ipozYoe0gzXmWH6asgfdl6VvEnPQ7Qwmu8ZslGHeJ2LHKRdw2Blp6zVQXt6
XoesQ1RHCTITeYZei0Q74BWxJGTS8TRrZIdf5geBo3a4zS1Q4hn8ZvglJbV/VfY=
=LpWM
-----END PGP SIGNATURE-----
Re: dynamically loading the stylesheet has bad performance
Posted by goat <go...@gmail.com>.
OK, thanks.
Is there any configuration for forcing Saxon loading stylesheets only
once(cache them in memory)?
--
View this message in context: http://servicemix.396122.n5.nabble.com/dynamically-loading-the-stylesheet-has-bad-performance-tp5596806p5602707.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.
Re: dynamically loading the stylesheet has bad performance
Posted by "ajs6f@virginia.edu" <aj...@virginia.edu>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
It's not clear to me how the Saxon component would know that it had already loaded a stylesheet in the past. It does not, to my knowledge, keep a registry of compiled sheets or even a history of which ones it has compiled. So yes, it's going to load the stylesheet every time if you ask it to.
- ---
A. Soroka
Software & Systems Engineering :: Online Library Environment
the University of Virginia Library
On Mar 26, 2012, at 10:28 PM, goat wrote:
> hi,
>
> I use SAXON as following for dynamically loading the stylesheet
> according to PropertyExpression:
> Case1:
> <saxon:xslt service="test:xslt-dynamic" endpoint="endpoint">
> <saxon:expression>
> <bean class="org.apache.servicemix.expression.PropertyExpression">
> <property name="property" value="xslt.source" />
> </bean>
> </saxon:expression>
> </saxon:xslt>
>
> It was found that the performance was very bad while big load on it.
>
> But when I replace it with statically loading as following:
> Case2:
> <saxon:xslt service="test:xslt" endpoint="endpoint"
> resource="classpath:transform.xsl" />
> It was found that the performance is improved dramaticlly!
>
> It seems that SAXON load stylesheet everytime even if the xsl is same
> in Case1.
>
> Could anyone help me explain this?
> Thanks!
>
>
>
> --
> View this message in context: http://servicemix.396122.n5.nabble.com/dynamically-loading-the-stylesheet-has-bad-performance-tp5596806p5596806.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
iQEcBAEBAgAGBQJPc0rhAAoJEATpPYSyaoIkE4oIANcg04LTHZotCGNtQU+RG1Ze
qKpPstaeXrlizggANvozjcqD4G3Ic9UcqetuPz/pLjIyKXaoqU9GJI95JtJomTBw
2nKty/izn2VPAAJuGLJXD8CvSNfYhy8AQlidSK6F8HZyyBN4KqF35ZOLJ2LOajmV
/PSUqKT3nhm6xNB+jEoe63cwGux/nll6YW/Ogw2ksmCJr+UtczJNGGU3+350GDy3
rKaa8td1rQghhDQUTbOac5pc1mxEh08gy7icoYfs0WjMOCfUf74z6FmrAjaUXYI6
RbiFIBJI0+ZGqZ5aVgIIfPFL6cRNOGlezeqbDUisD6eyv+h9XEjJZlmZxZtXGtk=
=Mh0k
-----END PGP SIGNATURE-----