Skip to content

feat(webapi): expose MMapEnabled preference (capability-gated) - #566

Merged
got3nks merged 1 commit into
amule-org:masterfrom
got3nks:feat/amuleapi-mmap
Jul 23, 2026
Merged

feat(webapi): expose MMapEnabled preference (capability-gated)#566
got3nks merged 1 commit into
amule-org:masterfrom
got3nks:feat/amuleapi-mmap

Conversation

@got3nks

@got3nks got3nks commented Jul 23, 2026

Copy link
Copy Markdown

Follow-up to #565 — surfaces the runtime memory-mapped file I/O preference on the REST API.

  • files.mmap_supported — read-only daemon capability (mirrors connection.upnp_available), read from the EC_TAG_FILES_MMAP_SUPPORTED tag the core advertises only when built with mmap support. Ignored if sent on PATCH.
  • files.mmap_enabled — the runtime value. A PATCH that sets it is rejected with 409 conflict when files.mmap_supported is false, so the option is only writable against a core that can actually use it (Windows / -DENABLE_MMAP=OFF daemons reject it rather than silently dropping the tag).

mmap covers all buffered block I/O — download writes to part files, upload reads of both shared (completed) and partial files, and hashing — so it's not limited to incomplete files.

Docs (docs/api/REFERENCE.md) and the 15-preferences-patch curl smoke updated — the test adapts to the daemon: round-trip on a mmap-capable core, the 409 gate otherwise.

Follow-up to amule-project#565: surface the memory-mapped file I/O preference on the REST
API. files.mmap_supported is a read-only daemon capability (mirrors
upnp_available), read from the EC_TAG_FILES_MMAP_SUPPORTED tag; files.mmap_enabled
is the runtime value. A PATCH that sets mmap_enabled is rejected with 409 when the
connected daemon lacks mmap support, so the option is only writable against a core
that can actually use it.

Updates docs/api/REFERENCE.md and the 15-preferences-patch curl smoke (round-trip
on a mmap-capable daemon; the 409 capability gate otherwise).
@got3nks
got3nks merged commit 4ebe328 into amule-org:master Jul 23, 2026
14 checks passed
@got3nks
got3nks deleted the feat/amuleapi-mmap branch July 23, 2026 18:03
@ngosang

ngosang commented Jul 25, 2026

Copy link
Copy Markdown
Member

WebUI implemented in #595

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants