Enum IndexingMode

    • Enum Constant Detail

      • 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 collection. 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 collection 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 document collection, to save the storage cost or improve the write throughput. Your queries will degenerate to scans of the entire collection.

    • Method Detail

      • values

        public static IndexingMode[] 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 (IndexingMode c : IndexingMode.values())
            System.out.println(c);
        
        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