Class DiscoveryNodeFilters

java.lang.Object
org.elasticsearch.cluster.node.DiscoveryNodeFilters

public class DiscoveryNodeFilters
extends java.lang.Object
  • Nested Class Summary

    Nested Classes
    Modifier and Type Class Description
    static class  DiscoveryNodeFilters.OpType  
  • Field Summary

    Fields
    Modifier and Type Field Description
    static java.util.function.BiConsumer<java.lang.String,​java.lang.String> IP_VALIDATOR
    Validates the IP addresses in a group of Settings by looking for the keys "_ip", "_host_ip", and "_publish_ip" and ensuring each of their comma separated values that has no wildcards is a valid IP address.
  • Method Summary

    Modifier and Type Method Description
    static DiscoveryNodeFilters buildFromKeyValue​(DiscoveryNodeFilters.OpType opType, java.util.Map<java.lang.String,​java.lang.String> filters)  
    boolean match​(DiscoveryNode node)  
    java.lang.String toString()
    Generates a human-readable string for the DiscoverNodeFilters.
    static DiscoveryNodeFilters trimTier​(DiscoveryNodeFilters original)
    Removes any filters that should not be considered, returning a new DiscoveryNodeFilters object.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • IP_VALIDATOR

      public static final java.util.function.BiConsumer<java.lang.String,​java.lang.String> IP_VALIDATOR
      Validates the IP addresses in a group of Settings by looking for the keys "_ip", "_host_ip", and "_publish_ip" and ensuring each of their comma separated values that has no wildcards is a valid IP address.
  • Method Details

    • buildFromKeyValue

      public static DiscoveryNodeFilters buildFromKeyValue​(DiscoveryNodeFilters.OpType opType, java.util.Map<java.lang.String,​java.lang.String> filters)
    • trimTier

      @Nullable public static DiscoveryNodeFilters trimTier​(@Nullable DiscoveryNodeFilters original)
      Removes any filters that should not be considered, returning a new DiscoveryNodeFilters object. If the filtered object has no filters after trimming, null is returned.
    • match

      public boolean match​(DiscoveryNode node)
    • toString

      public java.lang.String toString()
      Generates a human-readable string for the DiscoverNodeFilters. Example: _id:"id1 OR blah",name:"blah OR name2"
      Overrides:
      toString in class java.lang.Object