Enum IndexingMode

java.lang.Object
java.lang.Enum<IndexingMode>
com.azure.cosmos.models.IndexingMode
All Implemented Interfaces:
Serializable, Comparable<IndexingMode>, java.lang.constant.Constable

public enum IndexingMode extends Enum<IndexingMode>
Specifies the supported indexing modes in the Azure Cosmos DB database service.
  • Enum Constant Details

    • CONSISTENT

      public static final IndexingMode CONSISTENT
      Index is updated synchronously with a create or update operation.

      With consistent indexing, query behavior is the same as the default consistency level for the container. The index is always kept up to date with the data.

    • LAZY

      public static final IndexingMode LAZY
      Index is updated asynchronously with respect to a create or update operation.

      With lazy indexing, queries are eventually consistent. The index is updated when the container is idle.

    • NONE

      public static final IndexingMode NONE
      No index is provided.

      Setting IndexingMode to "NONE" drops the index. Use this if you don't want to maintain the index for a item container, to save the storage cost or improve the write throughput. Your queries will degenerate to scans of the entire container.

  • Method Details

    • values

      public static IndexingMode[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static IndexingMode 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
    • toString

      public String toString()
      Overrides:
      toString in class Enum<IndexingMode>