public enum ClusterExecutionPolicy extends Enum<ClusterExecutionPolicy>
ClusterExecutor
. That is the user
can ensure that a command goes or doesn't go to a specific physical location such as on the existing machine, rack
or site.
ClusterExecutionPolicy effectively scopes execution of commands to a subset of nodes. For example, someone might want to exclusively execute commands on a local network site instead of a backup remote network centre as well. Others might, for example, use only a dedicated subset of a certain Infinispan rack nodes for specific task execution.
Enum Constant and Description |
---|
ALL
The command can be executed on any node in the cluster
|
DIFFERENT_MACHINE
The command will be executed only on a different machine.
|
DIFFERENT_RACK
The command will be executed on machine on a different rack.
|
DIFFERENT_SITE
The command will be executed on a different site.
|
SAME_MACHINE
The command can be executed only on the same machine from where it was initiated.
|
SAME_RACK
The command will be executed on a machine on the same rack.
|
SAME_SITE
The command will be executed on a machine on the same site.
|
Modifier and Type | Method and Description |
---|---|
abstract boolean |
include(TopologyAwareAddress thisAddress,
TopologyAwareAddress otherAddress) |
static ClusterExecutionPolicy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ClusterExecutionPolicy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ClusterExecutionPolicy ALL
public static final ClusterExecutionPolicy SAME_MACHINE
public static final ClusterExecutionPolicy DIFFERENT_MACHINE
public static final ClusterExecutionPolicy SAME_RACK
public static final ClusterExecutionPolicy DIFFERENT_RACK
public static final ClusterExecutionPolicy SAME_SITE
public static final ClusterExecutionPolicy DIFFERENT_SITE
public static ClusterExecutionPolicy[] values()
for (ClusterExecutionPolicy c : ClusterExecutionPolicy.values()) System.out.println(c);
public static ClusterExecutionPolicy valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic abstract boolean include(TopologyAwareAddress thisAddress, TopologyAwareAddress otherAddress)
Copyright © 2018 JBoss, a division of Red Hat. All rights reserved.