XSL 1.0/2.0+ usage on XPP

We are having problems maintaining the old "C++" version  of the program "Xalan" for XSL 1.0  processing. This program is triggered through "xychange" when the command line does NOT contain the "-xsl2" option, as we use the default behavior to preserve XSL 1.0 processing.  Since it is a program, it can also be used in scripting by calling "Xalan" directly. In my opinion, no one should be using XSL 1.0 at this point since it is has been far exceeded by 2.0/3.0 with very awkward work arounds for very common transformations and other transformations that are just not possible. The functionality has been replaced by the program "xppxslt",  which uses the Saxon parser, but requires Java.  Saxon is upwards compatible and XSL 1.0 transforms will run as is.

If you are doing XSL processing on XPP, I would like to know:

1. Are you installing Java and running with XSL 2.0+ functionality?

2. Are you calling the program "Xalan" directly in your scripts

3. Can XPP change the requirements to state that you need Java if you are doing any XSL processing at all?

With this in mind, in a future release we would:

1. Stop delivering "Xalan", but leave it on any system so custom scripts would still function.

2. Change "xychange" to automatically use the xppxslt/Saxon processor with or without the "-xslt2" option.

3. Change the requirements documentation to state that Java is required if doing any XSL processing. NOTE: Java is already required if using SVG or the 'xppcompare' program.

Thanks

Steve Piercey

RWS/SDL/XyEnterprise/Xyvision

Parents
  • Steve,

    Your timing is excellent as today I am just extending a very old production script that was created by the now defunct Portalyx. This script has been created in 2005 and is still at the heart of production at Maruboshi in Holland. There is a part of the script that is preprocessing the xml running 2 Xalan based XSLT steps of which I have no idea what they are doing and even no desire to know what they are doing (I am just the maintainer that makes sure everything keeps running and from time to time extends/adapts the script). So Xalan is still in use and in this case called directly. 

    Now to answer your questions one by one:

    1. Are you installing Java and running with XSL 2.0+ functionality?
    At every installation/upgrade I do, I make sure the Java run time is installed and the the XSLT2 engine is running.
    All the XSLT's we currently make are XSLTV2. Simply because the XSLTV2 engine is a lot faster than the V1 engine

    2. Are you calling the program "Xalan" directly in your scripts
    Well in this one particular case mentioned above: yes, but that is an exceptional case that I inherited
    I would be amazed if over time I ever created something else that would call xalan directly...but never say never

    3. Can XPP change the requirements to state that you need Java if you are doing any XSL processing at all?
    If you ask me: most certain

    With this in mind, in a future release we would:

    1. Stop delivering "Xalan", but leave it on any system so custom scripts would still function (and xychange continues to work as before).
    That is OK as long as you don't remove the existing Xalan from the system.
    Later added:
    Plus ' modify' xychange that if it finds the Xalan engine, it continues to use the Xalan engine for V1 stylesheets. (this to avoid unexpected changes that could occur when the V2 engine is always used)

    2. Change "xychange" to automatically use the xppxslt/Saxon processor with or without the "-xslt2" option.

    That is OK as well. I am assuming that you will run Saxon with the -versionmsg:off option (just like you do now?) so we will not see any of the warnings when you run an XSLT1 stylesheet with an XSLT2 engine.
    I am assuming also that you have been running enough test to see if the resulting XML files are any different. I think in most cases the result would be the same but you never know that there is some obscure stylesheet out there that produces a slightly different result that might upset something else futher downstream

    3. Change the requirements documentation to state that Java is required if doing any XSL processing. NOTE: Java is already required if using SVG or the 'xppcompare' program.

    I even think that it is best to just add the installation of a java run time engine to the prerequisites to installing an XPP server.
    (How does a sys admin ever know that sooner or later nobody is going to run XSLT2 or xppcompare or SVG image conversion on the XPP system???)
    Having it as a prerequisite will prevent a lot of wasted time later on when a poor user is trying any of the above.

  • We agree with Bart but we have a question: If you "leave as is" on existing systems but remove this from the install for new installs what happens when a user wants to upgrade their server. Traditionally the users would do a clean install and therefore would lose the Xalan in that scenario.

Reply Children