0
0
mirror of https://github.com/tursodatabase/libsql.git synced 2025-06-17 03:19:51 +00:00

20 Commits

Author SHA1 Message Date
7668db8be4 server: fix hrana error classification ()
* server: fix hrana error classification

* add new test snapshots

* more snapshots
2024-06-05 16:34:12 +00:00
0c730c439a Propagate schema migration errors correctly ()
* Update hecrj/setup-rust-action to v2

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Update rust-toolchain.toml to 1.78

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Propagate schema migration errors correctly

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

---------

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>
2024-05-21 11:53:42 +00:00
1fc0550a65 harden attach ()
* pass namespace path resolver to VM instead of hacky dir walking

* test attach forbidden in migration

* fmt
2024-03-14 15:31:38 +00:00
a2077c54ab Fix namespace deletion ()
* fix schema deletion

* optional ns delete payload
2024-03-14 11:35:20 +00:00
0d5dc18ce1 rename migration tables ()
* rename __libsql_migration_tasks to sqlite3_libsql_tasks

* rename job tables
2024-03-13 11:03:55 +00:00
a95bdf4d35 job status notifier & wait for dry run success () 2024-03-12 19:55:41 +00:00
fe2ebffe28 check schema migration auth () 2024-03-11 17:09:43 +00:00
1528128fce allow ddl override () 2024-03-11 15:00:26 +00:00
226fba9a12 Add tests for data migration in schema dbs ()
- Added a test which performs data migration including
  inserts, updates and deletes
- Added a test which shows that schema migration fails
  if there is any conflicting data in the linked dbs
2024-03-08 16:11:26 +00:00
ae708f8952 Fork a new DB when creating from shared schema ()
* Fork a new DB when creating from shared schema

* Use the correct db type to get the wal logger

* Add a test for a new db in shared schema

- When a new db is created with a shared schema, it should have
  the same schema and the schema version
- When a new migration is done, the new db and all the existing
  dbs should have the same schema and version

* Move schema db fork logic inside namespace mod

* clean up and remove unnecessary store call
2024-03-08 14:32:22 +00:00
c9ba69245e Handle dry run failure, and abort migration ()
* test snasphots

* add test

* handle dry run failure, and abort all tasks

* fmt
2024-03-08 11:01:32 +00:00
bf19f3e1d7 reject migration containing migration statements () 2024-03-06 18:12:45 +00:00
75321d56d3 use custom query builder to collect migration error ()
use custom query builder to collect migration error
2024-03-06 15:31:46 +00:00
8f897d510e Block writes during schema migration ()
* Add block_writes to Connection

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Add block_writes to PrimaryDatabase

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Use block_writes in Connection::run

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Unblock writes once migration is finished

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Block writes on startup if there are pending migration tasks

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* Block writes when a migration task is enqueued

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>

* twix

---------

Signed-off-by: Piotr Jastrzebski <piotr@chiselstrike.com>
Co-authored-by: ad hoc <postma.marin@protonmail.com>
2024-03-05 22:17:36 +00:00
2b06b6b7d8 schema migration ()
happy path schema migration
2024-03-04 13:15:29 +00:00
86b0328254 add test snapshot files 2023-10-31 17:10:59 +01:00
5d9fd529fc use abstract Replicator in libsql-server 2023-10-30 17:26:17 +01:00
4879f4ccc2 Revert "Revert "Same-thread frame injection ()" ()"
This reverts commit 85b3358a4d.
2023-10-30 17:25:28 +01:00
f15800793a re-enable embedded replica tests 2023-10-19 09:11:25 +02:00
71ca43a7b6 make sqld compile 2023-10-17 17:41:26 +02:00