XI20 XSLT performance

Hello all,
I use an XSLT mapping for a XML to XML mapping (without DB access and without additional JAVA code). I was wondering if there is a way to increase the performance as I'm not satisfied with the overall XI performance when processing.
I run XI20 SP05 on Windows 2000 server with 4 CPUs and 2GB RAM. In my testing it took 111 seconds to process a input XML file containing 500 records with 17 tags per record.
When I process the same mapping on my laptop with a 1000 record XML file in XMLSPY it takes only 5 sec to finish.
Does someone have a hint why XSLT mapping in XI is that slow and how the performance can be improved without upgrading the hardware?
Best regards and thanks
Mario Müller

Mario,
This may sound strange, but you could improve the performance of your mapping by using Java or the XI message mapping.
XSLT loads all the XML message into memory and then maps the data according to the instructions.  This means that the process will use more memory and be slow that the other options.
The SAP XI message mapping only loads the node that it is working on and maps according to the instructions.  This means it uses less memory and is quicker.
Java mapping may be quicker that XSLT (and/or XI message mapping), depending on how it is coded.
Hope this helps.
Regards,
Simon

Similar Messages

  • XSLT performance problem

    Hi, I have an Oracle 81746 database and xdk92040 installed.
    I use the following procedure to create HTML from an XML clob (this is based on the xslsample provided in the documentation of oracle XML for PL/SQL):
    procedure BUILD_HTML(p_xml_inhoud in clob,
    p_inhoud out clob) is
    p xmlparser.Parser;
    xmldoc xmldom.DOMDocument;
    xmldocnode xmldom.DOMNode;
    proc xslprocessor.Processor;
    ss xslprocessor.Stylesheet;
    xsldoc xmldom.DOMDocument;
    docfrag xmldom.DOMDocumentFragment;
    docfragnode xmldom.DOMNode;
    xslelem xmldom.DOMElement;
    nspace varchar2(50);
    xslcmds xmldom.DOMNodeList;
    begin
    -- new parser
    p := xmlparser.newParser;
    -- set some characteristics
    xmlparser.setValidationMode(p, FALSE);
    xmlparser.setPreserveWhiteSpace(p, TRUE);
    -- parse xml file
    xmlparser.parseClob(p,p_xml_inhoud);
    xmldoc := xmlparser.getDocument(p);
    -- parse xsl file
    xmlparser.parse(p, 'f:\temp\ps2.xsl');
    -- get document
    xsldoc := xmlparser.getDocument(p);
    xslelem := xmldom.getDocumentElement(xsldoc);
    nspace := xmldom.getNamespace(xslelem);
    ss := xslprocessor.newStylesheet(xsldoc,'f:\temp\ps2.xsl');
    -- process xsl
    proc := xslprocessor.newProcessor;
    xslprocessor.showWarnings(proc, true);
    dbms_lob.createtemporary(p_inhoud,false);
    xslprocessor.processXSL(proc,ss,xmldoc,p_inhoud);
    -- Free XML Documents
    xmldom.freeDocument(xmldoc);
    xmldom.freeDocument(xsldoc);
    -- Free XSL Stylesheet and Processor
    xslprocessor.freeProcessor(proc);
    xslprocessor.freeStylesheet(ss);
    -- Free the xmlparser
    xmlparser.freeParser(p);
    end;
    Now, the input file is small :
    <?xml version = '1.0' encoding = 'ISO-8859-1'?>
    <ROWSET>
    <ROW num="1">
    <PS_ID>10422</PS_ID>
    <DN_REF_FAMILIENAAM>zzzzzzzz</DN_REF_FAMILIENAAM>
    <DN_REF_VOORNAAM>zzz</DN_REF_VOORNAAM>
    <GESLACHT>m</GESLACHT>
    <PS_NAMEN>
    <PS_NAMEN_ROW num="1">
    <NAAM>zzzzzzzz</NAAM>
    <NAAMSOORT>familienaam</NAAMSOORT>
    <SORTEERNR>10</SORTEERNR>
    </PS_NAMEN_ROW>
    <PS_NAMEN_ROW num="2">
    <NAAM>zzz</NAAM>
    <NAAMSOORT>ee
    rste voornaam</NAAMSOORT>
    <SORTEERNR>31</SORTEERNR>
    </PS_NAMEN_ROW>
    </PS_NAMEN>
    <PS_WOONPLAATSEN/>
    <RL_PS_PS/>
    <PS_TITELS/>
    <BIOGRAFIE></BIOGRAFIE>
    <PROFIEL></PROFIEL>
    <PS_ONDERWIJS/>
    <P
    S_DIPLOMAS/>
    <PS_TALEN/>
    <PS_BEROEPEN/>
    <PS_ERETEKENS/>
    <RL_OR_PS/>
    <PS_POL_MANDATEN/>
    <PS_POL_FUNCTIES_T/>
    <RL_PS_PB/>
    <BRONNEN></BRONNEN>
    <PERSOONLIJK_AE/>
    <PS_FAM/>
    <RL_PS_AE/>
    <WE
    RKEN/>
    <BIBLIOGRAFIE/>
    <PS_TREFWOORDEN>
    <PS_TREFWOORDEN_ROW num="1">
    <PS_CLUSTERTREFWOORDEN/>
    <PS_GROEPSTREFWOORDEN/>
    <PS_SPECIFICATIETREFWOORDEN/>
    </PS_TREFWOORDEN_ROW>
    </PS_TREFWOOR
    DEN>
    <PS_GEO_TREFWOORDEN/>
    <PS_BIJLAGEN/>
    <OPMERKINGEN>Syrië Jordanië</OPMERKINGEN>
    <PS_AUTEURS/>
    <LAATSTE_WIJZIGING>2003-01-15 17:08:14</LAATSTE_WIJZIGING>
    </ROW>
    </ROWSET>
    The XSLT file is rather big, so I don't included it here.
    The time that the statements in my BUILD_HTML procedure take, are as follows:
    xmlparser.parseClob(p,p_xml_inhoud); 0,3 sec
    xmlparser.parse(p, 'f:\temp\ps2.xsl'); 0,83 sec
    newStylesheet 0,42 sec
    processXSL 0,12 sec
    So the big bottleneck in the system are
    xmlparser.parse(p, 'f:\temp\ps2.xsl');
    and
    newStylesheet 42
    What should I do to make this more performant?
    If there is no other way : is there another Oracle-solution which I can use to transform XML to HTML?

    The performance really depends on how you write the XSL.

  • XSLT performance problem in Oracle

    Hi,
    I'm doing a XSLT in oracle. For this I use the XMLPARSER and XSLPROCESSOR package provided by Oracle.
    The function which implements this package has the following code.
    function get_XML
    (p_product_clob IN clob, p_stylesheet_id IN varchar2) return clob
    -- Local variables
    l_xslprocessor xslprocessor.PROCESSOR;
    l_stylesheet_DOMDoc xmldom.DOMDocument;
    l_xml_DOMDoc xmldom.DOMDocument;
    l_stylesheet_xmlparser xmlparser.PARSER;
    l_xml_xmlparser xmlparser.PARSER;
    l_stylesheet xslprocessor.STYLESHEET;
    -- to store the xml structure from the int_product_hist table.
    l_stylesheet_clob clob; -- to store the xsl to applied to the xml.
    l_result_xml clob; --output xml structure.
    begin
    --create a temporary clob
    dbms_lob.createtemporary(l_result_xml,true,dbms_lob.session);
    -- Check if the input xml clob variable is empty
    if dbms_lob.GETLENGTH(p_product_clob)=0 then
    return null;
    end if;
    -- Check for 205 according to which stylesheet is to be applied.
    if rtrim(ltrim(p_stylesheet_id)) is not null then
    select STYLESHEET_DESC into l_stylesheet_clob
    from SM_XML_STYLESHEETS
    where STYLESHEET_ID=p_stylesheet_id;
         if sql%notfound then
         return null;
         end if;
    else
    return null;
    end if;
    -- make objects
    l_xml_xmlparser := xmlparser.NEWPARSER;
    l_stylesheet_xmlparser := xmlparser.NEWPARSER;
    l_xslprocessor := xslprocessor.NEWPROCESSOR;
    -- Assign a parser to xml and xsl
    xmlparser.parseClob(l_xml_xmlparser, p_product_clob);
    xmlparser.parseClob(l_stylesheet_xmlparser, l_stylesheet_clob);
    l_xml_DOMDoc := xmlparser.GETDOCUMENT(l_xml_xmlparser);
    l_stylesheet_DOMDoc := xmlparser.GETDOCUMENT(l_stylesheet_xmlparser);
    l_stylesheet:=xslprocessor.NEWSTYLESHEET(l_stylesheet_DOMDoc,null);
    -- applying the xsl on xml.
    xslprocessor.processXSL(l_xslprocessor, l_stylesheet, l_xml_DOMDoc, l_result_xml);
    -- free all objects.
    xmlparser.freeParser(l_xml_xmlparser);
    xmlparser.freeParser(l_stylesheet_xmlparser);
    xslprocessor.freeStylesheet(l_stylesheet);
    xslprocessor.freeProcessor(l_xslprocessor);
    -- return the xml after xslt.
    return l_result_xml;
    end;
    The xml is sent as a parameter to this function (p_product_clob) and the stylesheet id is sent as input to this function. The stylesheet is picked from the table based on the id passed as parameter.
    The function returns a correct output. But it takes a lot of time to do this operation (2 min). My project requirement is 5 sec.
    Is there anyway that we can reduce the time for this XSLT.
    Regards,
    Milton.

    Would you send sample XML and XSL file? Or at least the XSL file.
    Thanks.

  • XSLT performance

    Hi,
    I've a jsp include file which has got 4 xsl transformations using xalan. This file is to be included in all pages of my application. Is there a better way to do this without transforming every time this page is included. If I store the transformed output in session, will that affect the performance of my web application?
    Thanks,
    Simi.

    Try looking into OSCache. Its a JSP Tag Lib written that will allow you to cache the results of jsp for a session or application level. Its very good and it will for sure help performance.
    http://www.opensymphony.com/oscache/
    It's a very good OS Product too and VERY simple to use.
    You get more then your moneys worth :P

  • Performance of XSLT transformation

    Hello everybody,
    I´m trying to do some in-database XML transformations from one XML format to another with a rather complex xsl stylesheet of about 9000 lines of code which performs this transformation. At first I tested the XDK XSLT functionality by simply doing a Transformation over the JAXP API outside the Database. It performed not bad, altough the memory consumption was a little bit higher then Saxon or Xalan. After that I read about the possibilities of in-database transformation, which should consume less memory because of oracle´s xml features like scalable DOM, XML Indexing and Query Rewriting when using object relational or binary storage. So we loaded our testdata into the db (we are using 11gR2 on a test system with Intel Core2Duo @ 3GhZ and 3GB RAM), in different XML storage options (XMLTYPE CLOB, Binary, OR) and tried to do a XSLT transformation on the columns. But it isn´t working.
    The db seems not to be able to cope with the transformation although the parser and processor should be the same as the off-database transformation that was working well (or am I wrong?). After half an hour we aborted because the db hadn´t finished the transformation yet (the off-db transformation of this 100KB XML took less then a second). We tried indexing the columns with XMLIndex, didn´t work out, we tried both XMLTYPE´s XMLtransform() and dbms_xslprocessor.processxsl(), same problem, the DB is working and working with no result, after some time we have to terminate. With a simple teststylesheet the transformation is doing fine but our complex stylesheet seems to be the problem.
    My question is, why is the xslt performance so poorly with the complex stylesheet and why can I use the XDK Parser and Processor in an off-db transformation very efficiently but when doing the same transformation in the db it´s not working.
    Hope you can help me out a little bit I´m really running out of ideas.
    Greetz dirac

    Hi,
    The db seems not to be able to cope with the transformation although the parser and processor should be the same as the off-database transformation that was working well (or am I wrong?). No, the database built-in XSLT processor (C-based) is not the same as the XDK's Java implementation.
    There's also a C XSLT processor available for external transformation and working with compiled stylesheets, it should outperform the Java implementation.
    See : http://docs.oracle.com/cd/E11882_01/appdev.112/e23582/adx_c_xslt.htm#i1020191
    We tried indexing the columns with XMLIndex, didn´t work out, we tried both XMLTYPE´s XMLtransform() and dbms_xslprocessor.processxsl(), same problem, the DB is working and working with no result, after some time we have to terminate. With a simple teststylesheet the transformation is doing fine but our complex stylesheet seems to be the problem.XMLIndexes won't help at all in this situation.
    In my experience so far with the built-in engine, I've seen the best result when the XML document we want transform is stored as binary XML.
    I don't know about the scalable DOM (or "lazy" DOM loading) feature described in the documentation, seems it doesn't support complex transformations, much like functional vs. streaming evaluation for XQuery.
    Hope you can help me out a little bit I´m really running out of ideas.I'd be interested in a test case if you have the possibility (stylesheet + sample input XML). You can mail me at this address : mb[dot]perso[at]wanadoo[dot]fr
    If you can't, could you describe what kind of transformation you're performing and how can I reproduce that behaviour?
    Thanks.
    Marc.

  • Java Translets XML/XSLT Transformation

    Translets "are precompiled XSL documents that are optimized and converted into simple Java classes. When you compile your application Java files, you compile your XSL files into Java class files. During runtime, you can load translets like any regular Java class and perform XSL transformations over and over again.
    The syntax checking and parsing of XSL documents are done when the XSL files are compiled. The transformation therefore takes only as long as the compiled code takes to execute, which improves performance multiple folds.
    The downside to using XSL is that "it can take a considerable amount of time and reduce performance. The time needed to parse XML and XSL documents is directly proportional to the size of the documents. Each transformation requires the XML and XSL documents to be loaded, syntax checked, and parsed." I recommends using translets for the following reasons.
    I had written an application (<a href="http://www.simplygites.com" title="www.simplygites.com">SimplyGites</a>) using standard XSL / XML transformation and experienced some very slow server-side transformation on the very complex screens with large amounts of xml. Timings showed these problem screens took 2-3 seconds to transform, which was totally unacceptable non-functional requirements.
    I considered rewriting these screens as JSP or PHP, then I discovered Translets. And wow what a discovery the timings for these pages now compiled as Translets(java classes) are amazing in comparison to the original timings ? I now have them transforming in 500ms (all now under 1 second).
    I would recommend anyone using XSL/XML transformation to use Translets, these have now been running tried and tested on the <a href="http://www.simplygites.com" title="www.simplygites.com">SimplyGites</a> for the past 6months.
    Technolgies used:
    Weblogic 8.1 SP5
    Java 1.4.2
    Required Jars
    xsltc.jar
    runtime.jar
    BCEL.jar
    JLex.jar
    java_cup.jar
    regexp.jar
    xml-dtm.jar
    For more information see http://xml.apache.org/xalan-j/xsltc_usage.html
    I hope this helps anyone that has XML/XSLT performance issues.
    Mark
    MB Computer Ltd
    www.simplygites.com

    Thanks for your help.
    The problem was that my firewall was blocking my server.

  • Writing XSLT to perform transformation from XML to ABAP

    Hi,
    I've been struggling quite a bit with XSLT. I read several old discussions regarding transformations using ST and XSLT but I haven't been able to solve my problem.
    I have a requirement to build a program to convert XML to an internal table.
    I've been able to do it for smaller XMLs, but whenever I try to apply the same logic to a bigger XML it simply just doesn't work. I'm almost certain it has something to do with the way I wrote the XSLT but I haven't been able to figure out what.
    The XML I have to read from goes something like this:
    <?xml version="1.0" encoding="WINDOWS-1252"?>
    -<AuditFile xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:OECD:StandardAuditFile-Tax:PT_1.02_01">
         -<Header xmlns="urn:OECD:StandardAuditFile-Tax:PT_1.02_01">
              <AuditFileVersion>1.02_01</AuditFileVersion>
                   <CompanyID>50002</CompanyID>
                   <TaxRegistrationNumber>5000</TaxRegistrationNumber>
                   <TaxAccountingBasis>F</TaxAccountingBasis>
                   <CompanyName>Company</CompanyName>
                   <BusinessName>Business</BusinessName>
                   -<CompanyAddress>
                        <AddressDetail>Address</AddressDetail>
                        <City>city</City>
                        <PostalCode>333333</PostalCode>
                        <Country>PT</Country>
                   </CompanyAddress>
                   <FiscalYear>2013</FiscalYear>
                   <StartDate>2013-07-01</StartDate>
                   <EndDate>2013-07-31</EndDate>
                   <CurrencyCode>EUR</CurrencyCode>
                   <DateCreated>2013-08-02</DateCreated>
                   <TaxEntity>Global</TaxEntity>
                   <ProductCompanyTaxID>00</ProductCompanyTaxID>
                   <SoftwareCertificateNumber>00</SoftwareCertificateNumber>
                   <ProductID>product</ProductID>
                   <ProductVersion>00</ProductVersion>
                  <Email>email@com</Email>
                   <Website>www.s.pt</Website>
         </Header>
         -<MasterFiles xmlns="urn:OECD:StandardAuditFile-Tax:PT_1.02_01">
              -<Customer>
                   <CustomerID>1</CustomerID>
                   <AccountID>ID</AccountID>
                   <CustomerTaxID>999999990</CustomerTaxID>
                   <CompanyName>Desconhecido</CompanyName>
                   -<BillingAddress>
                        <AddressDetail>Desconhecido</AddressDetail>
                        <City>Desconhecido</City>
                        <PostalCode>0000-000</PostalCode>
                        <Country>PT</Country>
                   </BillingAddress>
                   <SelfBillingIndicator>0</SelfBillingIndicator>
              </Customer>
              -<Customer>
                   <CustomerID>2</CustomerID>
                   <AccountID>Desconhecido</AccountID>
                   <CustomerTaxID>571</CustomerTaxID>
                   <CompanyName>Company</CompanyName>
                   -<BillingAddress>
                        <AddressDetail>detail</AddressDetail>
                        <City>city</City>
                        <PostalCode>0000-000</PostalCode>
                       <Country>PT</Country>
               </BillingAddress>
              <SelfBillingIndicator>0</SelfBillingIndicator>
         </Customer>
    ...and so on
    And the XSLT I've written so far is something like this:
    <xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
       <xsl:output encoding="iso-8859-1" indent="yes" method="xml" version="1.0"/>
       <xsl:strip-space elements="*"/>
       <xsl:template match="/">
         <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
           <asx:values>
             <ICUSTOMER>
               <xsl:apply-templates select="//Customer"/>
             </ICUSTOMER>
           </asx:values>
         </asx:abap>
       </xsl:template>
       <xsl:template match="Customer">
         <item>
           <CUSTOMER_ID>
             <xsl:value-of select="CustomerID"/>
           </CUSTOMER_ID>
           <ACCOUNT_ID>
             <xsl:value-of select="AccountID"/>
           </ACCOUNT_ID>
           <CUSTOMERTAX_ID>
             <xsl:value-of select="CustomerTaxID"/>
           </CUSTOMERTAX_ID>
           <COMPANYNAME>
             <xsl:value-of select="CompanyName"/>
           </COMPANYNAME>
           <ADDRESSDETAIL>
             <xsl:value-of select="BillingAddress/AddressDetail"/>
           </ADDRESSDETAIL>
           <CITY>
             <xsl:value-of select="BillingAddress/City"/>
           </CITY>
            <POSTALCODE>
             <xsl:value-of select="BillingAddress/PostalCode"/>
           </POSTALCODE>
            <COUNTRY>
             <xsl:value-of select="BillingAddress/Country"/>
           </COUNTRY>
           <SELFBILLINGINDICATOR>
             <xsl:value-of select="SelfBillingIndicator"/>
           </SELFBILLINGINDICATOR>
         </item>
       </xsl:template>
    </xsl:transform>
    Like I said, I'm almost certain that the problem is with the XSLT, as it returns an empty table / ALV. I've used this method before and it worked...
    Any thoughts?
    Thank you

    Hello Goncalo,
    I think, there are two problems:
    1) The xmlns declaration within your xml is a problem for the SAP XSLT Processor.
    2) I have written a similar XSLT-report, which performs directly with your data. Perhaps this is not necessary if 1) is solved:
    <xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    version="1.0">
       <xsl:output encoding="iso-8859-1" indent="yes" method="xml" version="1.0"/>
       <xsl:strip-space elements="*"/>
       <xsl:template match="AuditFile">
         <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
           <asx:values>
              <xsl:apply-templates select="MasterFiles"/>
           </asx:values>
         </asx:abap>
       </xsl:template>
       <xsl:template match="MasterFiles">
             <ICUSTOMER>
               <xsl:apply-templates select="./Customer"/>
             </ICUSTOMER>
       </xsl:template>
       <xsl:template match="Customer">
           <CUSTOMER_ID>
             <xsl:value-of select="CustomerID"/>
           </CUSTOMER_ID>
           <ACCOUNT_ID>
             <xsl:value-of select="AccountID"/>
           </ACCOUNT_ID>
           <CUSTOMERTAX_ID>
             <xsl:value-of select="CustomerTaxID"/>
           </CUSTOMERTAX_ID>
       </xsl:template>
    </xsl:transform>
    Kind regards,
    Hendrik

  • How to perform an XSLT Mapping Test

    Hi,
    I have defined an XSLT Mapping in XI and it seems to work, but when I perform a test in my Interface Mapping the source fields are not written on respective target fields. What is the problem?
    Thanks!

    The issue is in the logic f your XSL mapping.
    Use the same source XML and use it with XML Spy to debug why it is not working as you want it to.
    Regards
    Bhavesh

  • SAPXMLTOOLKIT Performance issue on XSLT conversion

    Hi,
    I am runnning a large XSLT transformation (source XML ~
    16MB - relatively flat format record structure from a POS
    system converting to IS Retail IDOC WPUBON  IDOC -
    around5MB of converted XML).
    The aim is that this is portable bewteen SAP Business
    Connector and SAP XI (both using the SAP XML TOOKIT). It
    was looking good (around 80 seconds conversion time on my
    laptop) and then I got a sapxmltoolkit.jar update (then I
    tried it on SAP BC 4.7 then tracked it down to versions
    of the sapxmltoolkit).
    I then looked at the command line performance on this for
    various different versions of sapxmltoolkit (used to be
    command line from inqmyxml.jar) - we use xmlspy for XSLT
    development and you can hook in a command line call to
    use the library... sample call:
    C:jdk1.3.1_15jrebinjava -ms384M -mx1024M -cp D:testingsapxmltoolkit.jar;
    C:jdk1.3.1_15jrelibrt.jar;D:testingSCTmapping.jar
    com.sap.engine.lib.xsl.xslt.CommandLine %1 %2 %3 %4
    LOOKING AT THE PROPERTIES file from the jar file the
    following version works well. Run time around 80 seconds
    completing in 500M of memory
    version=630.20030828104710.0000   GOOD
    the next two versions I have work very badly - run time
    greater than 10 minutes, system pages itself to death
    uses all 1GB of java memory (and my laptop only has 1GB)
    version=630.20050221090341.0000       BAD
    version=630.20040429124817.0000       BAD
    I see the latest version available still seems to be
    stamped 630 (even in 640 netweaver shipment). Who
    develops this... My samples to replicate this problem are
    rather large... but happy to post them to site for
    interested party
    Even on a 140K sized sample XML the same ratio exists
    goes from a few seconds to convert to minutes.... just on
    a change in sapxmltoolkit versions
    Regds Doug.
    mailto:[email protected]

    Thanks Alexander,
    Have logged as message 0120025231 / 0000618401 / 2005
    My short term fix is to run an IDE with known version of sapxmltoolkit (and invoke this separately) and avoid the built in sapxmltookit.jar...

  • Perform XSLT on XML as data source?

    Crystal Reports 2008 (12.0.0.549) can use XSLT when exporting an XML document.
    Can the XML driver, however, be configured to perform a XSLT on an XML document that will result in a document that will be used as a data source? 
    When I attempted to do so, I got an error--I was using an XSL document as the data source.

    Jamie-
    Thanks for the response.
    I'm trying to represent my résumé in XML format, then use Crystal Reports to generate a formatted, PDF document: craibuc/crystal-xmlresume · GitHub
    I'm hoping to avoid too much pre-processing, hence the desire to keep the data source in XML.  As such, exporting to CSV isn't an option.
    If this isn't possible, it would be a nice enhancement to the XML driver.

  • Performance of mappings (JAVA, XSLT, ABAP)

    Hello everybody,
    I would like to know about the performance of mappings using different languages (JAVA, XSLT, ABAP).
    Does anybody know which one will have the best performance?
    Thanks a lot.
    Regards Mario

    Hi Mario,
    I thought i will start of from scratch. Mapping is basically done to convert one form of xml into another form. This can be done using either of them mentioned below.
    - Graphical mapping
    - XSLT mapping
    - JAVA mapping
    - ABAP mapping
    There is no hard and fast rule for using the mapping techniques. But, I will try to put things in the right perspective for you.
    Graphical Mapping is used for simple mapping cases. When, the logic for your mapping is simple and straight forward and it does not involve any complex logic.
    Java and XSLT mapping are used when graphical mapping cannot help you.
    When the choice is between Java and XSLT, XSLT is simpler than java mapping and easier. But, it has its drawbacks. One among them being that you cannot use Java APIs and Classes in it. There might be cases in your mapping when you will have to perform something like a properties file look up or a DB lookup, such scenarios are not possible in XSLT and so, when you want to use some specific Java API's you will have to go for Java Mapping.
    Java Mapping uses 2 types of parsers. DOM and SAX. DOM is easier to use with lots of classes to help you create nodes and elements, but, DOM is very processor intensive.
    SAX parser is something that parses your XML one after the other, and so is not processor intensive. But, it is not exactly easy to develop either.
    To know more about each of them please go thru the following links. And if you ask me your which is better, it depends basically on the scenario you implementing and the complexity involved. Anyways please go thru the following links:
    Graphical mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/6d/aadd3e6ecb1f39e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/43/c4cdfc334824478090739c04c4a249/content.htm
    /people/bhanu.thirumala/blog/2006/02/02/graphical-message-mapping-150-text-preview
    http://www.sapgenie.com/netweaver/xi/mapping1.htm
    /people/alessandro.guarneri/blog/2006/01/26/throwing-smart-exceptions-in-xi-graphical-mapping
    XSLT mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/content.htm
    http://www.w3.org/TR/xslt20/
    JAVA mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/e2/e13fcd80fe47768df001a558ed10b6/content.htm
    DOM parser API
                     http://java.sun.com/j2se/1.4.2/docs/api/org/w3c/dom/package-frame.html
    ABAP mapping
    /people/r.eijpe/blog
    To know more about the value mapping tools for the SAP Exchange Infrastructure (XI), please go thru the following link:
    http://www.applicon.dk/fileadmin/filer/XI_Tools/ValueMappingTool.pdf
    To get an idea as to what value mapping is, please go thru the following links:
    http://help.sap.com/saphelp_nw04/helpdata/en/13/ba20dd7beb14438bc7b04b5b6ca300/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/f2/dfae3d47afd652e10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/2a/9d2891cc976549a9ad9f81e9b8db25/content.htm
    most of the links that I have provided also helps you get the step by step procedure of doing the same. And also involves the procedure to implement certain advanced features.
    And please go through this link which clearly explains the 3 types of mappings.
    /people/ravikumar.allampallam/blog/2005/02/10/different-types-of-mapping-in-xi
    Hope this clears your doubt fully.
    Regards,
    Abhy
    PS: AWARD POINTS FOR HELPUL ANSWERS.

  • Performance of XSLT

    We have an HTML page which user will use to get information. At the click of submit information is queried from 2 systems which is in XML format. This information is then merged into one before sending it back to the client.
    Couple of questions:
    1. My question, is it advisable to use XSLT for such kind of real time environment. I am not sure of the performance, if it's going to overload CPU, memory etc.
    2. What are the basic guidelines for writing efficient XSLT transformation.
    3. Is merging using XSLT slower than directly doing it in JAXB?

    In my experience, the decision to use Java code vs. XSLT is based on a couple of factors:
    1) Is what you want to do something that can be done in XSLT? XSLT is a very powerful tool but it is very quirky. It is very different from any other programming language I've used (and I have used a lot of them). So, the first test is "Can what I want to do be done easily in XSLT?"
    2) Next, who will make changes? If this is code to be shipped to a client and they will need to make minor changes over a period of time, and you don't want them to change the Java code, or the person who will be responsible for making those changes is not a Java programmer, then XSLT may be a better way than having the transformative code in Java. Also, changes might be done by an administrator with some training in XSLT more easily than having to teach them Java + XML + WebServices + database + + + .
    3) I've never heard of situations where XSLT caused stack overflows, or lengthy delays. That is not to say that you can be sloppy and XSLT will save you. XSLT does not have some "simple" constructs like mutable variables, or loops as in most for or while loops, one fallback is to use recursion. This can eat memory if not controlled and tested.
    4) Any work to fine tune the speed of this operation will probably be overshadowed by bad code in other parts of the application.
    I cannot think of anything that can be done in XSLT that cannot be done in Java code. There are many things that cannot be done in XSLT, however, that can be done in Java. Writing and debugging XSLT, especially the first 100,000 or so times is not simple for anything more complex than a textbook or tutorial exercise.
    So, there are no hard and fast rules on which is better. Each is the right choice for a set of problems. You have not given us enough information to make that decision. I've tried to help with your decision.

  • How to perform an xslt transformation on an xml document dynamically ?

    Hi all,
    I'd like to perform an xslt tranformation on a dynamically generated xml code. I'm looking for a tag which can by useful for it. The tag should take both xml code and xslt code, passed as String arguments (not as names of xml and xslt files). I tried to use xtags library and jstl:transform tag but it did not work. It worked only with plain xml code passed to x-tag. When I try to perform a transformation on a tag body containing an output text tag, the transformation formats only this tag, not its content.
    For example:
    <xtags:style xslt="xslName.xsl">
    <h:outputText value="#{beanName.stringPropertyName}"/>
    </xtags:style>
    Thanks in advance
    Message was edited by:
    opad

    The issue is in the logic f your XSL mapping.
    Use the same source XML and use it with XML Spy to debug why it is not working as you want it to.
    Regards
    Bhavesh

  • Performance issue: Java and XSLT

    I have a performance issue concerning Java and XSLT: my goal is to transform an xml file (source.xml)
    by using a given xsl file (transformation.xsl). As result I would like to get a String object, in which the result
    of the transformation (html-code) is in, so that I can display it in a browser. The problem is the long time
    it takes for the code below to run through.
    xml = new File("C:\\source.xml");
    xmlSource = new StreamSource(xml);
    xslt = new File("C:\\transformation.xsl");
    StreamSource xsltSource = new StreamSource(xslt);
    TransformerFactory transFact = TransformerFactory.newInstance();
    trans = transFact.newTransformer(xsltSource);
    StringWriter stringWriter = new StringWriter();
    StreamResult streamResult = new StreamResult(stringWriter);
    trans.transform(xmlSource, streamResult);
    String output = stringWriter.toString();
    stringWriter.close();
    Before, I made the same transformation in an xml development environment, named Cooktop
    (see http://xmlcooktop.com/). The transformation took about 2 seconds. With the code above in Java it
    takes about 20 seconds.
    Is there a way to make the transformation in Java faster?
    Thanks in advance,
    Marcello
    Oldenburg, Germany
    [email protected]

    I haven't tried it but the if you can use java 6, you could try the new stax (StAX) with the XML stream loading..
    Take a look at:
    http://javaboutique.internet.com/tutorials/staxxsl/
    Then, you could cache the xslt in templates:
    ---8<---
    templates = transformerFactory.newTemplates( xsltSource );
    Transformer transformer = templates.newTransformer();
    (here you could probobly also cache the Transformer object but I think it's it's not thread safe so it's a little tricker..)
    StreamResult result = new StreamResult( System.out );
              transformer.transform(xmlSource, result);
    And, don't transform your result to a string, use a Stream or something, then the transformer could start pumping out html while working, and if you get a out of memory error it looks like you have a pretty big xml file...
    If you use jsp you could try the build in jsp taglib for xml which I think is rather good and they have support for varReader which implements the StreamSource iirc.
    /perty

  • Poor performance of XSLT-transformation

    Hi, everyone
    I`ve got report in BI-publisher based on xsl-template.
    This template transforms flat xml-file in Excel file and displays the data in the likeness of a cross-tab.
    Everything looks fine, but when the input file is larger than 1 MB, then the output file is formed about 10-15 minutes.
    However, when the input file is less than 1 MB, I got the output file is less than 1 minute.
    How i can see where is the "bottleneck"?
    What i can do to improve performance of xslt-transformation?
    Thanks

    Hi,
    Sorry that did not respond sooner.
    We have gave the process of 1024 MB memory.
    It`s about 4100+ records in result xml.
    BIP version is 10.1.3.4 and java - 1.6.
    Xsl-template and Xml you can download here
    Thank you for reply =)

Maybe you are looking for

  • Adobe Bridge CS6 no muestra correctamente las miniaturas de video en formato .mov

    En Adobe Bridge CS5 y 5.1 cuando yo en algun video de formato .mov le asignaba un fotograma poster desde el programa Quicktime, automaticamente adobe Bridge me tomaba ese fotograma poster como la minuatura para el video, pero en CS6 eso no pasa, ¿Que

  • Document number in BAPI_DOCUMENT_CREATE2

    Hi All, Can some one tell me, do  i haive to pass the number to  DOKNR in BAPI_DOCUMENT_CREATE or it will take care the DOKNR creation itself, if i have to pass the number, can i pass the number which is generated randomly using NUMBE_GET_NEXT. And a

  • Dynamic Programming - Chart

    Hi all     i am creating dynamic charts, i am having problem on setting specific customizing taht usually do the Chart Designer. here my code:           graphic = (IWDBusinessGraphics) view.createElement(IWDBusinessGraphics.class, null);           gr

  • Can I perform masking & layers for HDR image in Aperture 2 _RAW images

    Hello I own Aperture 2. Can I do post processing such as masking & layers like one do to to create HDR image. If so... I generally take in RAW format. In Photoshop or Photomatix the HDR post processing is done in JPG. [I do not own Photoshop or Photo

  • Printing to PDF on Mac system

    Using Adobe 8 on a Mac system and print to Adobe does not work; the "PDF" button is there; however, when selecting that it does not "remove" the comments from the document.  Basically, we make internal comments on our documents, which are saved, and