Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Timestamp to the SDK, moving it out of client_api #114

Draft
wants to merge 25 commits into
base: main
Choose a base branch
from

Conversation

gefjon
Copy link
Contributor

@gefjon gefjon commented Oct 16, 2024

Description of Changes

Companion to SpacetimeDB#1836.

Based off #109

API

  • This is an API breaking change to the SDK

Type of ReducerEvent.timestamp is changed, methods on Timestamp are different, and WS API is updated.

Requires SpacetimeDB PRs

List any PRs here that are required for this SDK change to work

Copy link

changeset-bot bot commented Oct 16, 2024

🦋 Changeset detected

Latest commit: b92b505

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@clockworklabs/spacetimedb-sdk Patch
@clockworklabs/test-app Patch
client-vite Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

pkg-pr-new bot commented Oct 16, 2024

Open in Stackblitz

pnpm add https://pkg.pr.new/@clockworklabs/spacetimedb-sdk@114

commit: b92b505

Base automatically changed from gzip to main October 23, 2024 16:57
From SpacetimeDB 072c2ea3a32a6cf6d05ecf1ac9c9b54a4f95e340:

Prioritize BSATN and BFLATN compat with 0.12

Timestamp and TimeDuration store `micros: i64`, not `nanos: i64`.
This means that old commitlogs and snapshots should still be compatible,
assuming they don't include timestamps greater than `i64::MAX`,
as previously we used `micros: u64`. This seems unlikely.
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.

2 participants