Configuring object caching

For each entity component that uses automatic persistence, enable object caching on the Persistence/Object Cache subtab in the Component Properties dialog box. The settings are:

StepsCreating a named cache

If you want a cache to be shared by multiple components, finder methods or ejbSelect methods, you must create a named cache as follows:

  1. If the Repository/ObjectCache directory does not exist under your EAServer installation, create it.

  2. Create a text file in the Repository/ObjectCache directory named Cache.props, where Cache is the cache name used in component properties.

  3. Add lines as shown below to configure the cache properties. All properties are optional. If not set, the default values apply:

    com.sybase.jaguar.objectcache.size=size-value
    com.sybase.jaguar.objectcache.timeout=timeout-value
    com.sybase.jaguar.objectcache.sync=sync-method
    

    These values correspond to the component object caching properties, as described in the table below. Each cache property uses the same value syntax as the corresponding component property:

    Named cache property

    Component property

    com.sybase.jaguar.objectcache.size

    Cache Size. If not specified, the default is unlimited.

    com.sybase.jaguar.objectcache. timeout

    Cache Timeout. If not specified, the default is infinity.

    com.sybase.jaguar.objectcache.sync

    Cache Synchronization