Infinispan - Open Flamingo Confluence

eyelashesnectarineSoftware and s/w Development

Nov 3, 2013 (3 years and 7 months ago)

145 views

Infinispan

Preface


Benefits
of a data grid
solution


Infinispan

as a data
grid


Infinispan

as a
cache


Infinispan

operational modes


Start
Infinispan

Server


Eviction and expiration


Listeners


Transactions


Using
Infinispan

Core
API


Global configuration
settings


Cache configuration settings


Configuring cache loaders


Specific cache loader attributes


Cache loaders and
stores


Demo

Configuration

WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Preface

WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



대용량

트랜잭션


WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



대용량

트랜잭션


고가용성

WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



대용량

트랜잭션


고가용성

확장성

WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



대용량

트랜잭션


고가용성

확장성

SPOF

WEB Server

WAS Server

Database

WEB Server

WAS Server

Database

L4 switch

Internet

Client

Client

Client

Client

Client

Client

Client

Client

Client

Client



대용량

트랜잭션


고가용성

확장성

SPOF

데이터

공유



분배

Data Grid


활용한


고가용성



확장성

제공

https://
docs.jboss.org
/author/display/ISPN/
Infinispan+Server+Modules

Large data set

(
대용량

데이터


)

Designed to read and distribute
huge sets of data

across a set of
servers communicating over a network, forming a cluster.

Heterogeneity

(
이질성
)

T
he
software
and
hardware
points of view.

Diverse
platforms
and
storage
systems.

Scalability

(
확장성
)

Optimized to
scale out
.

Infinispan

(open source data grid)

w
ritten in
Java

Benefits of a data grid solution

By
automatically

and

dynamically

partitioning

(
데이터

분할
)


the
data

in memory across multiple servers,



enables continuous
data

availability

(
데이터

가용성
)



and
transactional

integrity

(
트랜잭션

무결성
)
,

even in the event of server failure.

Infinispan

as a data grid

Java Specification Request (JSR
-
107)

JSR
-
107 has been created

to define a temporary caching API for the java platform.

Javax.cache.Cache

interface for
distributed environments
.

CacheLoader

interface
for loading/storing cached data
.

Cache instances can
be retrieved
using a
CacheManager
.


Infinispan

exposes a JSR
-
107

Cache interface
in which you can
store data
,

a
nd
enhances

it

By
providing additional APIs and features
.

Infinispan

as a cache

Embedded
mode

Infinispan

within
the same JVM
as your application

(
for example,
the applications
deployed on
Jboss

Application
Server are able to interact with
an
Infinispan

instance
that is
embedded
in the application server
)


Client
-
server
mode

a
remote
Infinispan

instance

and connect to it using a variety of
different protocols

Infinispan

operational modes

Embedded mode

Server
-
Client mode

as a cache

as a
server

ex)
Jboss

AS
:

to cluster
-
enable
your
application

by
delegating state
management

connecting to it from a
variety of different clients

Start
Infinispan

Server

Bryan
-
ui
-
MacBook
-
Pro:bin

oopchoi
$ ./
startServer.sh

-
r hotrod

use the
startServer

script located in the
bin

folder of your
distribution.

Which
can be either

memcached

or

hotrod


2013
-
06
-
02 13:26:23,976 INFO (main) [
org.infinispan.server.core.Main
$] ISPN005001: Start main with
args
:
-
r, hotrod

2013
-
06
-
02 13:26:24,187 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.util.ModuleProperties
] Loading lifecycle SPI class: org.infinispan.server.memcached.LifecycleCallbacks@12c063ad

2013
-
06
-
02 13:26:24,188 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.util.ModuleProperties
] Loading lifecycle SPI class: org.infinispan.server.hotrod.LifecycleCallbacks@56e2ecc7

2013
-
06
-
02 13:26:24,214 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.util.ModuleProperties
] Loading lifecycle SPI class: org.infinispan.cli.interpreter.LifecycleCallbacks@64bef361

2013
-
06
-
02 13:26:24,217 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.util.ModuleProperties
] Loading lifecycle SPI class: org.infinispan.server.core.LifecycleCallbacks@57d840cd

2013
-
06
-
02 13:26:24,323 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.util.ModuleProperties
] No module command extensions to load

2013
-
06
-
02 13:26:24,408 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.manager.DefaultCacheManager
] Started cache manager ISPN on null

