Overview
GigaSpaces allows J2EE developers to solve integration problems and improve performance and distribution of J2EE applications. GigaSpaces offers a large set of J2EE solutions and patterns, including caching, messaging, parallel processing, load-balancing and integration, all based on one common technology – the space. The common platform enables rapid, simple development, as well as easy management of J2EE applications using a single set of tools.
An Alternative to Entity Beans
Expand this...
Current implementations of Entity Beans (CMP or BMP) suffer from performance problems and low concurrency abilities because of a multi-layered implementation, inefficient mapping, and the lack of a strong caching mechanism. It is also difficult to share Entity Beans information with non-J2EE applications. These limitations create bottlenecks that hamper scalability and performance, and prevent true separation between the object model and the persistent model.
GigaSpaces provides a fast Object Store, seamlessly integrated with any RDBMS in a way that releases bottlenecks without compromising either performance or reliability. GigaSpaces can be used either as the persistent store for Entity Beans (currently through BMP) or as a high-performance alternative to Entity Beans.
For example, a session bean can store its persistent information in the space. The information stored in the space remains in shared memory, and can also be persisted to a backend RDBMS (e.g. Oracle, DB2, MSSQL, MySQL, Cache, PointBase). GigaSpaces provides built-in persistency that maps the objects stored in the space into a full relational representation (see Database Cache and Persistency).
Passive/Active Caching
GigaSpaces enables two caching modes for J2EE: passive caching, which caches information on demand, and active caching which actively pushes relevant information to a local cache, using replication.
Passive Caching
Expand this...
Passive Caching is designed for result caching and reuse of information such as files and user profiles. A leasing and expiration mechanism serves as a 'garbage collector'. This caching mode is most useful in read-mostly or single-server scenarios.
One possible cache implementation consists of a local cache, which is an embedded space runnin within the J2EE container's JVM process, and a master cache, which is a remote space. The application first attempts to access information from its local cache, and if it doesn't find it, tries to load from the master cache. If the information is not in the master cache, it is loaded from the remote data source and stored both in the master and local cache. Subsequent requests to this data item are read from the local cache.
Other local cache instances can share the loaded information from the master cache. Updates on the cache instances are propagated from the master cache to all the other cache instances; updates may be configured in a push or pull mode.
Active Caching
Expand this...
In a highly distributed organization, with multiple servers communicating over a LAN or WAN, it is often necessary to synchronize shared information in near-real-time to maintain a consistent view across organizational units. Active caching can overcome this problem, by providing a single point of access to distributed information, and maintaining last-mile caching services that cache the relevant content close to the application.
When a modification is made by one of the applications participating in the same caching service, the caching service ensures that all local caches in other servers are updated with the change, and if not, it voids the cached object. This is done using GigaSpaces' content-based replication technology.
Each site can maintain a local space that caches relevant information. Updates are propagated transparently to all relevant sites through the replication channel. Unlike a typical messaging solution, the space not only passes the information in a reliable manner, but also controls the state and consistency of the information itself.
Unlike database replication solutions, the space supports extremely sophisticated replication policies, controlling who should see which content and when. It also removes the dependency on a specific database solution: Each site can maintain cached information in a separate database or, if the information is transient, even without a database.
Real-Time Integration for J2EE Applications
Integrating J2EE applications with other systems is a well-known problem. The GigaSpaces solution is based on a data-sharing approach: Applications integrate with each other by sharing and exchanging information through a common data store.
Expand this...
In the past, this technique was based on database solutions, and was mainly applicable to scenarios with a high level of sharing and consistency is relatively high. The performance overhead was also considered to be high. In contrast to database solutions, GigaSpaces creates a high-speed, shared memory bus between the J2EE application and other applications.
With this type of integration, a J2EE application is integrated with other J2EE and non-J2EE applications, by passing and sharing data through the space. Proxies enable access to the shared information by other platforms and languages such as C++, .Net, and web services. This enables real-time integration, since both sides share exactly the same information without any transformation.
Grid Engine
A J2EE application that performs complex tasks often suffers from an inability to utilize existing system resources, both internal (within the container) and external (in the network environment). GigaSpaces provides a light grid engine that enables:
Expand this...
- Utilization of system resources – J2EE applications gain access to distributed system resources, such as CPU and memory, improving their scalability and performance. The space coordinates and synchronizes access to the distributed resources to ensure reliable processing.
- Parallel processing – the GigaSpaces parallel-processing engine enables J2EE developers to improve application performance. When J2EE logical components require several tasks to be processed in parallel, and the results to be collected as they arrive, GigaSpaces tools enable reliable, recoverable, and guaranteed execution of the tasks in parallel.
For example, consider a J2EE application that needs performs a parallel task using a master-worker pattern. The J2EE session bean is the master application and a set of generic workers represents the processing units. The session bean performs a parallel job by writing a set of tasks into the space. Workers take these tasks in their idle time and execute them in the worker environment. In this way, the workers utilize their machine CPU and memory resources on behalf of the master session bean. Upon completion, the workers write results back to the space, the master takes the results and compiles them into a unified job result, which is sent back to the application.
|
Section Contents
|
Add Comment