Package io.vertx.redis.client

## Enum RedisClusterTransactions

- java.lang.Object
- - java.lang.Enum<RedisClusterTransactions>
  - - io.vertx.redis.client.RedisClusterTransactions

- All Implemented Interfaces:
    `Serializable`, `Comparable<RedisClusterTransactions>`

      public enum RedisClusterTransactions
      extends Enum<RedisClusterTransactions>

  Define how Redis transactions are handled in a clustered Redis client.

  This is only meaningful in case of a cluster Redis client.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant | Description
    --- | ---
    `DISABLED` | Redis transactions are not supported in the cluster.
    `SINGLE_NODE` | Redis transactions are supported in the cluster, but only when they target a single node.

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static RedisClusterTransactions` | `valueOf​(String name)` | Returns the enum constant of this type with the specified name.
    `static RedisClusterTransactions[]` | `values()` | Returns an array containing the constants of this enum type, in the order they are declared.

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

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

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

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### DISABLED

          public static final RedisClusterTransactions DISABLED

      Redis transactions are not supported in the cluster. Transaction commands lead to an error.

    - #### SINGLE_NODE

          public static final RedisClusterTransactions SINGLE_NODE

      Redis transactions are supported in the cluster, but only when they target a single node. The `MULTI` command is queued and is only issued when the next command is executed. This next command binds the connection to the corresponding node of the Redis cluster (so it should have keys, otherwise the target node is random). All subsequent commands are targeted to that node. If some of the subsequent commands have a key that belongs to another node, the command fails on the server side.

      If `WATCH` is used before `MULTI`, its key(s) determine to which node the connection is bound and the subsequent `MULTI` is not queued. If `WATCH` keys belong to multiple nodes, the command fails on the client side.

  - ### Method Detail

    - #### values

          public static RedisClusterTransactions[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (RedisClusterTransactions c : RedisClusterTransactions.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static RedisClusterTransactions valueOf​(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null