2013
-
06
-
02 13:26:24,425 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.server.hotrod.HotRodServer
] Starting server with basic settings: host=127.0.0.1, port=11222,
masterThreads
=
-
1,
workerThreads
=4,
idleTimeout
=
-
1,
tcpNoDelay
=true,
sendBufSize
=0,
recvBufSize
=0

2013
-
06
-
02 13:26:24,683 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.interceptors.InterceptorChain
] Interceptor chain size: 6

2013
-
06
-
02 13:26:24,683 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.interceptors.InterceptorChain
] Interceptor chain is:


>>
org.infinispan.interceptors.InvocationContextInterceptor


>>
org.infinispan.interceptors.CacheMgmtInterceptor


>>
org.infinispan.interceptors.NotificationInterceptor


>> org.infinispan.interceptors.locking.NonTransactionalLockingInterceptor


>>
org.infinispan.interceptors.EntryWrappingInterceptor


>>
org.infinispan.interceptors.CallInterceptor

2013
-
06
-
02 13:26:24,694 DEBUG (
InfinispanServer
-
Main) [
org.infinispan.CacheImpl
] Started cache ___
defaultcache

on null

bin/
infinispan.log

memcached

protocol

Hot
Rod protocol

consistent hash algorithm

scalability, high
availability

When
one node of the
cluster fails, even if its data
is preserved, you need to
manually update the list of
server nodes on your
clients.

The protocol allows for clients
to be built to take advantage

of dynamic load balancing and
failover.

Hot
Rod clients can
automatically detect changes

in the topology of Hot Rod
servers.

eviction

expiration

To prevent your application
from running out of
memory.

The maximum number of
entries
that are allowed in
memory
.

To attach
lifespan
and/or
maximum idle times

to
entries.

When entries expire, they
are not
passivated

like
evicted entries,

even if passivation is
enabled

<
infinispan
>


<
namedCache

name="
evictionCache
">


<eviction


maxEntries
="1000"


strategy="
LRU”

/
>


<expiration


wakeUpInterval
="500"


lifespan="60000"


maxIdle
="
10000”

/
>


<loaders passivation="true">


<loader



class
="
org.infinispan.loaders.file.FileCacheStore
">


<properties>


<property name="location"



value
="${
java.io.tmpdir
}"/>


</properties>


</loader>


<
/loaders>


</namedCache>


</infinispan>

Eviction and expiration

Listeners

-

cache

:

adding
or removing entries from the cache
.

-

cache manager

:

startup
/shutdown of the cache



or
topology change in the cluster
.

events

must be
public
,

return

a
void
,

parameter

representing the
event type
.

CacheStarted

CacheStopped


CacheEntryModified


CacheEntryCreated


CacheEntryRemoved


CacheEntryVisited


CacheEntryLoaded


CacheEntriesEvicted


CacheEntryActivated


CacheEntryPassivated


ViewChanged


TransactionRegistered


TransactionCompleted


CacheEntryInvalidated


synchronously

(default)

리스너에서

피해야



작업

-
오랜

시간을

필요로

하는

작업

-
다른

쓰레드를

블럭할만한

작업

@Listener(sync = false)

public
class
SimpleListener

{


... .

}

비동기화

Transactions

When a cache is started, it
registers(1)

itself with the
TransactionManager
.


When
you need to
demarcate(2)
(
경계를

정하다
)
a JTA transaction
, your application
will use
TransactionManager

(usually by obtaining
UserTransaction

from
JNDI
, if using a
Java EE environment
) and
begin

Transaction
(3)
, so that the current transaction is
associated with the running thread.

a
commit or a
rollback(4)
,
and this is propagated up to
TransactionManager

, which
will
prepare the
XA(5)
resources for
commit or
rollback(6)
.

Configuration

CacheManager

