Skip to content

RDBC-1243 RavenDB-28134 Keep subscription settings on create, update, import and restore - #333

Open
poissoncorp wants to merge 1 commit into
ravendb:v7.2from
poissoncorp:sdk-sync/RDBC-1243
Open

poissoncorp wants to merge 1 commit into
ravendb:v7.2from
poissoncorp:sdk-sync/RDBC-1243

Conversation

@poissoncorp

Copy link
Copy Markdown
Contributor

Subscriptions can now be created and updated with disabled, pin_to_mentor_node and archived_data_processing_behavior, and SubscriptionState reports the last two.

  • Changed: new ArchivedDataProcessingBehavior enum (ravendb/documents/data_archival.py, exported from ravendb); the three settings on SubscriptionCreationOptions and SubscriptionUpdateOptions; pin_to_mentor_node and archived_data_processing_behavior on SubscriptionState. Update sends a setting only when it is not None, so the server keeps the stored value.
  • Not ported: the import, backup restore and snapshot restore fixes and their tests. They are server code with no client change.
  • Tests: test_ravenDB_28134.py has the create and update tests of RavenDB_28134 (single database only, the test base has no sharded mode) and request body tests that need no server.
  • Checks: black --check passed; the request body tests passed. The server tests run only in CI. test_update_can_change_archived_data_processing_behavior needs a 7.2 nightly with RavenDB-28134.
  • Follow-up: RDBC-1244, create_for_options_autocomplete_query shares one default options object between calls.

Decision needed

Before this change, the Python client never sent these three settings. Most of this PR adds them; the C# change itself is small. The enum is the first data archival type in the client, placed after the C# namespace Raven.Client.Documents.DataArchival.

  • Merge as is (recommended): the settings match the C# and Node.js clients, and the C# fix cannot apply without them.
  • Do not merge: subscriptions in the Python client keep their current behavior and these settings stay unavailable.

Ticket: RDBC-1243
C# change: ravendb/ravendb#24114

SDK Sync Agent

…ing behavior on subscription create and update
@poissoncorp poissoncorp added the sdk-sync Port of C# client changes from an SDK sync task label Dec 1, 2026
@poissoncorp

Copy link
Copy Markdown
Contributor Author

The failing checks are not caused by this PR. Re-running the workflow with a current nightly server is the only step needed.

  1. test_update_can_change_archived_data_processing_behavior fails on all five builds. It needs the server fix from RavenDB-28134 Keep subscription settings on create, update, import and restore ravendb#24114: the update handler used to overwrite ArchivedDataProcessingBehavior with the stored value, and now keeps the value the client sends. That PR was merged at 10:59 UTC on 2026-12-01. The CI run started at 12:05 UTC and downloaded the nightly server, which most likely does not contain the fix yet. The client sends the value correctly: TestSubscriptionOptionsJson.test_update_sends_settings_that_are_set passes.
  2. TestSecuredSubscriptionBasic times out waiting for a batch on 3.10 and 3.13 only. The same code passes on 3.11, 3.12 and 3.14, and the test does not use the new settings, so this looks like a flaky failure.

Checks run locally: black --check . passed, TestSubscriptionOptionsJson passed (4 tests). Tests that need a server run only in CI.

SDK Sync Agent

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

sdk-sync Port of C# client changes from an SDK sync task

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant