mirror of
https://github.com/Zakkaus/doona.git
synced 2026-12-05 08:00:59 +00:00
## Problem / 问题 The README already lists dae as a backend, but doona treated every backend as honk. Against dae's native API every probe failed with 422 (dae accepts only cold probes, `component/nativeapi/handlers_probes.go:85-89`), mode switching, rule templates and new groups were always off because dae keeps the entry file read-only and the sections in `config.d` modules, group edits wrote honk's policies and filters that dae rejects, and messages said honk. ## How I fixed it / 解决方法 A dae engine profile (`src/api/engines/dae.ts`) holds what differs, and the pages ask the engine instead of assuming honk. Probes send cold and offer the kinds dae declares. Writes go to the module that owns the section, falling back to `config.d/group.dae` as dae does (`cmd/config_groups.go:103-115`). The group dialog follows dae's grammar: its policies, no nested groups or `subtag(keyword: …)`, names dae can parse and does not rewrite (`must_`), `&&` continuation lines and latency annotations kept, `fixed`/`select` index within the members. Node delete is offered only for `config.d/node.dae`, the one file dae's DELETE edits. Messages name the running backend. honk keeps its behaviour and wording. Not fixed here, dae side: rules report `source: null` (so the rules page stays read-only), groups advertise empty `probe_transports` (so group-wide tests stay off), and `read_only_reason` values `entry_source`/`layout_unmanaged` are not in the contract enum. dae publishes `operation.updated` for every probe job, which fills the notices; honk publishes the same event, so it is left as it is. ## Verified / 验证 `pnpm check` passes (254 files, 4,470 tests). The full e2e suite ran once at the last code state but two: 10 failures, all from expected text (fixed in this commit) and from a notice change that is reverted here; the rerun was stopped by host memory pressure, so CI's e2e is the final check. Group text written for dae was parsed with dae's own Go parser (`config_parser.Parse` + `config.New`). Live against dae `0d85246` on a test VM: nodes, single and all-node probes (cold, healthy nodes 8–14 ms, a dead node unavailable), new group written to `group.dae` and reloaded, global and rule mode written to `routing.dae` and reloaded, configuration page, DNS, logs and connections. That live run predates the last two fixes (policy labels, `must_` and index checks), which are covered by unit tests only. No honk screen changes. | Nodes after test all | Global mode written | Entry file read-only | |---|---|---| |  |  |  | --- - [x] I understand this change and answer for every line - [x] This branch is based on the current main - [x] I ran the repository's gates and recorded the results in Verified - [x] Each commit is one coherent change - [x] If behaviour changed, I updated the documentation - [x] If interface text changed, I updated `en.json` and every complete language's catalogue - [ ] If interface appearance changed, I attached light and dark screenshots - [ ] If the API contract changed, I ran `pnpm gen:api` and `pnpm check:gen` - [ ] I checked the boxes above without reading them - [ ] I am an AI agent, and this content was submitted without human review
549 B
549 B
Fixed
- On dae, node and group probes send cold probes, which dae accepts, instead of failing with 422, and offer the probe kinds dae declares.
- On dae, the outbound mode, rule templates and new groups write to the module that owns the section, in dae's syntax and with dae's policies.
- On dae, node delete is offered only where dae deletes, filters continued on a
&&line stay one filter, andrandomgroups are no longer shown as manual selectors. - Reload, suspend and other messages name the running backend instead of always saying honk.