manager = new
DefaultCacheManager
("
config
-
file.xml
");

global (
모든

캐시

인스턴스
)

the
global settings
shared among all cache instances
created

by
a single cache manager
.


default

(
모든

Named

캐시

인스턴스
)


the default behavior for
all the named
caches
belonging to this cache manager


namedCache

(
특정

Named

캐시

인스턴스
)

additional
configuration
elements for
specific named caches
,

and
will

extend what is defined in default

<global>


<
asyncListenerExecutor

factory=


"
org.infinispan.executors.DefaultExecutorFactory
">


<properties>


<property name="
maxThreads
" value="5"/>


<property name="
threadNamePrefix
"


…..

global

default/named

Global

configuration settings

-

thread pools

-

serialization

-

network
data transport

Element

Description

asyncListenerExecutor


Configures the executor service used to
emit
notifications
to
asynchronous listeners

asyncTransportExecutor


Configuration for the executor service used for
asynchronous work on the transport
, including
asynchronous
marshalling

and
cache
async

operations

such as
Cache.putAsync
()

evictionScheduledExecutor


Configuration for the scheduled executor service
used
to periodically run eviction cleanup tasks.

replicationQueueSchedule
dExecutor


Configuration for the scheduled executor service
used

to periodically flush replication queues
;
used if
asynchronous clustering is enabled
along
with
useReplQueue

being set to
true

Element

Description

globalJmxStatistics


This element specifies whether

global statistics(
통계
)

are
gathered and reported

via
JMX

for
all caches
under
this cache manager
.

transport

This element configures the transport used
for
network communications across the cluster

serialization

Configures
serialization

and

marshaling

settings

shutdown

This element specifies
behavior when the JVM
running the cache instance shuts down

serialization and marshaling

객체를

파일에

저장함으로써

영속성을

제공

객체

자체를

네트워크를

통하여

손쉽게

교환

가능

JMX(Java Management
eXtensions
)


응용

프로그램

소프트웨어
/
객체
/
장치

(
프린터


)


서비스

지향

네트워크

등을

감시

관리를

위한

도구를

제공하기

위한

자바

API
이다
.
이러한

리소스는

MBean
(Managed Bean)
이라는

객체로

표현된다
.

<global>



<
asyncListenerExecutor

factory
="
org.infinispan.executors.DefaultExecutorFactory
">


<properties>


<property name="
maxThreads
" value="5"/>


<property name="
threadNamePrefix
” value
="
AsyncListenerThread
"/>


</properties>


</
asyncListenerExecutor
>

</global>

Infinispan

listeners,
by default, are
synchronous

you can alter this
behavior by
setting the
sync = false

@Listener (sync = false)

public
class
MyAsyncListener

{
.... }

asyncListenerExecutor


<global>



<
asyncTransportExecutor




factory
= "
org.infinispan.executors.DefaultExecutorFactory
"
>





<
properties>



<
property name="
maxThreads
" value="25"/>



<
property name="
threadNamePrefix
" value="
AsyncSerializationThread
"/>



<
/properties>



<
/
asyncTransportExecutor
>

</global>

if you intend to
use the
non
-
blocking
,
asynchronous API
, or

if
you have configured your
cluster to use asynchronous
communications

asynchronous work on
the transport
, including
asynchronous
marshalling

and
cache
async

operations

such as
Cache.putAsync
()

asyncTransportExecutor

<global>



<
evictionScheduledExecutor




factory
= "
org.infinispan.executors.DefaultScheduledExecutorFactory
">



<
properties>



<
property name="
threadNamePrefix
" value="
EvictionThread
"/>



<
/properties>



<
/
evictionScheduledExecutor
>

</global>


this
can
be
used
,

if you have
eviction enabled
and wish to
customize the executor
used

by the
eviction and expiration process

evictionScheduledExecutor


<global>



<
globalJmxStatistics




enabled
="true"



jmxDomain
="
org.infinispan
"



cacheManagerName
="
SampleCacheManager
"/>

</global>

enables the collection of global JMX
statistics
.

allows you to
customize the JMX domain name
under
which
MBeans

are
registered
.


globalJmxStatistics

<global>



<transport



clusterName

= "
MyCluster
"



machineId

= "LinuxServer01"



rackId

= "Rack01"



siteId

= "Western
-
Europe" />



<
/transport>

</global>

-

clusterName

:

only
connect
to clusters sharing
the same
name
.

-

machineId

:
This can be useful to
disambiguate

between
multiple
JVM



instances
on the
same node
, or even
multiple virtual hosts



on
the same physical
host
.

-

rackId

: this
setting would help
prevent backups being stored


on
the
same rack

-

siteId

:
differentiate
between nodes in different data centers
,


replicating
to each other

transport

<
infinispan
>



<
default>



<
eviction strategy="LRU"
maxEntries
="2000"/>



<
/default>

<
/
infinispan
>

<
infinispan
>



<
namedCache

name="
evictionCache
">



<
eviction strategy="LIRS"
maxEntries
="2000"/>



<
/
namedCache
>

<
/
infinispan
>

default

named

-

cache loaders

-

eviction

-

expiration

-

custom
interceptors

Cache

configuration settings

Cache
defaultCache

=
manager.getCache
();

Cache
evictionCache

=
manager.getCache
("
evictionCache
");

Element

Description

clustering

Defines clustered characteristics of the cache.

customInterce
ptors

Configures custom interceptors to be added to the cache.

dataContainer

Controls the data container for the cache.

deadlockDete
ction

Configures deadlock detection.

eviction

Controls the eviction settings for the cache.

expiration

Controls the default expiration settings for entries in the
cache.

indexing

Configures indexing of entries in the cache for searching.

invocationBat
ching


Defines whether invocation batching is allowed in this cache
instance and sets up internals accordingly, to allow use of this
API.

jmxStatistics


Determines whether statistics are gathered and reported.

Element

Description

loaders

Configuration for cache loaders and stores.

locking

Defines the local, in
-
VM locking and concurrency
characteristics of the cache.

storeAsBinary


Controls whether when stored in memory, keys and values are
stored as references to their original objects, or in a serialized,
binary format.

transaction

Defines transactional (JTA) characteristics of the cache.

unsafe

Controls certain tuning parameters that may break some of
Infinispan's

public API contracts in exchange for better
performance in some cases.

The
mechanism
that
reads

entries
in a Cache
Store
.

when the entry is
not found in memory


<loaders


passivation
="true
"


shared
="false"


preload
="false">

<
/loaders>

Configuring cache
loaders

passivation (default=false)


W
hen
set to
true
, entries that are evicted
are removed from
memory
, and they are
persisted using a cache
store.

If passivation is disabled
, the cache store behaves

as
a
write
-
through cache
, which means that
write is done
synchronously
, both to the cache
and
to the backing store.



default


false
일까요
?

성능을

생각하면

true


좋을



같은데
?

데이터가

유실되는걸

피하고

싶은걸까요
?

1. Insert
keyOne

2. Insert
keyTwo

3. Eviction
thread runs, evicts
keyOne

4. Read
keyOne

5. Eviction
thread runs, evicts
keyTwo

6. Remove
keyTwo

Memory:
keyOne


Disk
:
keyOne

Memory:
keyOne
,
keyTwo


Disk
:
keyOne
,
keyTwo

Memory:
keyTwo


Disk
:
keyOne
,
keyTwo

Memory:
keyOne
,
keyTwo


Disk
:
keyOne
,
keyTwo

Memory:
keyOne


Disk
:
keyOne
,
keyTwo

Memory
:

keyOne


Disk
:
keyOne

Memory:
keyOne


Disk
:

Memory:
keyOne
,
keyTwo


Disk
:

Memory:
keyTwo


Disk
:
keyOne

Memory:
keyOne
,
keyTwo


Disk
:

Memory:
keyOne


Disk
:
keyTwo

Memory:
keyOne


Disk
:

passivation

(false)

passivation

(true)

shared (default=false)


S
hared

among
different cache instances
in the
cluster
.

This is useful in a clustered environment, in order to prevent
repeated and unnecessary writes of the same data to the cache
store, by different cache
instances.

가난하니까

공유해야죠
?

^^;;

preload
(default=false)


when the
cache starts
,
data

stored in the cache loader

will
be
preloaded

into memory
.

Note that preloading is
done per node
.

No
replication or
distribution
of the preloaded data will happen.

캐시가

시작될



스토어에서

메모리로

어떤

데이터를

미리

로딩할까요
?

모든

데이터를

로딩하진

않을



같은데

말이죠
!

<loader


class
="
org.infinispan.loaders.file.FileCacheStore
"


fetchPersistentState
="false"


purgeOnStartup
="false">


<
properties
>


<
property

name="location"


value="${
java.io.tmpdir
}"/>


</
properties
>

<
/loader>

Specific cache
loader

attributes



설정의

예만

봤을



로더는

스토어와

밀접한

관련이

있어

보이는군요
!

class


mandatory
attribute

(the
cache loader implementation
)

a
file
-
based
cache store,
JDBC
-
based

one, one that persists to
cloud storage
engines
, as well as the ability to write
your own implementations
.

class
="
org.infinispan.loaders.file.FileCacheStore
"

로더

설정에서

class


필수로

지정해야

하는군요
!

fetchPersistentState

(default=true)


used
in
a clustered environment
and determines whether to

fetch

the
persistent
state
of a
cache

when joining a cluster
and
performing a state transfer
.

Setting this attribute to
false

will result in a cold cache that
gradually warms up
as
elements are
accessed and loaded for the first time
. This would mean
that
individual caches in a cluster

might have
different in
-
memory states

at any given time

(largely
depending on

their
preloading

and
eviction strategies
).

클러스터

환경에서

하나의

클러스터가

추가

되었을



스토어의

상태를

모으는

작업을

하나

봅니다
.

purgeSynchronously

(default=false)


set
to true, the
eviction thread

will
block

execution
until the purging is finished

otherwise

it will return
immediately
, performing the purging of expired entries in a
separate thread
.



속성

값을

true


지정하면

퍼징이

완료될

때까지

eviction

쓰레드가

블락

되는군요
!

ignoreModifications

(
default=false)


determines
whether
updates are propagated

to the cache store.

If a
store

is to be treated as
read
-
only
,

then
ignoreModifications

should be set to true
.

캐시

스토어에

업데이트를

전달



것인지

여부를

설정합니다
!

스토어가

읽기

전용으로

되어

있다면



속성을

true


지정하라고

합니다
.


읽기

전용

스토어라면

스토어에

저장을





없으니까

업데이트를

무시하고

넘어가도록

명시적으로

설정하도록

권장하는



같습니다
.


만약
,

true


지정하면

eviction
설정을

해도

캐시스토어에

저장되지

않을까요
?

purgeOnStatup



empties

the
specified cache store
(if
ignoreModifications

is false),

when the cache starts up.

캐시가

시작





지정된

캐시

스토어를

비우는



같습니다
.

그런데



속성은

ignoreModifications

설정이

false


때만

의미가

있나

봅니다
.


만약
,

엄청

많은

데이터가

캐시

스토어에

저장되어

있다면

성능에

영향을

미치지

않을까요
?

properties
elements



속성은

하위

엘리먼트를

가지고

있군요
.

property

엘리먼트에는

name


value

속성을

지정하도록

되어

있습니다
.


그런데

가만히

보니까



property
들은

loader

엘리먼트의

class


지정한

클래스에

대한

속성들이었군요
.

<loader


class
="
org.infinispan.loaders.file.FileCacheStore
"


fetchPersistentState
="false"


purgeOnStartup
="false">


<properties>


<
property

name="location"


value="${
java.io.tmpdir
}"/>


