JavaScript promise rejection: Loading CSS chunk index-domready failed.
(error: https://sirherobrine23.com.br/assets/css/index-domready.9de057c0.css). Open browser console to see more details.
* server: fix conflict on attach update
* add tests and add on conflict to other branch
* only error on server errors
* remove test query
* add more on conflicts fixes
* Revert "add more on conflicts fixes"
This reverts commit 9cef2d320e.
* remove replace for meta store inserts
- 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
* 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
* 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>
* added an endpoint to ask for a general migration status
* return detailed information about individual migration job progress
* integrated migrations API in tests
* post-rebase
* adjusted code after rebase
* libsql: attach databases from other namespaces as readonly
With this proof-of-concept patch, other namespaces hosted
on the same sqld machine can now be attached in readonly mode,
so that users can read from other databases when connected
to a particular one.
* connection: add allow_attach to config
Default is false, which means connections are blocked from attaching
databases. If allowed, colocated databases can be attached in readonly
mode.
Example:
→ attach another as another; select * from another.sqlite_master;
TYPE NAME TBL NAME ROOTPAGE SQL
table t3 t3 2 CREATE TABLE t3(id)
* libsql,namespaces: add client-side ATTACH support
* attach: support ATTACH x AS y aliasing
We're going to need it, because the internal database names in sqld
are uuids, and we don't expect users to know or use them.
* attach: fix quoted db names
In libsql-server, raw db names are uuids that need to be quoted,
so that needs to be supported in the ATTACH layer.
As a bonus, "names" that are actually file system paths are refused
to prevent abuse.
* libsql-server: drop stray serde(default) from allow_attach
* libsql-replication: update proto files
* libsql-replication: regenerate protobuf
* tests: move attach to its own test
* libsql-replication: fix proto number after rebase
This adds a new `Builder` type that can now be used to construct the
`Database` type. This will scale better as we add more varied options.
This commit also deprecates the old builder types and will produce a
warning that will push users to using the new `Builder` type. This will
then allow us to remove the old deprecated constructors at some point in
the future.
This PR adds a new internal metadata store for namespace configuration.
This internally uses a normal namespace so that the replica also get's
synchronized. This is just initial work there are a few more issues to
solve regarding replica's getting updated configs and some internal
hardening that needs to be done. Tracking issue for follow up work #768.
Closes#501