public class CosmosItemRequestOptions extends Object
Constructor and Description |
---|
CosmosItemRequestOptions()
Constructor
|
Modifier and Type | Method and Description |
---|---|
ConsistencyLevel |
getConsistencyLevel()
Gets the consistency level required for the request.
|
DedicatedGatewayRequestOptions |
getDedicatedGatewayRequestOptions()
Gets the Dedicated Gateway Request Options
|
String |
getIfMatchETag()
Gets the If-Match (ETag) associated with the request in the Azure Cosmos DB service.
|
String |
getIfNoneMatchETag()
Gets the If-None-Match (ETag) associated with the request in the Azure Cosmos DB service.
|
IndexingDirective |
getIndexingDirective()
Gets the indexing directive (index, do not index etc).
|
List<String> |
getPostTriggerInclude()
Gets the triggers to be invoked after the operation.
|
List<String> |
getPreTriggerInclude()
Gets the triggers to be invoked before the operation.
|
String |
getSessionToken()
Gets the token for use with session consistency.
|
Duration |
getThresholdForDiagnosticsOnTracer()
Gets the thresholdForDiagnosticsOnTracer, if latency on CRUD operation is greater than this
diagnostics will be send to open telemetry exporter as events in tracer span of end to end CRUD api.
|
String |
getThroughputControlGroupName() |
Boolean |
isContentResponseOnWriteEnabled()
Gets the boolean to only return the headers and status code in Cosmos DB response
in case of Create, Update and Delete operations on CosmosItem.
|
CosmosItemRequestOptions |
setConsistencyLevel(ConsistencyLevel consistencyLevel)
Sets the consistency level required for the request.
|
CosmosItemRequestOptions |
setContentResponseOnWriteEnabled(Boolean contentResponseOnWriteEnabled)
Sets the boolean to only return the headers and status code in Cosmos DB response
in case of Create, Update and Delete operations on CosmosItem.
|
CosmosItemRequestOptions |
setDedicatedGatewayRequestOptions(DedicatedGatewayRequestOptions dedicatedGatewayRequestOptions)
Sets the Dedicated Gateway Request Options
|
CosmosItemRequestOptions |
setIfMatchETag(String ifMatchETag)
Sets the If-Match (ETag) associated with the request in the Azure Cosmos DB service.
|
CosmosItemRequestOptions |
setIfNoneMatchETag(String ifNoneMatchETag)
Sets the If-None-Match (ETag) associated with the request in the Azure Cosmos DB service.
|
CosmosItemRequestOptions |
setIndexingDirective(IndexingDirective indexingDirective)
Sets the indexing directive (index, do not index etc).
|
CosmosItemRequestOptions |
setPostTriggerInclude(List<String> postTriggerInclude)
Sets the triggers to be invoked after the operation.
|
CosmosItemRequestOptions |
setPreTriggerInclude(List<String> preTriggerInclude)
Sets the triggers to be invoked before the operation.
|
CosmosItemRequestOptions |
setSessionToken(String sessionToken)
Sets the token for use with session consistency.
|
CosmosItemRequestOptions |
setThresholdForDiagnosticsOnTracer(Duration thresholdForDiagnosticsOnTracer)
Sets the thresholdForDiagnosticsOnTracer, if latency on CRUD operation is greater than this
diagnostics will be send to open telemetry exporter as events in tracer span of end to end CRUD api.
|
void |
setThroughputControlGroupName(String throughputControlGroupName) |
public String getIfMatchETag()
public CosmosItemRequestOptions setIfMatchETag(String ifMatchETag)
ifMatchETag
- the ifMatchETag associated with the request.public String getIfNoneMatchETag()
public CosmosItemRequestOptions setIfNoneMatchETag(String ifNoneMatchETag)
ifNoneMatchETag
- the ifNoneMatchETag associated with the request.public ConsistencyLevel getConsistencyLevel()
public CosmosItemRequestOptions setConsistencyLevel(ConsistencyLevel consistencyLevel)
consistencyLevel
- the consistency level.public IndexingDirective getIndexingDirective()
public CosmosItemRequestOptions setIndexingDirective(IndexingDirective indexingDirective)
indexingDirective
- the indexing directive.public List<String> getPreTriggerInclude()
public CosmosItemRequestOptions setPreTriggerInclude(List<String> preTriggerInclude)
preTriggerInclude
- the triggers to be invoked before the operation.public List<String> getPostTriggerInclude()
public CosmosItemRequestOptions setPostTriggerInclude(List<String> postTriggerInclude)
postTriggerInclude
- the triggers to be invoked after the operation.public String getSessionToken()
public CosmosItemRequestOptions setSessionToken(String sessionToken)
sessionToken
- the session token.public Boolean isContentResponseOnWriteEnabled()
CosmosClientBuilder
,
however if specified on CosmosItemRequestOptions
,
it will override the value specified in CosmosClientBuilder
for this request.
By-default, this is null.public CosmosItemRequestOptions setContentResponseOnWriteEnabled(Boolean contentResponseOnWriteEnabled)
CosmosClientBuilder
,
however if specified on CosmosItemRequestOptions
,
it will override the value specified in CosmosClientBuilder
for this request.contentResponseOnWriteEnabled
- a boolean indicating whether payload will be included
in the response or not for this request@Beta(value=V4_15_0, warningText="Preview API - subject to change in non-backwards compatible way") public DedicatedGatewayRequestOptions getDedicatedGatewayRequestOptions()
@Beta(value=V4_15_0, warningText="Preview API - subject to change in non-backwards compatible way") public CosmosItemRequestOptions setDedicatedGatewayRequestOptions(DedicatedGatewayRequestOptions dedicatedGatewayRequestOptions)
dedicatedGatewayRequestOptions
- Dedicated Gateway Request Options@Beta(value=V4_13_0, warningText="Preview API - subject to change in non-backwards compatible way") public String getThroughputControlGroupName()
@Beta(value=V4_13_0, warningText="Preview API - subject to change in non-backwards compatible way") public void setThroughputControlGroupName(String throughputControlGroupName)
public Duration getThresholdForDiagnosticsOnTracer()
public CosmosItemRequestOptions setThresholdForDiagnosticsOnTracer(Duration thresholdForDiagnosticsOnTracer)
thresholdForDiagnosticsOnTracer
- the latency threshold for diagnostics on tracer.Copyright © 2021 Microsoft Corporation. All rights reserved.