Skip to content

Conversation

@VeskeR
Copy link
Contributor

@VeskeR VeskeR commented Jan 16, 2026

BufferedObjectOperations should only be cleared when ATTACHED with RESUMED flag not set is received or on sync completion, not when a new sync sequence ID arrives. This is because the server caches object state at channel attachment time, not at the start of a sync sequence.

Resolves AIT-286

See ably-js implementation ably/ably-js#2150

BufferedObjectOperations should only be cleared when ATTACHED with RESUMED
flag not set is received or on sync completion, not when a new sync
sequence ID arrives. This is because the server caches object state at
channel attachment time, not at the start of a sync sequence.

Resolves AIT-286
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the BufferedObjectOperations clearing behavior for LiveObjects synchronization by ensuring operations are cleared at the correct time based on when the server caches object state.

Changes:

  • Added RTO4d to specify that BufferedObjectOperations must be cleared when ATTACHED is received without the RESUMED flag, since the server caches object state at channel attachment time
  • Added RTO5f as an explanatory note describing the expected and edge-case behaviors for server-initiated resyncs
  • Deleted RTO5a2b which previously required clearing BufferedObjectOperations when a new sync sequence ID arrived

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

*** @(RTO5a2)@ If a new sequence id is sent from Ably, the client library must treat it as the start of a new objects sync sequence, and any previous in-flight sync must be discarded:
**** @(RTO5a2a)@ The @SyncObjectsPool@ list must be cleared
**** @(RTO5a2b)@ The @BufferedObjectOperations@ list must be cleared
**** @(RTO5a2b)@ This clause has been deleted
Copy link

Copilot AI Jan 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The deleted clause statement should end with a period for consistency with other deleted clauses in the specification (see RSN4c, TS3, etc. in features.textile).

Suggested change
**** @(RTO5a2b)@ This clause has been deleted
**** @(RTO5a2b)@ This clause has been deleted.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants