diff --git a/sdk/cosmos/azure-cosmos-examples/src/test/java/com/azure/cosmos/rx/examples/UniqueIndexAsyncAPITest.java b/sdk/cosmos/azure-cosmos-examples/src/test/java/com/azure/cosmos/rx/examples/UniqueIndexAsyncAPITest.java index 6f739115bb1e..817d869dc2bc 100644 --- a/sdk/cosmos/azure-cosmos-examples/src/test/java/com/azure/cosmos/rx/examples/UniqueIndexAsyncAPITest.java +++ b/sdk/cosmos/azure-cosmos-examples/src/test/java/com/azure/cosmos/rx/examples/UniqueIndexAsyncAPITest.java @@ -43,8 +43,7 @@ public void uniqueIndex() { DocumentCollection collectionDefinition = new DocumentCollection(); collectionDefinition.setId(UUID.randomUUID().toString()); UniqueKeyPolicy uniqueKeyPolicy = new UniqueKeyPolicy(); - UniqueKey uniqueKey = new UniqueKey(); - uniqueKey.setPaths(ImmutableList.of("/name", "/field")); + UniqueKey uniqueKey = new UniqueKey(ImmutableList.of("/name", "/field")); uniqueKeyPolicy.setUniqueKeys(Lists.newArrayList(uniqueKey)); collectionDefinition.setUniqueKeyPolicy(uniqueKeyPolicy); PartitionKeyDefinition partitionKeyDef = new PartitionKeyDefinition(); diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ChangeFeedProcessor.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ChangeFeedProcessor.java index 9a8c63fa0656..041e499d92e4 100644 --- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ChangeFeedProcessor.java +++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ChangeFeedProcessor.java @@ -66,9 +66,9 @@ public interface ChangeFeedProcessor { /** * Returns the current owner (host) and an approximation of the difference between the last processed item (defined * by the state of the feed container) and the latest change in the container for each partition (lease - * document). + * item). *
- * An empty map will be returned if the processor was not started or no lease documents matching the current
+ * An empty map will be returned if the processor was not started or no lease items matching the current
* {@link ChangeFeedProcessor} instance's lease prefix could be found.
*
* @return a map representing the current owner and lease token, the current LSN and latest LSN, and the estimated
@@ -111,7 +111,7 @@ interface BuilderDefinition {
BuilderDefinition hostName(String hostName);
/**
- * Sets and existing {@link CosmosAsyncContainer} to be used to read from the monitored collection.
+ * Sets and existing {@link CosmosAsyncContainer} to be used to read from the monitored container.
*
* @param feedContainer the instance of {@link CosmosAsyncContainer} to be used.
* @return current Builder.
@@ -152,7 +152,7 @@ interface BuilderDefinition {
BuilderDefinition handleChanges(Consumer
- * In DIRECT mode, all requests to server resources within a collection, such as documents, stored procedures
+ * In DIRECT mode, all requests to server resources within a container, such as items, stored procedures
* and user-defined functions, etc., are made directly to the data nodes within the target Cosmos DB cluster
* using either the HTTPS or TCP/SSL transport protocol.
*
- * Certain operations on account or database level resources, such as databases, collections and users, etc.,
+ * Certain operations on account or database level resources, such as databases, containers and users, etc.,
* are always routed through the gateway using HTTPS.
*
* After subscription the operation will be performed. The {@link Mono} will
* contain one or several feed response pages of the read conflicts. In case of
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/CosmosAsyncContainer.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/CosmosAsyncContainer.java
index 3659a8e35126..b71e0a3ec322 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/CosmosAsyncContainer.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/CosmosAsyncContainer.java
@@ -94,7 +94,7 @@ public Mono
* After subscription the operation will be performed. The {@link Mono} upon
* successful completion will contain a single Cosmos container response for the
@@ -134,7 +134,7 @@ public Mono
* When EnableEndpointDiscovery is true and PreferredRegions is non-empty,
- * the SDK will prefer to use the regions in the collection in the order
+ * the SDK will prefer to use the regions in the container in the order
* they are specified to perform operations.
*
* If EnableEndpointDiscovery is set to false, this property is ignored.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/DirectConnectionConfig.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/DirectConnectionConfig.java
index 9c4ec55867de..36b13b61e1b2 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/DirectConnectionConfig.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/DirectConnectionConfig.java
@@ -10,7 +10,8 @@
/**
* Represents the connection config with {@link ConnectionMode#DIRECT} associated with Cosmos Client in the Azure Cosmos DB database service.
* For performance tips on how to optimize Direct connection configuration,
- * refer to performance tips guide: https://docs.microsoft.com/en-us/azure/cosmos-db/performance-tips-java-sdk-v4-sql?tabs=api-async
+ * refer to performance tips guide:
+ * Performance tips guide
*/
public final class DirectConnectionConfig {
// Constants
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/Permission.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/Permission.java
index b54bf293b994..bb916d876a61 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/Permission.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/Permission.java
@@ -12,7 +12,7 @@
import java.util.Locale;
/**
- * Represents a per-User Permission to access a specific resource e.g. Document or Collection in the Azure Cosmos DB
+ * Represents a per-User Permission to access a specific resource e.g. item or container in the Azure Cosmos DB
* database service.
*/
public final class Permission extends Resource {
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/RequestOptions.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/RequestOptions.java
index 9beaf90a7bb6..f73e6624a131 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/RequestOptions.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/RequestOptions.java
@@ -179,7 +179,7 @@ public void setResourceTokenExpirySeconds(Integer resourceTokenExpirySeconds) {
}
/**
- * Gets the offer type when creating a document collection.
+ * Gets the offer type when creating a container.
*
* @return the offer type.
*/
@@ -188,7 +188,7 @@ public String getOfferType() {
}
/**
- * Sets the offer type when creating a document collection.
+ * Sets the offer type when creating a container.
*
* @param offerType the offer type.
*/
@@ -197,7 +197,7 @@ public void setOfferType(String offerType) {
}
/**
- * Gets the throughput in the form of Request Units per second when creating a document collection.
+ * Gets the throughput in the form of Request Units per second when creating a container.
*
* @return the throughput value.
*/
@@ -206,7 +206,7 @@ public Integer getOfferThroughput() {
}
/**
- * Sets the throughput in the form of Request Units per second when creating a document collection.
+ * Sets the throughput in the form of Request Units per second when creating a container.
*
* @param offerThroughput the throughput value.
*/
@@ -279,9 +279,9 @@ public void setScriptLoggingEnabled(boolean scriptLoggingEnabled) {
}
/**
- * Gets the quotaInfoEnabled setting for document collection read requests in the Azure Cosmos DB database service.
- * quotaInfoEnabled is used to enable/disable getting document collection quota related stats for document
- * collection read requests.
+ * Gets the quotaInfoEnabled setting for container read requests in the Azure Cosmos DB database service.
+ * quotaInfoEnabled is used to enable/disable getting container quota related stats for item
+ * container read requests.
*
* @return true if quotaInfoEnabled is enabled
*/
@@ -290,9 +290,9 @@ public boolean isQuotaInfoEnabled() {
}
/**
- * Sets the quotaInfoEnabled setting for document collection read requests in the Azure Cosmos DB database service.
- * quotaInfoEnabled is used to enable/disable getting document collection quota related stats for document
- * collection read requests.
+ * Sets the quotaInfoEnabled setting for container read requests in the Azure Cosmos DB database service.
+ * quotaInfoEnabled is used to enable/disable getting container quota related stats for item
+ * container read requests.
*
* @param quotaInfoEnabled a boolean value indicating whether quotaInfoEnabled is enabled or not
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/changefeed/ChangeFeedContextClient.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/changefeed/ChangeFeedContextClient.java
index 6e73914f2513..29a74342ad16 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/changefeed/ChangeFeedContextClient.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/changefeed/ChangeFeedContextClient.java
@@ -109,7 +109,7 @@
* This can be used to support multiple instances of {@link ChangeFeedProcessor} instances pointing at the same
- * feed while using the same auxiliary collection.
+ * feed while using the same auxiliary container.
*
* @return a prefix to be used as part of the lease ID.
*/
@@ -180,10 +180,10 @@ public ChangeFeedProcessorOptions setMaxItemCount(int maxItemCount) {
/**
* Gets the start request continuation token to start looking for changes after.
*
- * This option can be used when lease store is not initialized and it is ignored if a lease document exists and
+ * This option can be used when lease store is not initialized and it is ignored if a lease item exists and
* has continuation token that is not null. If this is specified, both StartTime and StartFromBeginning are ignored.
*
- * @return the string representing a continuation token that will be used to get document feeds starting with.
+ * @return the string representing a continuation token that will be used to get item feeds starting with.
*/
public String getStartContinuation() {
return this.startContinuation;
@@ -192,11 +192,11 @@ public String getStartContinuation() {
/**
* Sets the start request continuation token to start looking for changes after.
*
- * This option can be used when lease store is not initialized and it is ignored if a lease document exists and
+ * This option can be used when lease store is not initialized and it is ignored if a lease item exists and
* has continuation token that is not null. If this is specified, both StartTime and StartFromBeginning are ignored.
*
* @param startContinuation the start request continuation token to start looking for changes after.
- * @return the string representing a continuation token that will be used to get document feeds starting with.
+ * @return the string representing a continuation token that will be used to get item feeds starting with.
*/
public ChangeFeedProcessorOptions setStartContinuation(String startContinuation) {
this.startContinuation = startContinuation;
@@ -207,7 +207,7 @@ public ChangeFeedProcessorOptions setStartContinuation(String startContinuation)
* Gets the time (exclusive) to start looking for changes after.
*
* This option can be used when:
- * (1) Lease documents are not initialized; this setting will be ignored if the lease documents exists and have a
+ * (1) Lease items are not initialized; this setting will be ignored if the lease items exists and have a
* valid continuation token.
* (2) Start continuation token option is not specified.
* If this option is specified, "start from beginning" option is ignored.
@@ -222,7 +222,7 @@ public OffsetDateTime getStartTime() {
* Sets the time (exclusive) to start looking for changes after (UTC time).
*
* This option can be used when:
- * (1) Lease documents are not initialized; this setting will be ignored if the lease documents exists and have a
+ * (1) Lease items are not initialized; this setting will be ignored if the lease items exists and have a
* valid continuation token.
* (2) Start continuation token option is not specified.
* If this option is specified, "start from beginning" option is ignored.
@@ -240,7 +240,7 @@ public ChangeFeedProcessorOptions setStartTime(OffsetDateTime startTime) {
* or from current (false). By default it's start from current (false).
*
* This option can be used when:
- * (1) Lease documents are not initialized; this setting will be ignored if the lease documents exists and have a
+ * (1) Lease items are not initialized; this setting will be ignored if the lease items exists and have a
* valid continuation token.
* (2) Start continuation token option is not specified.
* (3) Start time option is not specified.
@@ -255,7 +255,7 @@ public boolean isStartFromBeginning() {
* Sets a value indicating whether change feed in the Azure Cosmos DB service should start from beginning.
*
* This option can be used when:
- * (1) Lease documents are not initialized; this setting will be ignored if the lease documents exists and have a
+ * (1) Lease items are not initialized; this setting will be ignored if the lease items exists and have a
* valid continuation token.
* (2) Start continuation token option is not specified.
* (3) Start time option is not specified.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CompositePathSortOrder.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CompositePathSortOrder.java
index 195b8dc0af45..8b5b3cc8458e 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CompositePathSortOrder.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CompositePathSortOrder.java
@@ -5,7 +5,7 @@
/**
* Represents the sorting order for a path in a composite index, for a
- * collection in the Azure Cosmos DB database service.
+ * container in the Azure Cosmos DB database service.
*/
public enum CompositePathSortOrder {
/**
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ConflictResolutionMode.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ConflictResolutionMode.java
index c1ef68ba59c9..dc2565545dae 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ConflictResolutionMode.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ConflictResolutionMode.java
@@ -14,8 +14,8 @@ public enum ConflictResolutionMode {
* Last writer wins conflict resolution mode
*
* Setting the ConflictResolutionMode to "LAST_WRITER_WINS" indicates that conflict resolution should be done by
- * inspecting a field in the conflicting documents
- * and picking the document which has the higher value in that path. See
+ * inspecting a field in the conflicting items
+ * and picking the item which has the higher value in that path. See
* {@link ConflictResolutionPolicy#getConflictResolutionPath()} for details on how to specify the path
*
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosAsyncItemResponse.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosAsyncItemResponse.java
index 40329cbd5f9b..ece871e18398 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosAsyncItemResponse.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosAsyncItemResponse.java
@@ -182,6 +182,7 @@ public Duration getDuration() {
/**
* Gets the ETag from the response headers.
+ * This is only relevant when getting response from the server.
*
* Null in case of delete operation.
*
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosConflictProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosConflictProperties.java
index f347343cb1fe..592686ba9109 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosConflictProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosConflictProperties.java
@@ -86,6 +86,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -95,6 +96,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerProperties.java
index 7d72ef7c8975..1439b69b5999 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerProperties.java
@@ -11,7 +11,7 @@
import java.util.stream.Collectors;
/**
- * Represents a item container in the Azure Cosmos DB database service. A cosmos container is a named logical container
+ * Represents a container in the Azure Cosmos DB database service. A cosmos container is a named logical container
* for cosmos items.
*
* A database may contain zero or more named containers and each container consists of zero or more JSON items.
@@ -55,7 +55,7 @@ public CosmosContainerProperties(String id, PartitionKeyDefinition partitionKeyD
this.documentCollection = new DocumentCollection(json);
}
- // Converting document collection to CosmosContainerProperties
+ // Converting container to CosmosContainerProperties
CosmosContainerProperties(DocumentCollection collection) {
this.documentCollection = new DocumentCollection(collection.toJson());
}
@@ -126,7 +126,7 @@ public CosmosContainerProperties setPartitionKeyDefinition(PartitionKeyDefinitio
/**
* Gets the conflictResolutionPolicy that is used for resolving conflicting writes
- * on documents in different regions, in a collection in the Azure Cosmos DB service.
+ * on items in different regions, in a container in the Azure Cosmos DB service.
*
* @return ConflictResolutionPolicy
*/
@@ -136,7 +136,7 @@ public ConflictResolutionPolicy getConflictResolutionPolicy() {
/**
* Sets the conflictResolutionPolicy that is used for resolving conflicting writes
- * on documents in different regions, in a collection in the Azure Cosmos DB service.
+ * on items in different regions, in a container in the Azure Cosmos DB service.
*
* @param value ConflictResolutionPolicy to be used.
* @return the CosmosContainerProperties.
@@ -147,7 +147,7 @@ public CosmosContainerProperties setConflictResolutionPolicy(ConflictResolutionP
}
/**
- * Gets the collection's default time-to-live value.
+ * Gets the container's default time-to-live value.
*
* @return the default time-to-live value in seconds.
*/
@@ -156,23 +156,23 @@ public Integer getDefaultTimeToLiveInSeconds() {
}
/**
- * Sets the collection's default time-to-live value.
+ * Sets the container's default time-to-live value.
*
- * The default time-to-live value on a collection is an optional property. If set, the documents within the
- * collection
+ * The default time-to-live value on a container is an optional property. If set, the items within the
+ * container
* expires after the specified number of seconds since their last write time. The value of this property should
* be one of the following:
*
- * null - indicates evaluation of time-to-live is disabled and documents within the collection will never expire,
+ * null - indicates evaluation of time-to-live is disabled and items within the container will never expire,
* regardless whether
- * individual documents have their time-to-live set.
+ * individual items have their time-to-live set.
*
- * nonzero positive integer - indicates the default time-to-live value for all documents within the collection.
+ * nonzero positive integer - indicates the default time-to-live value for all items within the container.
* This value can be overridden
- * by individual documents' time-to-live value.
+ * by individual items time-to-live value.
*
- * -1 - indicates by default all documents within the collection never expire. This value can be overridden by
- * individual documents'
+ * -1 - indicates by default all items within the container never expire. This value can be overridden by
+ * individual items
* time-to-live value.
*
* @param timeToLive the default time-to-live value in seconds.
@@ -191,7 +191,7 @@ public CosmosContainerProperties setDefaultTimeToLiveInSeconds(Integer timeToLiv
*
* It is an optional property. A valid value must be either a nonzero positive integer, '-1', or 0.
* By default, AnalyticalStoreTimeToLive is set to 0 meaning the analytical store is turned off for the container;
- * -1 means documents in analytical store never expire.
+ * -1 means items in analytical store never expire.
* The unit of measurement is seconds. The maximum allowed value is 2147483647.
*
* @param timeToLive the analytical store time to live in seconds.
@@ -208,7 +208,7 @@ public CosmosContainerProperties setAnalyticalStoreTimeToLiveInSeconds(Integer t
*
* It is an optional property. A valid value must be either a nonzero positive integer, '-1', or 0.
* By default, AnalyticalStoreTimeToLive is set to 0 meaning the analytical store is turned off for the container;
- * -1 means documents in analytical store never expire.
+ * -1 means items in analytical store never expire.
* The unit of measurement is seconds. The maximum allowed value is 2147483647.
*
* @return analytical ttl
@@ -248,6 +248,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -257,6 +258,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerRequestOptions.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerRequestOptions.java
index 09986beca058..02690f8346cc 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerRequestOptions.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerRequestOptions.java
@@ -18,8 +18,8 @@ public final class CosmosContainerRequestOptions {
/**
* Gets the quotaInfoEnabled setting for cosmos container read requests in the Azure Cosmos DB database service.
- * quotaInfoEnabled is used to enable/disable getting cosmos container quota related stats for document
- * collection read requests.
+ * quotaInfoEnabled is used to enable/disable getting cosmos container quota related stats for item
+ * container read requests.
*
* @return true if quotaInfoEnabled is enabled
*/
@@ -29,8 +29,8 @@ public boolean isQuotaInfoEnabled() {
/**
* Sets the quotaInfoEnabled setting for cosmos container read requests in the Azure Cosmos DB database service.
- * quotaInfoEnabled is used to enable/disable getting cosmos container quota related stats for document
- * collection read requests.
+ * quotaInfoEnabled is used to enable/disable getting cosmos container quota related stats for item
+ * container read requests.
*
* @param quotaInfoEnabled a boolean value indicating whether quotaInfoEnabled is enabled or not
* @return the current request options
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosDatabaseProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosDatabaseProperties.java
index b670f196b06d..d94d086dd462 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosDatabaseProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosDatabaseProperties.java
@@ -36,7 +36,7 @@ public CosmosDatabaseProperties(String id) {
this.database = new Database(jsonString);
}
- // Converting document collection to CosmosContainerProperties
+ // Converting container to CosmosContainerProperties
CosmosDatabaseProperties(Database database) {
this.database = database;
}
@@ -76,6 +76,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -85,6 +86,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosItemResponse.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosItemResponse.java
index ef2f1940ab1e..c1801221a9cc 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosItemResponse.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosItemResponse.java
@@ -123,6 +123,7 @@ public Duration getDuration() {
/**
* Gets the ETag from the response headers.
+ * This is only relevant when getting response from the server.
*
* Null in case of delete operation.
*
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosPermissionProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosPermissionProperties.java
index 3f00bf86d5c9..cb1b7e536e71 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosPermissionProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosPermissionProperties.java
@@ -131,6 +131,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -140,6 +141,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosStoredProcedureProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosStoredProcedureProperties.java
index 40eeef57f758..de314dc40474 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosStoredProcedureProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosStoredProcedureProperties.java
@@ -13,8 +13,9 @@
* Represents a stored procedure in the Azure Cosmos DB database service.
*
* Cosmos DB allows stored procedures to be executed in the storage tier, directly against a container. The
- * script gets executed under ACID transactions on the primary storage partition of the specified collection. For
- * additional details, refer to the server-side JavaScript API documentation.
+ * script gets executed under ACID transactions on the primary storage partition of the specified container. For
+ * additional details, refer to
+ * documentation
*/
public final class CosmosStoredProcedureProperties {
@@ -102,6 +103,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -111,6 +113,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosTriggerProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosTriggerProperties.java
index 6ddd95b53db3..6de7e85b886d 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosTriggerProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosTriggerProperties.java
@@ -126,6 +126,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -135,6 +136,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserDefinedFunctionProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserDefinedFunctionProperties.java
index 1e546686b361..e17af43bf57e 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserDefinedFunctionProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserDefinedFunctionProperties.java
@@ -87,6 +87,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -96,6 +97,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserProperties.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserProperties.java
index 88521bb68d3e..b3d9f5797ffb 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserProperties.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosUserProperties.java
@@ -43,7 +43,7 @@ public CosmosUserProperties setId(String id) {
this.user = new User(jsonString);
}
- // Converting document collection to CosmosContainerProperties
+ // Converting container to CosmosContainerProperties
CosmosUserProperties(User user) {
this.user = user;
}
@@ -86,6 +86,7 @@ public String getResourceId() {
/**
* Get the last modified timestamp associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the timestamp.
*/
@@ -95,6 +96,7 @@ public OffsetDateTime getTimestamp() {
/**
* Get the entity tag associated with the resource.
+ * This is only relevant when getting response from the server.
*
* @return the e tag.
*/
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedOptions.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedOptions.java
index 6ea51eb9b1a9..10b6f7addb23 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedOptions.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedOptions.java
@@ -181,7 +181,7 @@ public FeedOptions setMaxBufferedItemCount(int maxBufferedItemCount) {
}
/**
- * Sets the ResponseContinuationTokenLimitInKb request option for document query
+ * Sets the ResponseContinuationTokenLimitInKb request option for item query
* requests in the Azure Cosmos DB service.
*
* ResponseContinuationTokenLimitInKb is used to limit the length of
@@ -206,7 +206,7 @@ public FeedOptions getResponseContinuationTokenLimitInKb(int limitInKb) {
}
/**
- * Gets the ResponseContinuationTokenLimitInKb request option for document query
+ * Gets the ResponseContinuationTokenLimitInKb request option for item query
* requests in the Azure Cosmos DB service. If not already set returns 0.
*
* ResponseContinuationTokenLimitInKb is used to limit the length of
@@ -293,7 +293,7 @@ public boolean isQueryMetricsEnabled() {
}
/**
- * Sets the option to enable/disable getting metrics relating to query execution on document query requests
+ * Sets the option to enable/disable getting metrics relating to query execution on item query requests
*
* @param queryMetricsEnabled whether to enable or disable query metrics
* @return the FeedOptionsBase.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedResponse.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedResponse.java
index 28c9828c2458..2231c5d44f52 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedResponse.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/FeedResponse.java
@@ -96,7 +96,7 @@ public long getDatabaseUsage() {
}
/**
- * Gets the maximum quota for collection resources within an account from the Azure Cosmos DB service.
+ * Gets the maximum quota for container resources within an account from the Azure Cosmos DB service.
*
* @return The maximum quota for the account.
*/
@@ -105,9 +105,9 @@ public long getCollectionQuota() {
}
/**
- * Gets the current number of collection resources within the account from the Azure Cosmos DB service.
+ * Gets the current number of container resources within the account from the Azure Cosmos DB service.
*
- * @return The current number of collections.
+ * @return The current number of containers.
*/
public long getCollectionUsage() {
return this.currentQuotaHeader(Constants.Quota.COLLECTION);
@@ -150,7 +150,7 @@ public long getPermissionUsage() {
}
/**
- * Gets the maximum size of a collection in kilobytes from the Azure Cosmos DB service.
+ * Gets the maximum size of a container in kilobytes from the Azure Cosmos DB service.
*
* @return The maximum quota in kilobytes.
*/
@@ -159,16 +159,16 @@ public long getCollectionSizeQuota() {
}
/**
- * Gets the current size of a collection in kilobytes from the Azure Cosmos DB service.
+ * Gets the current size of a container in kilobytes from the Azure Cosmos DB service.
*
- * @return The current size of a collection in kilobytes.
+ * @return The current size of a container in kilobytes.
*/
public long getCollectionSizeUsage() {
return this.currentQuotaHeader(Constants.Quota.COLLECTION_SIZE);
}
/**
- * Gets the maximum quota of stored procedures for a collection from the Azure Cosmos DB service.
+ * Gets the maximum quota of stored procedures for a container from the Azure Cosmos DB service.
*
* @return The maximum stored procedure quota.
*/
@@ -177,7 +177,7 @@ public long getStoredProceduresQuota() {
}
/**
- * Gets the current number of stored procedures for a collection from the Azure Cosmos DB service.
+ * Gets the current number of stored procedures for a container from the Azure Cosmos DB service.
*
* @return The current number of stored procedures.
*/
@@ -186,7 +186,7 @@ public long getStoredProceduresUsage() {
}
/**
- * Gets the maximum quota of triggers for a collection from the Azure Cosmos DB service.
+ * Gets the maximum quota of triggers for a container from the Azure Cosmos DB service.
*
* @return The maximum triggers quota.
*/
@@ -195,7 +195,7 @@ public long getTriggersQuota() {
}
/**
- * Get the current number of triggers for a collection from the Azure Cosmos DB service.
+ * Get the current number of triggers for a container from the Azure Cosmos DB service.
*
* @return The current number of triggers.
*/
@@ -204,7 +204,7 @@ public long getTriggersUsage() {
}
/**
- * Gets the maximum quota of user defined functions for a collection from the Azure Cosmos DB service.
+ * Gets the maximum quota of user defined functions for a container from the Azure Cosmos DB service.
*
* @return The maximum user defined functions quota.
*/
@@ -213,7 +213,7 @@ public long getUserDefinedFunctionsQuota() {
}
/**
- * Gets the current number of user defined functions for a collection from the Azure Cosmos DB service.
+ * Gets the current number of user defined functions for a container from the Azure Cosmos DB service.
*
* @return the current number of user defined functions.
*/
@@ -225,7 +225,7 @@ public long getUserDefinedFunctionsUsage() {
* Gets the maximum size limit for this entity from the Azure Cosmos DB service.
*
* @return the maximum size limit for this entity.
- * Measured in kilobytes for document resources and in counts for other resources.
+ * Measured in kilobytes for item resources and in counts for other resources.
*/
public String getMaxResourceQuota() {
return getValueOrNull(header,
@@ -235,7 +235,7 @@ public String getMaxResourceQuota() {
/**
* Gets the current size of this entity from the Azure Cosmos DB service.
*
- * @return the current size for this entity. Measured in kilobytes for document resources
+ * @return the current size for this entity. Measured in kilobytes for item resources
* and in counts for other resources.
*/
public String getCurrentResourceQuotaUsage() {
@@ -320,7 +320,7 @@ ConcurrentMap
- * With consistent indexing, query behavior is the same as the default consistency level for the collection. The
+ * 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.
*/
CONSISTENT("Consistent"),
@@ -18,16 +18,16 @@ public enum IndexingMode {
/**
* 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.
+ * With lazy indexing, queries are eventually consistent. The index is updated when the container is idle.
*/
LAZY("Lazy"),
/**
* 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.
+ * 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.
*/
NONE("None");
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/IndexingPolicy.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/IndexingPolicy.java
index a179f114d1e1..803659aa70d7 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/IndexingPolicy.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/IndexingPolicy.java
@@ -14,7 +14,7 @@
import java.util.List;
/**
- * Represents the indexing policy configuration for a collection in the Azure Cosmos DB database service.
+ * Represents the indexing policy configuration for a container in the Azure Cosmos DB database service.
*/
public final class IndexingPolicy {
private static final String DEFAULT_PATH = "/*";
@@ -86,10 +86,10 @@ public IndexingPolicy(Index[] defaultIndexOverrides) {
}
/**
- * Gets whether automatic indexing is enabled for a collection.
+ * Gets whether automatic indexing is enabled for a container.
*
- * In automatic indexing, documents can be explicitly excluded from indexing using RequestOptions. In manual
- * indexing, documents can be explicitly included.
+ * In automatic indexing, items can be explicitly excluded from indexing using RequestOptions. In manual
+ * indexing, items can be explicitly included.
*
* @return the automatic
*/
@@ -98,10 +98,10 @@ public Boolean isAutomatic() {
}
/**
- * Sets whether automatic indexing is enabled for a collection.
+ * Sets whether automatic indexing is enabled for a container.
*
- * In automatic indexing, documents can be explicitly excluded from indexing using RequestOptions. In manual
- * indexing, documents can be explicitly included.
+ * In automatic indexing, items can be explicitly excluded from indexing using RequestOptions. In manual
+ * indexing, items can be explicitly included.
*
* @param automatic the automatic
* @return the Indexing Policy.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKey.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKey.java
index a51c5d3a199c..9f949b581780 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKey.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKey.java
@@ -8,7 +8,7 @@
/**
* Represents a partition key value in the Azure Cosmos DB database service. A
- * partition key identifies the partition where the document is stored in.
+ * partition key identifies the partition where the item is stored in.
*/
public class PartitionKey {
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKeyDefinition.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKeyDefinition.java
index 772f564e3e6c..94bc2b81bbb1 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKeyDefinition.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/PartitionKeyDefinition.java
@@ -17,7 +17,7 @@
/**
* Represents a partition key definition in the Azure Cosmos DB database service. A partition key definition
* specifies which
- * document property is used as the partition key in a collection that has multiple partitions.
+ * item property is used as the partition key in a container that has multiple partitions.
*/
public final class PartitionKeyDefinition {
private List
- * 1) For partitioned collections, the value of partition key is implicitly a part of each unique key.
+ * 1) For containers, the value of partition key is implicitly a part of each unique key.
+ *
* 2) Uniqueness constraint is also enforced for missing values.
+ *
* For instance, if unique key policy defines a unique key with single property path, there could be only one
- * document that has missing value for this property.
+ * item that has missing value for this property.
*
* @see UniqueKeyPolicy
*/
@@ -26,10 +28,12 @@ public final class UniqueKey {
private JsonSerializable jsonSerializable;
/**
- * Instantiates a new Unique key.
+ * Instantiates a new Unique key with paths.
+ * @param paths the unique paths.
*/
- public UniqueKey() {
+ public UniqueKey(List
- * The paths to enforce uniqueness on. Each path is a rooted path of the unique property in the document,
+ * The paths to enforce uniqueness on. Each path is a rooted path of the unique property in the item,
* such as "/name/first".
*
* @return the unique paths.
@@ -72,9 +76,9 @@ public List
- * The paths to enforce uniqueness on. Each path is a rooted path of the unique property in the document,
+ * The paths to enforce uniqueness on. Each path is a rooted path of the unique property in the item,
* such as "/name/first".
*
* @param paths the unique paths.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/UniqueKeyPolicy.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/UniqueKeyPolicy.java
index c4e1455a0523..c1e5cc30b887 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/UniqueKeyPolicy.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/UniqueKeyPolicy.java
@@ -10,8 +10,8 @@
import java.util.List;
/**
- * Represents the unique key policy configuration for specifying uniqueness constraints on documents in the
- * collection in the Azure Cosmos DB service.
+ * Represents the unique key policy configuration for specifying uniqueness constraints on items in the
+ * container in the Azure Cosmos DB service.
*/
public final class UniqueKeyPolicy {
private List> consumer);
/**
- * Sets an existing {@link CosmosAsyncContainer} to be used to read from the leases collection.
+ * Sets an existing {@link CosmosAsyncContainer} to be used to read from the leases container.
*
* @param leaseContainer the instance of {@link CosmosAsyncContainer} to use.
* @return current Builder.
diff --git a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ConnectionMode.java b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ConnectionMode.java
index cefe9935cc9f..278afba4c88e 100644
--- a/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ConnectionMode.java
+++ b/sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ConnectionMode.java
@@ -21,11 +21,11 @@ public enum ConnectionMode {
/**
* Specifies that requests to server resources are made directly to the data nodes.
*