org.elasticsearch.cluster.block
Class ClusterBlocks

java.lang.Object
  extended by org.elasticsearch.cluster.block.ClusterBlocks

public class ClusterBlocks
extends java.lang.Object

Represents current cluster level blocks to block dirty operations done against the cluster.


Nested Class Summary
static class ClusterBlocks.Builder
           
 
Field Summary
static ClusterBlocks EMPTY_CLUSTER_BLOCK
           
 
Method Summary
static ClusterBlocks.Builder builder()
           
 boolean disableStatePersistence()
          Returns true if one of the global blocks as its disable state persistence flag set.
 org.elasticsearch.common.collect.ImmutableSet<ClusterBlock> global()
           
 org.elasticsearch.common.collect.ImmutableSet<ClusterBlock> global(ClusterBlockLevel level)
           
 boolean hasGlobalBlock(ClusterBlock block)
           
 boolean hasIndexBlock(java.lang.String index, ClusterBlock block)
           
 boolean indexBlocked(ClusterBlockLevel level, java.lang.String index)
           
 ClusterBlockException indexBlockedException(ClusterBlockLevel level, java.lang.String index)
           
 void indexBlockedRaiseException(ClusterBlockLevel level, java.lang.String index)
           
 org.elasticsearch.common.collect.ImmutableMap<java.lang.String,org.elasticsearch.common.collect.ImmutableSet<ClusterBlock>> indices()
           
 org.elasticsearch.common.collect.ImmutableMap<java.lang.String,org.elasticsearch.common.collect.ImmutableSet<ClusterBlock>> indices(ClusterBlockLevel level)
           
 ClusterBlockException indicesBlockedException(ClusterBlockLevel level, java.lang.String[] indices)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMPTY_CLUSTER_BLOCK

public static final ClusterBlocks EMPTY_CLUSTER_BLOCK
Method Detail

global

public org.elasticsearch.common.collect.ImmutableSet<ClusterBlock> global()

indices

public org.elasticsearch.common.collect.ImmutableMap<java.lang.String,org.elasticsearch.common.collect.ImmutableSet<ClusterBlock>> indices()

global

public org.elasticsearch.common.collect.ImmutableSet<ClusterBlock> global(ClusterBlockLevel level)

indices

public org.elasticsearch.common.collect.ImmutableMap<java.lang.String,org.elasticsearch.common.collect.ImmutableSet<ClusterBlock>> indices(ClusterBlockLevel level)

disableStatePersistence

public boolean disableStatePersistence()
Returns true if one of the global blocks as its disable state persistence flag set.


hasGlobalBlock

public boolean hasGlobalBlock(ClusterBlock block)

hasIndexBlock

public boolean hasIndexBlock(java.lang.String index,
                             ClusterBlock block)

indexBlockedRaiseException

public void indexBlockedRaiseException(ClusterBlockLevel level,
                                       java.lang.String index)
                                throws ClusterBlockException
Throws:
ClusterBlockException

indexBlockedException

public ClusterBlockException indexBlockedException(ClusterBlockLevel level,
                                                   java.lang.String index)

indexBlocked

public boolean indexBlocked(ClusterBlockLevel level,
                            java.lang.String index)

indicesBlockedException

public ClusterBlockException indicesBlockedException(ClusterBlockLevel level,
                                                     java.lang.String[] indices)

builder

public static ClusterBlocks.Builder builder()