Zero 1.8

Operational Visibility and Reliability

Installation

npm install @rocicorp/zero@1.8

Overview

Zero 1.8 focuses on operational visibility, production reliability, and performance under large replication and query workloads.

Features

  • Request header forwarding: zero-cache can now forward allowlisted headers from the incoming HTTP request to query and mutate endpoints. This is useful for server-injected proxy or load-balancer headers such as x-forwarded-for that clients cannot safely set themselves. (#6144) (thanks @tjenkinson!)
  • GHCR Docker images: Zero Docker images are now published to ghcr.io/rocicorp/zero in addition to Docker Hub. (#6161)
  • View-syncer serving lag metrics: Added zero.sync.serving-lag, zero.sync.serving-lag-stats, and zero.sync.serving-lagging-client-groups so operators can see when replica data is ready locally but has not finished serving to active client groups. (#6157) (thanks @tantaman!)
  • Initial sync metrics: Added OpenTelemetry metrics and structured logs for initial-sync runs, COPY time, SQLite flush time, index creation time, copied rows, copied bytes, chunks, sync mode, copy format, and outcomes. (#6191)
  • Litestream v0.5 backup cleanup: Added an opt-in path for backing up with Litestream v0.5.x and reading verified cleanup watermarks through the Litestream SQLite VFS. (#6146) (thanks @tantaman!)

Performance

  • Large upstream transactions persist to the CDC changeLog about 13x faster in local pg-16 benchmarks, with much lower transient heap usage, by batching change-log writes through json_to_recordset. (#6142)
  • Common in-memory ZQL fetch shapes are 1.4x-2.0x faster by collapsing the MemorySource generator stack in the common no-overlay/no-start/no-connection-filter path. (#6127)
  • Take-window maintenance fetches on ordered SQLite sources can avoid planner-hostile partition scans by adding seekable leading-column bounds for non-null sort columns. (#6184) (thanks @tantaman!)

Fixes

Breaking Changes

None.