3 Replies Latest reply on Nov 29, 2006 9:27 AM by Manik Surtani

    Monitoring puts and evictions

    fake fake Newbie

      Hey all,

      I am trying to devise a way to montior puts and expires. When i put a new node on the tree, i use put(fqn, key, value) - each node contains only one key/value pair. I use the LRU eviction policy.

      What i would like to have a listener able to monitor the adds and evictions of the cache, with access to the data objects. I tried using TreeCacheListener but it seems the nodeCreated and nodeEvicted callbacks are signaled too early and too late, respectively. This means the key/value mapping either doesn't exist yet, or the entire node is gone.

      Does anyone have any ideas on how I can accomplish my goal? I was thinking about tacking on a custom interceptor to the chain - do you think this would work?