public final class FeedOptions extends Object
Constructor and Description |
---|
FeedOptions() |
FeedOptions(FeedOptions options) |
Modifier and Type | Method and Description |
---|---|
boolean |
getAllowEmptyPages()
Gets the option to allow empty result pages in feed response.
|
Boolean |
getEmitVerboseTracesInQuery()
Gets the option to allow queries to emit out verbose traces for
investigation.
|
Boolean |
getEnableScanInQuery()
Gets the option to allow scan on the queries which couldn't be served as
indexing was opted out on the requested paths.
|
int |
getMaxBufferedItemCount()
Gets the maximum number of items that can be buffered client side during
parallel query execution.
|
int |
getMaxDegreeOfParallelism()
Gets the number of concurrent operations run client side during parallel
query execution.
|
FeedOptions |
getResponseContinuationTokenLimitInKb(int limitInKb)
Sets the ResponseContinuationTokenLimitInKb request option for document query
requests in the Azure Cosmos DB service.
|
String |
getSessionToken()
Gets the session token for use with session consistency.
|
Integer |
maxItemCount()
Gets the maximum number of items to be returned in the enumeration
operation.
|
FeedOptions |
maxItemCount(Integer maxItemCount)
Sets the maximum number of items to be returned in the enumeration
operation.
|
PartitionKey |
partitionKey()
Gets the partition key used to identify the current request's target
partition.
|
FeedOptions |
partitionKey(PartitionKey partitionkey)
Sets the partition key used to identify the current request's target
partition.
|
boolean |
populateQueryMetrics()
Gets the option to enable populate query metrics
|
FeedOptions |
populateQueryMetrics(boolean populateQueryMetrics)
Sets the option to enable/disable getting metrics relating to query execution on document query requests
|
Map<String,Object> |
properties()
Gets the properties
|
FeedOptions |
properties(Map<String,Object> properties)
Sets the properties used to identify the request token.
|
String |
requestContinuation()
Gets the request continuation token.
|
FeedOptions |
requestContinuation(String requestContinuation)
Sets the request continuation token.
|
void |
setAllowEmptyPages(boolean allowEmptyPages)
Sets the option to allow empty result pages in feed response.
|
FeedOptions |
setEmitVerboseTracesInQuery(Boolean emitVerboseTracesInQuery)
Sets the option to allow queries to emit out verbose traces for
investigation.
|
FeedOptions |
setEnableScanInQuery(Boolean enableScanInQuery)
Sets the option to allow scan on the queries which couldn't be served as
indexing was opted out on the requested paths.
|
FeedOptions |
setMaxBufferedItemCount(int maxBufferedItemCount)
Sets the maximum number of items that can be buffered client side during
parallel query execution.
|
FeedOptions |
setMaxDegreeOfParallelism(int maxDegreeOfParallelism)
Sets the number of concurrent operations run client side during parallel
query execution.
|
int |
setResponseContinuationTokenLimitInKb()
Gets the ResponseContinuationTokenLimitInKb request option for document query
requests in the Azure Cosmos DB service.
|
FeedOptions |
setSessionToken(String sessionToken)
Sets the session token for use with session consistency.
|
public FeedOptions()
public FeedOptions(FeedOptions options)
public String getSessionToken()
public FeedOptions setSessionToken(String sessionToken)
sessionToken
- the session token.public Boolean getEnableScanInQuery()
public FeedOptions setEnableScanInQuery(Boolean enableScanInQuery)
enableScanInQuery
- the option of enable scan in query.public Boolean getEmitVerboseTracesInQuery()
public FeedOptions setEmitVerboseTracesInQuery(Boolean emitVerboseTracesInQuery)
emitVerboseTracesInQuery
- the emit verbose traces in query.public int getMaxDegreeOfParallelism()
public FeedOptions setMaxDegreeOfParallelism(int maxDegreeOfParallelism)
maxDegreeOfParallelism
- number of concurrent operations.public int getMaxBufferedItemCount()
public FeedOptions setMaxBufferedItemCount(int maxBufferedItemCount)
maxBufferedItemCount
- maximum number of items.public FeedOptions getResponseContinuationTokenLimitInKb(int limitInKb)
ResponseContinuationTokenLimitInKb is used to limit the length of continuation token in the query response. Valid values are >= 1.
The continuation token contains both required and optional fields. The required fields are necessary for resuming the execution from where it was stooped. The optional fields may contain serialized index lookup work that was done but not yet utilized. This avoids redoing the work again in subsequent continuations and hence improve the query performance. Setting the maximum continuation size to 1KB, the Azure Cosmos DB service will only serialize required fields. Starting from 2KB, the Azure Cosmos DB service would serialize as much as it could fit till it reaches the maximum specified size.
limitInKb
- continuation token size limit.public int setResponseContinuationTokenLimitInKb()
ResponseContinuationTokenLimitInKb is used to limit the length of continuation token in the query response. Valid values are >= 1.
public Integer maxItemCount()
public FeedOptions maxItemCount(Integer maxItemCount)
maxItemCount
- the max number of items.public String requestContinuation()
public FeedOptions requestContinuation(String requestContinuation)
requestContinuation
- the request continuation.public PartitionKey partitionKey()
public FeedOptions partitionKey(PartitionKey partitionkey)
partitionkey
- the partition key value.public boolean populateQueryMetrics()
public FeedOptions populateQueryMetrics(boolean populateQueryMetrics)
populateQueryMetrics
- whether to enable or disable query metricspublic Map<String,Object> properties()
public FeedOptions properties(Map<String,Object> properties)
properties
- the properties.public boolean getAllowEmptyPages()
public void setAllowEmptyPages(boolean allowEmptyPages)
allowEmptyPages
- whether to allow empty pages in feed responseCopyright © 2020 Microsoft Corporation. All rights reserved.