Add event-window delta support for calendar views #7

Closed
opened 2026-07-09 16:22:27 +02:00 by zemion · 1 comment
Owner

Calendar views currently load GET /api/v1/calendar/events as a date-window snapshot. Private ETags reduce unchanged reload payloads, but high-volume calendars still need section/window deltas once event counts grow.

Scope:

  • Add calendar event change-sequence recording for create/update/delete/import/sync writes.
  • Add GET /api/v1/calendar/events/delta scoped by calendar id and start/end window.
  • Return changed events, tombstones for events leaving the visible window, watermark, has_more, and full.
  • Use full snapshots when recurrence expansion, sync-token expiry, or window/filter changes make incremental replay unsafe.
  • Keep the existing /events snapshot endpoint for compatibility and ETag support.
  • Update the calendar WebUI reload path to prefer deltas for the active window.
  • Add smoke tests for create, update moving an event out of the window, delete tombstones, and stale-watermark fallback.

Related platform work: govoplan-core#222.

Calendar views currently load `GET /api/v1/calendar/events` as a date-window snapshot. Private ETags reduce unchanged reload payloads, but high-volume calendars still need section/window deltas once event counts grow. Scope: - Add calendar event change-sequence recording for create/update/delete/import/sync writes. - Add `GET /api/v1/calendar/events/delta` scoped by calendar id and start/end window. - Return changed events, tombstones for events leaving the visible window, `watermark`, `has_more`, and `full`. - Use full snapshots when recurrence expansion, sync-token expiry, or window/filter changes make incremental replay unsafe. - Keep the existing `/events` snapshot endpoint for compatibility and ETag support. - Update the calendar WebUI reload path to prefer deltas for the active window. - Add smoke tests for create, update moving an event out of the window, delete tombstones, and stale-watermark fallback. Related platform work: govoplan-core#222.
Author
Owner

Implemented and verified calendar event-window deltas.

Changes:

  • Added calendar event change-sequence recording for local create/update/delete and common import/sync write paths.
  • Added GET /api/v1/calendar/events/delta scoped by calendar and date window, with changed events, tombstones, watermark, has_more, and full fallback on expired watermarks.
  • Updated the Calendar WebUI reload path to prefer event-window deltas for the active date range.
  • Added smoke coverage for create replay, moving an event out of the visible window, visible delete tombstones, and stale-watermark fallback.

Verification: test_calendar_event_window_delta_tracks_moves_deletes_and_stale_watermarks passes.

Implemented and verified calendar event-window deltas. Changes: - Added calendar event change-sequence recording for local create/update/delete and common import/sync write paths. - Added `GET /api/v1/calendar/events/delta` scoped by calendar and date window, with changed events, tombstones, `watermark`, `has_more`, and full fallback on expired watermarks. - Updated the Calendar WebUI reload path to prefer event-window deltas for the active date range. - Added smoke coverage for create replay, moving an event out of the visible window, visible delete tombstones, and stale-watermark fallback. Verification: `test_calendar_event_window_delta_tracks_moves_deletes_and_stale_watermarks` passes.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: add-ideas/govoplan-calendar#7
No description provided.