</
properties
>

<
/loader>

Cache loaders and stores

-

File
system based cache loaders

-

JDBC
based cache loaders

-

Cloud
cache loader

-

Remote
cache loader

-

Cassandra
cache loader

-

Cluster
cache loader

-

JPA
cache store

-

LevelDB

cache store

-

MongoDB

cache loader

https://
docs.jboss.org
/author/display/ISPN/
Cache+Loaders+and+Stores

Tools

JDK 1.6.0 or above
.

http://www.oracle.com/technetwork/java/javase/downloads/index.html


http://docs.oracle.com/javase/7/docs/webnotes/install/index.html


Apache Maven3.0 or above
.

http://maven.apache.org/download.cgi


IDE(Eclipse or
IntelliJ
)

Infinispan

http://www.jboss.org/infinispan/downloads


Knowledge

Java

Concepts such as data caching and clustering

Sample Code

http://github.com/infinispan/Infinispan
-
book

http://programmingsummaries.tistory.com/
128

(
Git

사용법
)

http://forum.falinux.com/zbxe/index.php?document_srl=533022&mid=
lectur
e_tip

(
Git


)


Install

Install
-

Java, Maven

Bryan
-
ui
-
MacBook
-
Pro:Commands

oopchoi
$ java
-
version

java version "1.7.0_04
-
ea"

