Package org.infinispan.rest.distribution
Class NodeDistributionInfo
java.lang.Object
org.infinispan.rest.distribution.NodeDistributionInfo
- All Implemented Interfaces:
JsonSerialization
,NodeDataDistribution
@Immutable
@ProtoTypeId(6001)
public class NodeDistributionInfo
extends Object
implements JsonSerialization, NodeDataDistribution
Collect node's information and statistics of the local JVM.
Contains information about the node name and address; the JVM statistics are memory used and available,
all in bytes. We rely on
ClusterContainerStats
to retrieve the JVM values, so if the collector is
disabled, we return -1.- Author:
- José Bolina
-
Constructor Summary
ConstructorDescriptionNodeDistributionInfo
(String name, List<String> addresses, long memoryAvailable, long memoryUsed) -
Method Summary
Modifier and TypeMethodDescriptionlong
long
name()
static NodeDistributionInfo
resolve
(CacheManagerInfo manager, GlobalComponentRegistry registry) toJson()
-
Constructor Details
-
NodeDistributionInfo
-
-
Method Details
-
name
- Specified by:
name
in interfaceNodeDataDistribution
-
addresses
@ProtoField(value=2, collectionImplementation=java.util.ArrayList.class) public List<String> addresses()- Specified by:
addresses
in interfaceNodeDataDistribution
-
memoryAvailable
@ProtoField(value=3, defaultValue="0") public long memoryAvailable() -
memoryUsed
@ProtoField(value=4, defaultValue="0") public long memoryUsed() -
toJson
- Specified by:
toJson
in interfaceJsonSerialization
-
resolve
public static NodeDistributionInfo resolve(CacheManagerInfo manager, GlobalComponentRegistry registry)
-