Azure Cosmos DB
An Azure NoSQL database service for app development.
980 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
How to create uniqueKey for container using annotation in azure cosmos DB.
You can use the feature of Nested Partition Key Path in azure-spring-data-cosmos to solve the unique key problem in spring - https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/cosmos/azure-spring-data-cosmos/README.md#nested-partition-key-support.
Yes it is
I want to create unique key path for tagName and domainName using annotation
@alrt
@MetContainer (containerName = "emptyTag")
@TostringsOwO
@EqualsAndHashCode
@Builder
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignoreUnknown = true)
@NoArgsConstructor
@AllArgsConstructor
public class Tag {
@Id
@GeneratedValue
private String id;
private String tagName;
private String domainName;
@PartitionKey
private String countryDcOrgUnit;
}