7 Commits
Author SHA1 Message Date
dualfroz 4cacfcec7b Describe this repository 2026-10-22 21:07:58 +02:00
dualfroz 9bdd4a2024 feat: Make typo factor configurable
Fixes https://github.com/valeriansaliou/sonic/issues/394.
2026-10-10 12:42:09 +02:00
dualfroz 73692bcfdb fix(core): Back up and restore FST buckets again
Since 27a1b2b ("chore(core): Flatten FST store code"), the bucket loop in
`FstStorePool::dump_action` checked the type and name of the collection
entry instead of the bucket entry. As a collection is a directory, every
bucket was skipped: `TRIGGER backup` answered `OK` but wrote no FST, and
`TRIGGER restore` restored none.

Add a test which backs up a consolidated FST and restores it.
2026-10-03 17:33:05 +02:00
dualfroz 51a00dd099 fix(core): Make TRIGGER backup work while stores are in use
`TRIGGER backup` answered `ERR internal_error` in two common cases:

- a KV store was open in the pool (e.g. right after a `PUSH`): the backup
  opened the database a second time, which RocksDB refuses as its `LOCK`
  file is held. The pooled store is now backed up instead, after a flush.
- the KV or FST store directory did not exist yet (nothing ingested, or
  nothing consolidated yet): listing it failed. There is nothing to back up
  in that case.

Also enable the `trigger_backup` test, which covers both cases.

Fixes #274
2026-10-03 14:05:56 +02:00
dualfroz e7def56ff0 docs: Document the 128 characters limit on collection, bucket and object names
Values longer than 128 bytes or with non-ASCII characters are rejected by
`StoreItemPart::from_str` with `ERR invalid_argument(...)`, but the
protocol did not say so.

Closes #319
2026-10-03 15:36:07 +02:00
dualfroz c4a1a7ead6 docs: explain write_buffer_size in MiB instead of asking for a multiple of 1024 2026-09-23 12:40:11 +02:00
dualfroz cb9cbacdd3 fix(server): Do not panic when a channel read fails
A read timeout or an abrupt client hang-up unwound the channel thread,
which flooded the logs with "closing channel" panics and skipped the
connected clients counter decrement, leaking a client slot each time.

Fixes #256
2026-09-13 15:38:27 +02:00