Skip to content

Version Packages - #3

Merged
gingerhendrix merged 1 commit into
mainfrom
tegami/version-packages
Oct 23, 2026
Merged

gingerhendrix merged 1 commit into
mainfrom
tegami/version-packages

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Summary

All bumped packages.

Package From To
@streamsy/core 0.4.0 0.5.0
@streamsy/projection 0.4.0 0.5.0
@streamsy/serve 0.4.0 0.5.0
@streamsy/storage 0.4.0 0.5.0

Changelogs

state-control-messages.md

Show Bumped Packages (4)
Package Bump
npm:@streamsy/core minor
npm:@streamsy/projection minor
npm:@streamsy/serve minor
npm:@streamsy/storage minor

Durable State control messages

Breaking change: the item type of a State address now includes control messages. Code that reads type, key or headers.operation from a State item must narrow the item first.

A State stream can now hold the control messages of the Durable State protocol: snapshot-start, snapshot-end and reset. Before this release, StreamAddress.state failed to decode a stored control. Streams.decode then failed the whole batch with a DecodeFault, and a follow or projection on that address stopped.

  • StreamAddress.state decodes and encodes controls. The items of a StateAddress, a Streamsy.state route and Serve.state have the new type StreamAddress.CollectionsEvent<C>. That type is CollectionsChange<C> | StateControl. It was CollectionsChange<C>.
  • StreamAddress.isControl and StreamAddress.isChange narrow an item. StreamAddress.reset(), StreamAddress.snapshotStart() and StreamAddress.snapshotEnd() make a control. Each one takes an optional { offset }.
  • StreamAddress.stateControl is the codec for one control. StreamAddress.stateChange stays the codec for the changes of one collection.
  • DurableState.changes and projection outputs accept DurableState.Entry<C>, which is a row change or a control. A control is written unchanged. With an offset, a control that has no offset gets that offset.
  • Serve.state serves stored controls as they are. It still refuses the x-streamsy-state-reset: snapshot request header.

To migrate a reader that folds State items, skip controls or handle them:

if (StreamAddress.isControl(item)) {
  if (item.headers.control === "reset") rows.clear();
} else if ("value" in item) rows.set(item.key, item.value);
else rows.delete(item.key);

Publish

The following packages will be published if merged:

Package Version Registry
@streamsy/core 0.5.0 npm
@streamsy/projection 0.5.0 npm
@streamsy/serve 0.5.0 npm
@streamsy/storage 0.5.0 npm

@github-actions
github-actions Bot force-pushed the tegami/version-packages branch from 6943071 to e9f043d Compare October 22, 2026 23:08
@gingerhendrix
gingerhendrix merged commit 2d57ad1 into main Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant