Skip to content

Commit ba9f3be

Browse files
authored
Fix row deduplication issues (#294)
## Description of Changes Addresses clockworklabs/SpacetimeDBPrivate#1585 There was an issue with row deduplication when a TransactionUpdate of the form: ``` + k1: v1 - k1: v1 - k1: v1 + k1: v2 ``` appeared, where `k1` is the primary key of a row and `v1`, `v2` are the full values of that row. The old manner of processing updates would see this as a no-op. I've updated the logic to handle this case correctly, at the cost of an extra equality comparison per row in an update. (Actually it's slightly cheaper than this, it skips the equality comparison if there is only row with a particular primary key in an update. This may help speed up processing of large updates e.g. chunk data in BitCraft.) ## API - [ ] This is an API breaking change to the SDK *If the API is breaking, please state below what will break* ## Requires SpacetimeDB PRs ## Testsuite SpacetimeDB branch name: master ## Testing - [x] Added a failing test, then fixed it
1 parent fda3685 commit ba9f3be

File tree

2 files changed

+542
-87
lines changed

2 files changed

+542
-87
lines changed

0 commit comments

Comments
 (0)