Class CreatePrimaryQueryIndexOptions
java.lang.Object
com.couchbase.client.java.CommonOptions<CreatePrimaryQueryIndexOptions>
com.couchbase.client.java.manager.query.CreatePrimaryQueryIndexOptions
public class CreatePrimaryQueryIndexOptions extends CommonOptions<CreatePrimaryQueryIndexOptions>
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classCreatePrimaryQueryIndexOptions.BuiltNested classes/interfaces inherited from class com.couchbase.client.java.CommonOptions
CommonOptions.BuiltCommonOptions -
Method Summary
Modifier and Type Method Description CreatePrimaryQueryIndexOptions.Builtbuild()static CreatePrimaryQueryIndexOptionscreatePrimaryQueryIndexOptions()CreatePrimaryQueryIndexOptionsdeferred(boolean deferred)Set totrueto defer building of the index untilQueryIndexManager.buildDeferredIndexes(java.lang.String)is called.CreatePrimaryQueryIndexOptionsignoreIfExists(boolean ignore)If a primary index already exists, an exception will be thrown unless this is set to true.CreatePrimaryQueryIndexOptionsindexName(String indexName)Specifies the name of the primary index to create.CreatePrimaryQueryIndexOptionsnumReplicas(int numReplicas)Specifies the number of replicas of the index to create.CreatePrimaryQueryIndexOptionswith(String optionName, Object optionValue)Escape hatch for specifying extra options in theWITHclause.Methods inherited from class com.couchbase.client.java.CommonOptions
clientContext, parentSpan, retryStrategy, self, timeout
-
Method Details
-
createPrimaryQueryIndexOptions
-
indexName
Specifies the name of the primary index to create. If not set, the server assigns a default name of"#primary". -
ignoreIfExists
If a primary index already exists, an exception will be thrown unless this is set to true. -
numReplicas
Specifies the number of replicas of the index to create. -
deferred
Set totrueto defer building of the index untilQueryIndexManager.buildDeferredIndexes(java.lang.String)is called.If you are creating multiple indexes on the same bucket, you may see improved performance by creating them in deferred mode and then building them all at once.
-
with
Escape hatch for specifying extra options in theWITHclause. Intended for options that are supported by Couchbase Server but not by this version of the SDK. -
build
-