Java(TM) SE Runtime Environment (build 1.7.0_04
-
ea
-
b19)

Java
HotSpot
(TM) 64
-
Bit Server VM (build 23.0
-
b20, mixed mode)

Bryan
-
ui
-
MacBook
-
Pro:Commands

oopchoi
$
mvn

-
version

Apache Maven 3.0.3 (r1075438; 2011
-
03
-
01 02:31:09+0900)

Maven home: /
usr
/share/maven

Java version: 1.7.0_04
-
ea, vendor: Oracle Corporation

Java home: /Library/Java/
JavaVirtualMachines
/1.7.0.jdk/Contents/Home/
jre

Default locale:
ko_KR
, platform encoding: UTF
-
8

OS name: "mac
os

x", version: "10.8.3", arch: "amd64", family: "mac"

JAVA_HOME, M2_HOME



add environment variable to your system.

Install
-

Infinispan

folder

bin
/
startServer.sh

Start
Infinispan

in a standalone JVM process

bin/
importConfig.sh

Migrate
Jboss

Cache configurations into the
Infinispan

configuration file

b
in/
runGuiDemo.sh

Test
Infinispan’s

cache using a Java Swing
-
based demo

doc

Contains the
Javadocs

API documentation for
Infinispan

etc

contains the XML schemas for the
Infinispan

