1
0
mirror of https://github.com/aziascreations/BakaShrot.git synced 2026-11-23 20:58:46 +01:00

Fixed two peers sending the same attachment at once, Noted the stream limits, Removed the PureBasic-era leftovers

- An attachment is received from one peer at a time: the others are
  refused NotReady and ask again at their next sync; one cut short lets
  the next one take it over
- A 'replicating' row with all its bytes but never checked is asked
  again from part 0, and a peer asking from the wrong part resets it
- Noted the stream limit (1,048,575 topic/node pairs, 2^43-1 message ids
  each) in the example config and known-issues.md
- Removed NoDefaultTopic (code 6, retired), Writer::vacuum, the v8
  detection and the old ini key tests
- Cleared the PureBasic-era notes from the docs, revamp.md keeping only
  the old open items still unfixed; noted the GUI explorer (egui)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-16 17:23:33 +01:00
parent 764bc3652a
commit a5a2f65442
38 changed files with 436 additions and 907 deletions
+3 -19
View File
@@ -15,7 +15,7 @@ Decided in `../revamp.md`, "Decided".
| `[replication]` | the servers it sends to and takes from, retry and sync pace, batch size |
| `[roles.<name>]` | what certificates with that role may do |
Unknown keys are refused, so a typo or a key of the old ini is caught.
Unknown keys are refused, so a typo is caught.
## Who's who: certificates, then roles
@@ -100,27 +100,11 @@ file's order, else `"*"`'s line wherever it is; without any, it's kept
forever. Ages count from when a message was first pushed, on whichever
server; each server has its own.
## What changed from the old ini
| Old (`OldSource/Server/Config/schema.ini`) | Now |
|---|---|
| `PrivateKey`, `[BakaShrot] Node` | `ca`, `certificate`, `key`: the node is the certificate's name |
| `[BakaShrot.Client.*]`: keys, `Node`, `Allow*` | `[roles.*]`, the node and roles from the certificate |
| `[BakaShrot.Peer.*]`: `Host`, `Port`, `Node`, `PublicKey`, topic and node lists | `[replication] push_to` and `accept_from` (addresses), the lists in the peer's roles |
| `ReplicatingTopics` | each peer role's `send_topics` / `accept_topics` |
| topic and node ids, pins, ranges, `[BakaShrot.Nodes]` | names only: ids are the database's |
| `DefaultTopic` | dropped: a push always names its topic |
| `Host` + `Port` | `listen` |
| seconds | durations (`"10s"`) |
| `NetThreadPoolSize` | gone (tokio) |
| `UploadTimeout` | gone: attachments are streamed in their push (protocol 7), nothing waits |
| `FULL` / `NORMAL` | `"full"` / `"normal"`; `off` still refused |
## Tests
`crates/bakashrot-config/tests/config.rs`: the example, the defaults,
every setting, retention's order, permissions (several roles, none known,
replication per role), the topic lists that are gone, paths from the config's
folder, and the refusals, each with its line: TOML errors, unknown keys
(the old ini's too), every value that's wrong, names twice (without case),
folder, and the refusals, each with its line: TOML errors, unknown keys,
every value that's wrong, names twice (without case),
unquoted dotted names.