[Engine-devel] Introducing Infinispan cache and some required actions after change

Yair Zaslavsky yzaslavs at redhat.com
Tue Apr 23 07:45:47 UTC 2013



----- Original Message -----
> From: "Michael Kublin" <mkublin at redhat.com>
> To: "engine-devel" <engine-devel at ovirt.org>
> Sent: Tuesday, April 23, 2013 10:30:09 AM
> Subject: [Engine-devel] Introducing Infinispan cache and some required	actions after change
> 
> Hi All,
> The following commit I2fbebb10c08c87d2c7fd4d7443d3e3b374541ed7 will introduce
> a in memory cache inside ovirt-engine
> The cache which was chosen is infinispan (http://www.jboss.org/infinispan/)
> The reasons are following: cache has all required functionality, it is open
> source project and has built-in integration with
> JBOSS, all cache configuration can be accessed or edited via JBOSS admin
> console.
> 
> By introducing this commit the first stage is finished:
> 1. Cache implementation is added to project
> 2. Show example how to add and use a cache in ovirt-engine, if it is required
> 3. Solved bug with possible memory leak in audit log event
> 
> The next stages are:
> 1. Second stage - replace all custom made implementation by standard central
> cache implementation
> 2. Third stage - introduce second level cache for work with DB
> 3. Fourth stage (Future) - make cluster wise cache or make cache as service,
> if we will have more than one instance of JBOSS
> 
> Now, after the applying the following commit
> I2fbebb10c08c87d2c7fd4d7443d3e3b374541ed7, everyone who works with
> ovirt-engine
> will be required to perform the following operation
> 1. Run mvn clean install -Pdep,setup in order to replace an old
> standalone.xml with new version of it
> Or
> 1. Use regular deploy: mvn clean install -Pdep
> 2. Access to $JBOSS_HOME/bin/standalone.xml and replace or add infinispan
> subsystem:
>         <subsystem xmlns="urn:jboss:domain:infinispan:1.1"
>         default-cache-container="ovirt-engine">
>             <cache-container name="ovirt-engine" default-cache="timeout-base"
>             jndi-name="java:jboss/infinispan/ovirt-engine" start="EAGER">
>                 <local-cache name="timeout-base">
>                     <transaction mode="NONE"/>
>                     <eviction max-entries="10000"/>
>                     <expiration interval="60000"/>
>                 </local-cache>
>             </cache-container>
>         </subsystem>
> 3. Add or check that exists <extension
> module="org.jboss.as.clustering.infinispan"/>  under <extensions> element

Great!
Minor addition -
For those of you who are familiar with the term "region" (exists at JBoss Cache, and IIRC ehcache) - look at the configuration Michael provided for "timeout-base".
Infinspan supports transactions (see the "transaction-mode") and supports distribution (currently at local mode - see the "local-cache" definition).


Yair
> 
> Thanks and Regards Michael
> _______________________________________________
> Engine-devel mailing list
> Engine-devel at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/engine-devel
> 



More information about the Devel mailing list