configuration file along with some sample
configuration files.

lib

contains some additional libraries that need to be on your
classpath

(or packaged with your
deployment), along with the main library
infinispan
-
core.jar
, which can be located at the root of
the
Infinispan

archive.

modules

contains a number of optional modules (such as the
Infinispan

query module or REST interface).

In order to use them, you will need to add the module’s JAR file and all of its dependencies
(modules/MODULE_NAME/lib) to be on your
classpath
, in addition to
Infinispan’s

JARs.

licenses

contains the licenses for some of the other libraries shipped with the distribution.


Additional modules

Infinispan

has a highly extensible architecture, making it easy to plug in additional extensions.

By default, a set of additional modules are contained in the modules folder of the distribution.

The
cacheStore

module
, for example, allows
Infinispan

to store cached data in a persistent location, such as a
shared JDBC database, a local
filesystem
, among others.

The
hotrod

folder

contains a server module featuring a custom binary protocol for communicating with a
remote
Infinispan

cluster.

(hotrod protocol design : faster c/s interactions, load balancing, failover, data location operations)

Another server endpoint is found in the
memcached

directory
. This allows
memcached

clients to talk to one
or more
Infinispan

servers using the
memcached

wire protocol. (non
-
clustered simple cache)

the
lucene
-
directory folder
contains a highly scalable Apache
Lucene

directory implementation that can be
used to provide reliable index sharing across the cluster.

The
query module
, also making use of Apache
Lucene

in combination with Hibernate Search, adds querying
capabilities to
Infinispan
. This module allows users to search for stored data without access to a specific key.
So, you can now search for your data based on their attributes (for example, the tickets sold in one country).

The
rhq
-
plugin directory

contains libraries that can be use to manage multiple
Infinispan

instances using the
web
-
based, open source RHQ management platform (monitoring both
CacheManager
, Cache instance).

Another addition can be located in the
spring folder
. The libraries contained in this folder allow you to use
Infinispan

as a Spring Cache API instead of the default implementations, which ship with Spring.

Finally, the
tree folder

contains
Infinispan’s

tree API module, which offers clients the possibility of storing data
using a hierarchical (tree
-
like) structured API. This API is similar to the one
proided

by
Jboss

Cache, hence the
tree module is perfect for those users wanting to migrate their applications from
Jboss

Cache to
Infinispan
.

1. Move into the bin folder and execute the
runGuiDemo.sh

script.

2. Once
launched, the GUI will display the following frame:

Testing the installation
with
the GUI Demo

3. In order to get started, hit the Start Cache button, which will



instantiate a cache.

4. Move to the Manipulate data tab. In this tab, you can perform



CRUD operations on the cache, including generating bulk random



inserts. In the following example, we are adding a sample entry in



the cache by filling the Key and Value textboxes and hitting



the Go button.

5. Once added, the Demo GUI will switch automatically to



the Data view tab, which will display the list of entries contained



in the cache.

https://
github.com
/
infinispan
/
Infinispan
-
book

oopchoi
$
git

clone
git
://
github.com
/
infinispan
/
Infinispan
-
book.git

S
et up
IntelliJ

Demo

Question

https://www.facebook.com/groups/infinispan
/


questions@packtpub.com


https://
docs.jboss.org
/author/display/ISPN/Home