Hitachi Vantara Pentaho Community Forums
Results 1 to 6 of 6

Thread: flushing the cache from a jsp or an xaction

  1. #1
    Join Date
    Apr 2007
    Posts
    21

    Post flushing the cache from a jsp or an xaction

    Hi,

    is it possible to flush the mondrian cache from an xaction, so that you can i.e. flush it before calling an action creating a pivot table.

    You can probably also add a link or button to pivot.jsp and then call mondrian.rolap.cache.CachePool.instance().flush();

    What is the best/easiest solution? Does someone have an example of flushing the cache from a jsp or an xaction? Or can you configure this in mondrian.properties?

    Thanks!

  2. #2
    Join Date
    May 2006
    Posts
    104

    Default

    There's two xactions under the admin folder in the 1.6.0 PCI that do what you're looking for:

    clear_mondrian_data_cache.xaction and clear_mondrian_schema_cache.xaction.
    Ralph

  3. #3
    Join Date
    Apr 2007
    Posts
    21

    Smile Thanks

    This is what I was looking for.

    Danke!
    Jan

  4. #4
    Join Date
    Jan 2007
    Posts
    485

    Default flushing the cache from a jsp or an xaction

    Quote Originally Posted by rlance View Post
    There's two xactions under the admin folder in the 1.6.0 PCI that do what you're looking for:

    clear_mondrian_data_cache.xaction and clear_mondrian_schema_cache.xaction.
    I am using an older version of the PCI (V1.2.0 build 534 GA)... I have 2 questions...:

    1) can I use the referenced xaction in older versiones of the PCI?
    2) Besides the above, is their any way to "initiate" an xaction to include a statement /instruction to clear the cache?

    My problem is that I have some 10+ different cubes, but after running the 1st pivot, subsequent running of "other" cubes (even those not using the same mondrian cube) something still remains in the cache, which does not allow correct display of new requested pivots.

    Any help in this matter will be highly appreciated.

    DMurray3

  5. #5
    Join Date
    May 2006
    Posts
    104

    Default

    I don't know of any possibility in the earlier Pentaho version. We too use the 1.2 version still and have not found a good solution for the cache problem. I'm trying to convince management to upgrade, but we have customers with very old servers that can't use java 1.5+, so it's more than just installing Pentaho for them.

    Regarding calling xactions from xactions, for the cache clearing in 1.6 I don't thnik you need to, one would use 'script'. Somewhere, I remember reading that one xaction can call another, but I haven't actually treid it, sorry.
    Ralph

  6. #6
    Join Date
    Jan 2007
    Posts
    485

    Default Further on: flushing the cache from a jsp or an xaction

    Thanks rlance...

    I copied the files for clear_mondrian_data_cache.xaction and clear_mondrian_schema_cache.xaction to my PCI (V1.2.0 build 534 GA) and further modified one of my PivotView xactions, to include clear_mondrian_data_cache. This "apparently"does work (each time I run my modified PivotView e PCI log lists the sql statements mondiran is generating ....) and of course using this has the drawback of affecting the "speed-of-thought" with which the PivotView is finally displayed.

    Notwithstanding the above, when running two different pivot-views consecutively (the first with the clear_schema_cache embedded in the pivot-view xaction, the second without the "clear_.."), the second pivot-view (still in some cases) inherits some of the chart properties of the first pivot-view (fie example, axis lables), regardless of the fact that both pivot-view xactions have these properties set in the respective XML. I understand this to be becasue the chart properties of the first pivot-view statyed -to some extent- cached and the second pivot-view uses those...

    So now my effort is to understand what each of these "clear" xactions do; when it is better to use to clear_mondrian_data_cache vs. clear_mondrian_schema_cache, i.e. in order to achieve a correct "refreshing" of information/settings while sacrifycing at a mimimun the speed-of-thought.

    Any ideas will be greatly appreciated.

    By the way, I included the "clear_.." xaction in my pivot-view xaction, using the Design Studio, by adding an "Execute - Pentaho BI Process" in the pivot-view xaction's Process Actions (see image enclosed) and provided the name and location of the "clear_..." xaction.

    DMurray3
    Last edited by DMurray3; 02-21-2008 at 10:39 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.