org.apache.cassandra.batchlog

## Class BatchlogManager.EndpointFilter

- java.lang.Object
- - org.apache.cassandra.batchlog.BatchlogManager.EndpointFilter

- Enclosing class:
    BatchlogManager

      public static class BatchlogManager.EndpointFilter
      extends java.lang.Object

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `EndpointFilter(java.lang.String localRack, com.google.common.collect.Multimap<java.lang.String,java.net.InetAddress> endpoints)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.Collection<java.net.InetAddress>` | `filter()`
    `protected int` | `getRandomInt(int bound)`
    `protected boolean` | `isValid(java.net.InetAddress input)`
    `protected void` | `shuffle(java.util.List<?> list)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### EndpointFilter

          public EndpointFilter(java.lang.String localRack,
                                com.google.common.collect.Multimap<java.lang.String,java.net.InetAddress> endpoints)

  - ### Method Detail

    - #### filter

          public java.util.Collection<java.net.InetAddress> filter()

      Returns:
        list of candidates for batchlog hosting. If possible these will be two nodes from different racks.

    - #### isValid

          protected boolean isValid(java.net.InetAddress input)

    - #### getRandomInt

          protected int getRandomInt(int bound)

    - #### shuffle

          protected void shuffle(java.util.List<?> list)

Copyright © 2018 The Apache Software Foundation