Enterprise-class Java applications by clustering the JVM with Terracotta
Of all tech meetings I attend, NovaJUG’s are the most difficult for me to follow. I have decided just to reproduce my notes from the presentation. I hope my programmer readers will find them useful.
Ari Zilka presented on Terracotta’s clustering technology. Some highlights:
- Zilka said he believes Terracotta is the first to use transparent clustering at a high level.
- Clustering is not about shared memory
- Terracotta’s code is free, it is supported by a subscription service.
- cluster is above Java Virtual Machine and below the application
- clustering in runtime offers more control
- Terracotta 2.2 is due for release on December 4
Here Zilka made a demonstration of Terracotta with two Macs where two users moved images/objects on the screen simultaneously.
Zilka made some general observations about Java technology:
- Java specification is good; Java uses a strict & valuable set of semantics
Concerning Java serialization:
- language should work the way we were taught in the book
- object identity and pass-by reference
- coordination between threads
- return same reference to same object: map dot put = map dot get
- with serialization objects are moved across applications, you lose trust
- Terracotta clusters at runtime
- stateless programming - because operators can shut down neatly
- load balancing is good; but balancing at application level consistently is best
- with Terracotta you can write to stateful and run in statelessness
- managed runtimes relieve developers (example, memory management)
- Why runtime management is better, you can see patterns of activity, example, who accesses what information and how often they access it
- Terracotta put (serialization) get (deserialization)
- serialization perturbs the domain model
How API based clustering impacts simplicity
-scale out solutions relay on Java serialization
- perturbs the domain model
- adds new coding rules
Locality of reference
- database object not local for processor
- if an object can move then one must map
- must be able to lock object
Terracotta
- handles the getting and putting in the map
- you can trust equality
- no API
- almost no code
Terracotta instrumentation
- map level memory, read/write operations
- network based clustering with consistency
- transparent to business logic
- Bytecode instrumentation
AOP style control; does anyone have this object before I create it and if so, what is the address?
- no peer to peer in Terracotta
- Control cluster server knows who has the lock
- clustering to the heap
Capabilities
- heap level replication - share object
- ACID Replicators - no new exception or error scenarios
- central storage - keeps application state across restarts
- communications hub - manage shared objects
- virtual memory
- coordination
- stateful applications/stateless server
- Terracotta saves each field of each object
- JBoss is not ACID compliant; Terracotta is
- Terracotta shell servlets invoke Java for you
- stateless - kill any node - and still pick up where I left off
- logical extension of your heap
- Hub & Spoke -> scale the hub
- field level changes -> batched
- network overload -> runtime optimized
- Terracotta should be used with Hotspot 1.4 or 1.5, it works with Tomcat, WebLogic, Spring, and Weflow
No comments:
Post a Comment