Yes, the rumors are true - it's release day! :tada: :tada:
We're gearing up for our big 1.0 release later this year, so this release has some great foundational API improvements, improves consistency across ours APIs, and adds some other fantastic foundational features!
Highlights
- Bumped to Rust 1.78
- We now regularly capture a snapshot of the database state, and restore from it when restarting the Database
- Tables are now private by default, and must be explicitly marked as
publicvia#[spacetimedb(table(public))]or[SpacetimeDB.Table(Public = true)] - Our SDKs now have consistent
filter_by_*functions that return a collection of results, andfind_by_*functions that return a single result - Implement a new rand api which fixes bugs in our previous random number generator
- Bugfix: When the database is restarted, we properly treat all clients as disconnected
Big ones!
- Module hotswapping - You can now update your server logic with a new module without disconnecting existing clients! Players will keep on playing and clients will keep on clienting without being any the wiser!
- Recv-style ABI - We've improved the performance of passing data into your module from the host substantially by eliminating several allocations and copies.
CLI changes
spacetime builduses the--project-pathparam instead of an anonymous paramspacetime publish -crequires confirmation (can be overridden with--force)spacetime logs -fdoes not start from the very beginning
What's Changed
impl PartialEq<ProductValue> for RowRefby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1164- Use a custom
FixedBitSet+ optimizePage::iter_fixed_lenby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1160 - Implement
RelValue: Eq + Hashby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1107 - Fix soundness hole in
Table::delete+ don't make & immedately drop PVs in the method by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1162 - Add PR status check that fails unless based on
masterby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1180 - Some clarifications to dropping the updates in eval incr by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1192
- perf(
JoinInner): use AVs for keys instead of PVs by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1194 - Make
Pagealways fully init by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1193 - Remove C# GetArgsAsObjectArray by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1188
- feat(1168): Track subscription query duration for each reducer by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1195
- Fix unsoundness in
AlgebraicValue::type_ofby making it partial by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1189 - From.{join => joins} + remove Option layer + Remove RelOps::try_fold by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1208
- subscription benches: reorder footprint fields by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1209
- C#: rename DbEventArgs to ReducerContext by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1191
- Bump to Rust 1.78 by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1205
spacetime builduses--project-pathparam by @jdetter in https://github.com/clockworklabs/SpacetimeDB/pull/1212- Remove some impls that were dead code by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1210
- CrudExpr::{Delete, Insert, Update}: only DbTables are possible, so cleanup InMem path by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1211
- Remove RowUpdate event from C# by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1190
- Switch to a better API for tagged enums for C# by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1177
- Remove a few dead impls by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1214
- commitlog: Allow folds to not allocate
Mutationsvalues by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1215 - Fix #1180: Add PR status check that fails unless based on master by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1213
- Split up #735:
auth.rsrefactors by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/871 - Create a lockfile when opening config files by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1196
- Bump version to 0.9.0 by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1055
- Add CODEOWNERS for
rust-toolchain.tomlby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1221 - Fix select * from * by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1218
- CLI - Small refactors to identity code by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1169
- Add CODEOWNERS for
LICENSE.txtby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1225 - Add
CODEOWNERSforCODEOWNERSby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1226 spacetime publish: Add confirmation for-cby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1038- Make identity naming more consistent + fix bugs by @jdetter in https://github.com/clockworklabs/SpacetimeDB/pull/1140
- feat(1229): Double client channel capacity by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1230
- to_bsatn_extend/vec: use uninit instead of zeroed buffer by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1204
- refactor compile_read_only_query: dedup SideEffect errors by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1235
- Add test for
select * from B join A on B.y = A.xby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1238 - Always send TransactionUpdate to the sender by @drogus in https://github.com/clockworklabs/SpacetimeDB/pull/1111
- row_count field to table by @Shubham8287 in https://github.com/clockworklabs/SpacetimeDB/pull/1242
- Simplify
MutTxId::table_existsby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1246 - Remove unreachable branches from C# generate by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1247
Table::get_fixed_row->RowRef::get_row_data+ Some docs by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1250- Move
StaticBsatnLayoutcode to its module + harden test by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1254 - Remove
BTreeIndex::nameagain by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1251 - Atomically downgrade lock when committing tx to prevent deadlock by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1252
- Tiny change: slightly better logging of sled errors by @kazimuth in https://github.com/clockworklabs/SpacetimeDB/pull/1248
- Add
PageHeader::unmodified_hash, a BLAKE3 hash for snapshotting by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1249 - Privatize
Table::row_layout+ relatedBTreeIndexrefactoring by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1262 - core: Collapse DBIC into HostController by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1186
- Reserve sequence range for system tables by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1265
- Add
fn ColList::last(&self) -> ColIdby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1267 - Misc datastore cleanups & less cloning by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1263
- Module hotswapping by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1147
- Consistent filtering rules for Rust bindings by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1280
- recv-style abi by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1002
- feat(1231): Basic query cardinality estimation by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1273
- Simplify
btree_indexmodule with more idiomatic Rust by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1285 - Disconnect dangling clients by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1132
- CI workflows support
workflow_dispatchevent by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1289 - Remove
incremental-joins.mdby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1296 - Add table smoketest + more smoketest logging by @kazimuth in https://github.com/clockworklabs/SpacetimeDB/pull/1272
- Fix
workflow_dispatchfor ci.yml by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1295 - Shub/st connected clients by @Shubham8287 in https://github.com/clockworklabs/SpacetimeDB/pull/1288
- Let ProgramStorage::external be async by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1291
- due cleanup in datastore test by @Shubham8287 in https://github.com/clockworklabs/SpacetimeDB/pull/1301
- fix(1297):
spacetime logs -fshould not start at the very beginning by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1298 merge_apply_inserts/deletes: do metrics work once per table, not per row by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1286- Consistent filtering in Rust client + minor fixes by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1275
- Implement consistent filtering rules for C# modules by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1282
- Update C# codegen to consistent filtering rules by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1277
- Implement consistent filtering rules for TypeScript by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1276
- CLI - Fix
Lockfileerror message format strings by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1302 - CLI - Drop Config lock earlier for
spacetime logsby @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1303 - Facilitate eventual datastore crate by reducing visibilities and simplifying imports by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1306
- Commitlog: panic on fsync failure by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/985
execution_set.check_auth(...)on initial subscription by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1274- Refactor
check_auth+(walk_)sourcesusing internal iteration in the latter by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1304 - Bump version to 0.9.3 by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1224
- feat(1231): Add a configurable row limit for queries by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1293
- NFC: use record struct for auto-equality in C# by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1318
- Fix FilterBy regression in C# by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1309
- Bump ABI version for C# AOT by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1311
- Implement new rand api by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1283
- metric for table size by @Shubham8287 in https://github.com/clockworklabs/SpacetimeDB/pull/1319
- Automated bot tests by @kazimuth in https://github.com/clockworklabs/SpacetimeDB/pull/1255
- Restrict multi-col index scans to
=(OpCmp::Eq) on all columns by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1316 - Re-add execute_sql_mut_tx by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1313
- Tables only become public explicitly via
#[spacetimedb(table(public))]by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1278 IndexJoin/JoinInner: storeColIdby @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1166- More trace logs for TX locking by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1253
- Split
ColumnOpinto one with row indices and one withFieldName& other enabled changes by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1207 - Flatten
ColumnOp, avoiding allocation in the common case by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1234 - Fix commitlog
fold_transactions_fromignoring requested offset by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1330 - Jeremie/notify sql by @lcodes in https://github.com/clockworklabs/SpacetimeDB/pull/1198
- Impl
Serialize,DeserializeforPageby @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1335 - Create new crate
fs-utils; moveLockfileandcreate_parent_dirby @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1334 - Make both TX offset counters agree by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1332
- commitlog: Make bitflip test a proptest by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1333
- Make
update_databaseinsensitive to table access changes by @Centril in https://github.com/clockworklabs/SpacetimeDB/pull/1338 - Define
DirTrie, a git-like on-disk object store by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1336 - Add the
snapshotcrate, which implements snapshotting at a low level by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1340 - Fix bug with
Lockfilesticking around by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1341 - chore: fix typos by @xiaoxianBoy in https://github.com/clockworklabs/SpacetimeDB/pull/1241
- Fix
Config.savefailing if/tmpis on a different filesystem by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1346 - feat(1329): System table for system variables by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1342
- Update quickstart modules to have public tables by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1348
- Shared C# codegen for BSATN by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1312
- Prune bindings deps by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1290
- feat: System table based slow query logging by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1350
- Add Jenkinsfile to run internal automation by @kurtismullins in https://github.com/clockworklabs/SpacetimeDB/pull/1232
- fix(1353): Remove underscore based table access checks by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1354
- core: Store address, owner and program bytes in st_module by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1305
- test(1329): Row limit from system table by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1355
- Add explicit parameter for table visibility by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1359
- Bump version to 0.10.0 by @bfops in https://github.com/clockworklabs/SpacetimeDB/pull/1349
- Fix output of binary, Identity, Address for
SQLoutput and the 'Display' of them to show a full hex value by @mamcx in https://github.com/clockworklabs/SpacetimeDB/pull/1087 - Integrate snapshotting into core by @gefjon in https://github.com/clockworklabs/SpacetimeDB/pull/1344
- core: Determine dangling clients from
st_clientsby @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1366 - durability: Skip fsync if nothing changed by @kim in https://github.com/clockworklabs/SpacetimeDB/pull/1360
- [C#] Add Roslyn shapshot tests by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1399
- chore: Remove max value metrics by @joshua-spacetime in https://github.com/clockworklabs/SpacetimeDB/pull/1402
- [NFC] [C#] Minor simplifications to type checks in Roslyn codegen by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1400
- Add Option SDK tests by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1405
- [C#] [NFC] Use semantic model's type where possible by @RReverser in https://github.com/clockworklabs/SpacetimeDB/pull/1401
- Fix auth regression by @coolreader18 in https://github.com/clockworklabs/SpacetimeDB/pull/1413
New Contributors
- @lcodes made their first contribution in https://github.com/clockworklabs/SpacetimeDB/pull/1198
- @xiaoxianBoy made their first contribution in https://github.com/clockworklabs/SpacetimeDB/pull/1241
Full Changelog: https://github.com/clockworklabs/SpacetimeDB/compare/v0.9.2-beta...v0.10.0-beta
