Cosmos: Promote Full Fidelity Change Feed (AllVersionsAndDeletes) API to GA#49283
Cosmos: Promote Full Fidelity Change Feed (AllVersionsAndDeletes) API to GA#49283ananth7592 wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Pull request overview
Promotes Cosmos DB Full Fidelity Change Feed (AllVersionsAndDeletes) surface area to GA by removing @Beta markings from the public API types/methods (while keeping deprecated legacy APIs for back-compat), and updates release notes / Revapi configuration accordingly.
Changes:
- Removed
@Betaannotations from AllVersionsAndDeletes-related public APIs (policies, request options, processor builder, item/metadata models, operation type enum). - Updated
sdk/cosmos/azure-cosmos/CHANGELOG.mdto document the GA promotion. - Updated Revapi ignore configuration to account for
@Betaannotation removals on enums as well.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosContainerProperties.java | Removes @Beta from change feed policy getter/setter. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/CosmosChangeFeedRequestOptions.java | Removes @Beta from allVersionsAndDeletes() request option. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ChangeFeedProcessorItem.java | Promotes processor item model/accessors to GA by removing @Beta. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ChangeFeedPolicy.java | Promotes policy factory/accessor APIs to GA by removing @Beta. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ChangeFeedOperationType.java | Promotes operation type enum to GA by removing @Beta. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ChangeFeedMetaData.java | Promotes metadata model/accessors to GA by removing @Beta. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/implementation/CosmosChangeFeedRequestOptionsImpl.java | Removes @Beta from internal allVersionsAndDeletes() implementation method. |
| sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/ChangeFeedProcessorBuilder.java | Removes @Beta from builder handlers for AllVersionsAndDeletes. |
| sdk/cosmos/azure-cosmos/CHANGELOG.md | Adds release note entry for GA promotion. |
| eng/lintingconfigs/revapi/track2/revapi.json | Adjusts Revapi ignore matcher to include enums for annotation removals. |
Comments suppressed due to low confidence (1)
sdk/cosmos/azure-cosmos/src/main/java/com/azure/cosmos/models/ChangeFeedPolicy.java:99
createAllVersionsAndDeletesPolicy(Duration retentionDuration)is now GA, but it still dereferencesretentionDurationwithout a null check, leading to an unhelpfulNullPointerExceptionif callers pass null. Add an explicit null validation (e.g.,Objects.requireNonNull) with a clear parameter name/message before the existing argument validation.
public static ChangeFeedPolicy createAllVersionsAndDeletesPolicy(Duration retentionDuration) {
if (retentionDuration.isNegative() ||
retentionDuration.isZero() ||
retentionDuration.getNano() != 0 ||
| "matcher": "regex", | ||
| "match": "(class|interface|method|parameter) com\\.azure\\.cosmos\\..*" | ||
| "match": "(class|interface|enum|method|parameter) com\\.azure\\.cosmos\\..*" | ||
| }, |
…s to GA Removes @beta from FFCF / AllVersionsAndDeletes public APIs, including ChangeFeedProcessorContext (parameter type of the BiConsumer overload). The deprecated fullFidelity / createFullFidelityPolicy / createIncrementalPolicy / getFullFidelityRetentionDuration methods are intentionally kept for back-compat. ChangeFeedMode.FULL_FIDELITY enum is also kept (continuation token wire format). Resolves #48959 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
a99efc7 to
1aba48d
Compare
| @@ -251,8 +250,6 @@ public void setRequestContinuation(String etag) { | |||
| this.feedRangeInternal); | |||
| } | |||
|
|
|||
| @Beta(value = Beta.SinceVersion.V4_12_0, warningText = | |||
There was a problem hiding this comment.
We should not remove the @Beta annotation from these deprecated APIs, since they are deprecated anyway, let's keep the @Beta annotation on these.
Idea is to remove them completely from the SDK in the long run, so let's not GA them.
| @@ -3,7 +3,24 @@ | |||
| ### 4.81.0-beta.1 (Unreleased) | |||
|
|
|||
| #### Features Added | |||
|
|
|||
| * Promoted the Full Fidelity Change Feed (AllVersionsAndDeletes) APIs to GA. See [Issue 48959](https://github.com/Azure/azure-sdk-for-java/issues/48959). The following types and members are no longer marked `@Beta`: | |||
There was a problem hiding this comment.
This is too big of a changelog entry, lets just keep it to
Promoted the Full Fidelity Change Feed (AllVersionsAndDeletes) APIs to GA. See [PR 49283](https://github.com/Azure/azure-sdk-for-java/pull/49283)
| { | ||
| "code": "java.annotation.removed", | ||
| "new": "enum com.azure.cosmos.models.ChangeFeedOperationType", | ||
| "justification": "Promoting ChangeFeedOperationType enum from Beta to GA - see issue #48959." |
There was a problem hiding this comment.
We don't need this new rule, we can use the existing one above and add enum to it. Would that not work?
Promote Full Fidelity Change Feed (AllVersionsAndDeletes) APIs to GA
Removes @beta from FFCF / AllVersionsAndDeletes public APIs. The deprecated fullFidelity / createFullFidelityPolicy / createIncrementalPolicy / getFullFidelityRetentionDuration methods are intentionally kept for back-compat. ChangeFeedMode.FULL_FIDELITY enum is also kept (continuation token wire format).
Resolves #48959
Description
Please add an informative description that covers that changes made by the pull request and link all relevant issues.
If an SDK is being regenerated based on a new swagger spec, a link to the pull request containing these swagger spec changes has been included above.
All SDK Contribution checklist:
General Guidelines and Best Practices
Testing Guidelines