Topic
  • 2 replies
  • Latest Post - ‏2013-06-29T10:33:57Z by HermannSW
samanderson
samanderson
172 Posts

Pinned topic Stylesheet caching standards

‏2013-06-28T13:48:53Z |

Experts -

 

Please help me understand below :-

 

Is there an idle value for setting this style sheet cache and document cache on xml manager? Suggest me for one idle value for high volume of transactions and long style sheets and xml documents.

Does it vary from DP box to DP box based on flash memory?

What will be the max value ?

 

 

  • swlinn
    swlinn
    1391 Posts

    Re: Stylesheet caching standards

    ‏2013-06-28T15:45:20Z  

    I don't believe there is a cache timeout on the stylesheet cache.  For on box files, the firmware will recognize if the stylesheet has changed and will recompile it if necessary.  If you are pulling your stylesheets from an off box location, such as a http server, then you'll need to flush the cache to recompile.  As for the document cache, the time to live is specified on the doc cache policy.  You need to consider how many files you would want to cache and how large they are.  High volume and large files I would specify with a larger priority if using a fixed policy as reparsing them will mean the appliance is spending more time doing work it could be doing servicing your client requests.  If you are using protocol based policies, then the appliance will follow what the protocol headers are specifying.  If you can, I'd create the cache large enough to handle the majority if not all of your documents, and if not all, then set the priority such that smaller and less frequently used files are removed from the cache to make room for newer entries.

    Regards,

    Steve

  • HermannSW
    HermannSW
    5497 Posts

    Re: Stylesheet caching standards

    ‏2013-06-29T10:33:57Z  
    • swlinn
    • ‏2013-06-28T15:45:20Z

    I don't believe there is a cache timeout on the stylesheet cache.  For on box files, the firmware will recognize if the stylesheet has changed and will recompile it if necessary.  If you are pulling your stylesheets from an off box location, such as a http server, then you'll need to flush the cache to recompile.  As for the document cache, the time to live is specified on the doc cache policy.  You need to consider how many files you would want to cache and how large they are.  High volume and large files I would specify with a larger priority if using a fixed policy as reparsing them will mean the appliance is spending more time doing work it could be doing servicing your client requests.  If you are using protocol based policies, then the appliance will follow what the protocol headers are specifying.  If you can, I'd create the cache large enough to handle the majority if not all of your documents, and if not all, then set the priority such that smaller and less frequently used files are removed from the cache to make room for newer entries.

    Regards,

    Steve

    Stylesheet cache does not have a timeout value.

    But there is no need for that.
    As long as the maximum number of stylesheets in an XML Manager's stylesheet cache is not reached, there is no need to remove one/some/all.

    "XSL Cache Size   256  stylesheets" is the default when configuring your XML Manager.
    In case the maximum number is used, and a new stylesheet needs to be cached, an old one is removed for it.


    Whenever "something" gets compiled (stylesheet, XPATH expression, WSDL, Schema, ...) new entries will appear
    in file "logtemp:compile-log" of default domain. If you can see vever ending compile activities in that file, then your
    XSL Cache Size is configured too small and you should try to increase that value.


    Here is the SOMA script you can use to manually flush an XML Manager's stylesheet cache completely.
    You have to specify the domain and the XML manager name.
    But handle with care! Huge recompilation activities may be the result when traffic triggers the recompilations.
     

    $ doSoma admin FlushStylesheetCache.xml datapower1.boeblingen.de.ibm.com:6543
    Enter host password for user 'admin':
    <?xml version="1.0" encoding="UTF-8"?>
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><dp:response xmlns:dp="http://www.datapower.com/schemas/management"><dp:timestamp>2013-06-29T12:21:55+02:00</dp:timestamp><dp:result>
                            OK
                        </dp:result></dp:response></env:Body></env:Envelope>$
    $
    $ cat FlushStylesheetCache.xml
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
      <env:Body>
        <dp:request domain="speak.js"
          xmlns:dp="http://www.datapower.com/schemas/management"
        >
          <dp:do-action>
            <FlushStylesheetCache>
              <XMLManager>default</XMLManager>
            </FlushStylesheetCache>
          </dp:do-action>
        </dp:request>
      </env:Body>
    </env:Envelope>
    $


    Hermann<myXsltBlog/> <myXsltTweets/> <myCE/>