Skip to content

Commit

Permalink
Include sync order snapshot for postgres
Browse files Browse the repository at this point in the history
  • Loading branch information
simolus3 committed Feb 10, 2025
1 parent 2e17504 commit db9ebac
Show file tree
Hide file tree
Showing 2 changed files with 74 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,80 @@ exports[`sync - postgres > expiring token 2`] = `
]
`;

exports[`sync - postgres > sync buckets in order 1`] = `
[
{
"checkpoint": {
"buckets": [
{
"bucket": "b0[]",
"checksum": 920318466,
"count": 1,
"priority": 2,
},
{
"bucket": "b1[]",
"checksum": -1382098757,
"count": 1,
"priority": 1,
},
],
"last_op_id": "2",
"write_checkpoint": undefined,
},
},
{
"data": {
"after": "0",
"bucket": "b1[]",
"data": [
{
"checksum": 2912868539n,
"data": "{"id":"earlier","description":"Test 2"}",
"object_id": "earlier",
"object_type": "test",
"op": "PUT",
"op_id": "2",
"subkey": "243b0e26-87b2-578a-993c-5ac5b6f7fd64",
},
],
"has_more": false,
"next_after": "2",
},
},
{
"partial_checkpoint_complete": {
"last_op_id": "2",
"priority": 1,
},
},
{
"data": {
"after": "0",
"bucket": "b0[]",
"data": [
{
"checksum": 920318466n,
"data": "{"id":"t1","description":"Test 1"}",
"object_id": "t1",
"object_type": "test",
"op": "PUT",
"op_id": "1",
"subkey": "02d285ac-4f96-5124-8fba-c6d1df992dd1",
},
],
"has_more": false,
"next_after": "1",
},
},
{
"checkpoint_complete": {
"last_op_id": "2",
},
},
]
`;

exports[`sync - postgres > sync global data 1`] = `
[
{
Expand Down
8 changes: 0 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,5 @@
"vite-tsconfig-paths": "^4.3.2",
"vitest": "^2.1.1",
"ws": "^8.2.3"
},
"pnpm": {
"ignoredBuiltDependencies": [
"esbuild"
],
"onlyBuiltDependencies": [
"esbuild"
]
}
}

0 comments on commit db9ebac

Please sign in to comment.