Hazelcast

From Wikipedia, the free encyclopedia
Jump to: navigation, search
Hazelcast
Hazelcast logo.png
Developer(s) Hazelcast Team
Stable release 2.5 / December 13, 2012 (2012-12-13)
Development status Active
Written in Java
Operating system Cross-platform
Type In memory data grid
License Apache License 2.0
Website http://www.hazelcast.com/

Hazelcast is an open source, in-memory data grid for Java.

Hazelcast architecture is peer-to-peer. It supports dynamic discovery using multicast or TCP/IP. After discovery, node communication is only TCP/IP using Java NIO.

Contents

Hazelcast Features [edit]

  • Distributed Java data structures (Queue, Set, List, Map, Lock, Topic)
  • Distributed Executor Service
  • Distributed Multimap
  • Support for transactions
  • J2EE container integration via JCA
  • Hibernate 2nd level cache
  • Index and Query support
  • Dynamic clustering, scaling and partitioning
  • WAN (Wide Area Network) Replication
  • Decentralized. Each node in the cluster has the same role.
  • Data is distributed across the cluster (so each node contains different data).

Getting Started [edit]

Following is the sample usage of distributed hash map using Hazelcast.

import java.util.Map;
import java.util.Collection;
import com.hazelcast.core.Hazelcast;
 
Map<String, Person> mapPeople = Hazelcast.getMap("people");
mapPeople.put("1", new Person("Jack"));
mapPeople.put("2", new Person("Avi"));
 
Collection<Person> colPeople = mapPeople.values();
for (Person person : colPeople) {
    // print person
}

See also [edit]

External links [edit]