Class PdoCache

java.lang.Object
org.wurbelizer.wurblet.AbstractWurblet
org.wurbelizer.wurblet.AbstractJavaWurblet
All Implemented Interfaces:
org.wurbelizer.wurblet.Wurblet

public class PdoCache extends DbModelWurblet
(@wurblet) Generate code for setting up a PdoCache for an entity.

usage:
@wurblet <tag> PdoCache [--secure] [--preload] [--mutable] [--udk] [--strategy=LRU|LFU|FORGET] [--maxsize=<n>] [--keepquota=<p>] [--configure=<method>] [index1] [index2] ...

arguments:

  • --secure: if cache must check read permission for each access (default is no check).
  • --preload: the first access will load all entities at once.
  • --mutable: generates a non-shared cache, i.e. mutable PDOs (by default a shared readonly cache is generated).
  • --udk: add index for the unique domain key.
  • --strategy=LRU|LFU|FORGET: the caching strategy (default is FORGET).
  • --maxsize=<n>: the cache size (if not preloaded).
  • --keepquota=<p>: percentage of entries to keep when applying caching strategy. Default is 50.
  • --configure=<method>: an optional method to further configure the cache.
  • --index<n>: additional unique indexes. By default, only the ID-index will be created.
For more options, see DbModelWurblet.
  • Constructor Details

    • PdoCache

      public PdoCache()
  • Method Details

    • run

      public void run() throws org.wurbelizer.wurbel.WurbelException
      Specified by:
      run in interface org.wurbelizer.wurblet.Wurblet
      Overrides:
      run in class DbModelWurblet
      Throws:
      org.wurbelizer.wurbel.WurbelException