Skip to content

webrtc: bring the draft up to date, with its plan and increment 1's code - #12

Merged
pinhopro merged 2 commits into
mainfrom
webrtc/refresh-draft
Nov 14, 2026
Merged

pinhopro merged 2 commits into
mainfrom
webrtc/refresh-draft

Conversation

@pinhopro

@pinhopro pinhopro commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Brings the webcpp::webrtc genesis (libraries/webrtc/openspec/changes/genesis/) from the stale draft of 2026-10-13 up to date, and proposes it: its status is proposed (task 0.8), for its public discussion here and the maintainers' decision. Its implementation will live in https://github.com/webcpporg/webrtc, a repository the owner creates once the proposal is accepted.

  • The owner's decisions of 2026-11-14 (design.md): webcpp::webrtc is a library of its own on webcpp::asio, not a part of webcpp::beast (D1); libdatachannel's MPL-2.0 is accepted (D16); the native backend uses libdatachannel's C API only, so the library works with exceptions on and off on both targets (D4).
  • Stale statements fixed: webcpp::asio is implementing and its browser bridge exists; Boost.Asio runs on WASIp2/P3 (the #error under WASI stays, with the reason that still holds); libdatachannel 0.24.6 is pinned at 6b1e2e6 and built from third_party/.
  • Task 0.4: the browser design is aligned with webcpp::beast's browser WebSocket as built (one intrusive registration of the bridge, staged arrivals and one notification, the receive bound charged on arrival, cancellation per type, operation state in the handler's allocator, the unsupported policy's inline namespace and b2 feature), each difference stated with its reason; trystero's backend is mapped at e9326e9, shared connection and early native frames included.
  • Task 0.1: reference/plan.md, the three increments.
  • Task 0.2: reference/source/, increment 1: the interface and the native implementation over libdatachannel's C API, with its tests. reference/spec.md (2026-10-10) is kept as written; design.md lists what changed since.
  • Task 0.8: the status proposed in .openspec.yaml, proposal.md, reference/STATUS.md and the README's table; design.md's rollback archives a withdrawn or rejected proposal, as CONTRIBUTING.md says, instead of deleting it.

Evidence (2026-11-14, reference/STATUS.md)

  • Built against the superproject at eb08198 with its pinned libdatachannel and OpenSSL: 25 test targets pass from scratch (b2 -a), as the build asks and with exception-handling=off; the lifetime test passes 100 rounds under ThreadSanitizer with no report.
  • A measurement: a native channel never read, past libdatachannel's 1,024-message queue, stalls its connection's other channels until it is read or destroyed. A test pins the finding; design.md D9 and open question O3 record it.
  • clang-format and clang-tidy (wasi-sdk 34, the superproject's configuration) report nothing for the library's translation units; the whole-tree lint was not run.
  • openspec validate --all --strict --no-interactive (1.10.0) in libraries/webrtc, python3 tools/proposals.py readme, check and python3 tools/proposals_test.py pass.

Not in this change

  • Tasks 1.11 to 1.13 (the C API's cost on receipt, the documentation, the repository webcpporg/webrtc), then increments 2 and 3.
  • The superproject's CODING-GUIDELINES.md chapter 18 still summarizes the old draft, and the libdatachannel B2 target's threading message names trystero only: both are superproject changes.

🤖 Generated with Claude Code

The design records the owner's decisions of 2026-11-14: webcpp::webrtc
stays a library of its own on webcpp::asio, not a part of webcpp::beast;
libdatachannel's MPL-2.0 is accepted for it; and the native backend calls
libdatachannel's C API only, so the library works with exceptions on and
off on both targets.

It corrects what was stale: webcpp::asio is implementing and its bridge
exists, Boost.Asio runs on WASIp2 and WASIp3 (the WASI #error stays, with
the reason that still holds), and libdatachannel 0.24.6 is pinned and
built from third_party. It aligns the browser design with webcpp::beast's
browser WebSocket as built, and maps trystero's backend at e9326e9,
shared connection and early native frames included.

reference/plan.md holds the three increments. reference/source/ holds
increment 1, the interface and the native implementation, whose 25 test
targets pass from scratch against the pinned libdatachannel, as the build
asks, without exceptions and under ThreadSanitizer. A measurement found
that a native channel never read stalls its connection's other channels;
the design and a test record it.
Move webcpp::webrtc's genesis from draft to proposed (tasks.md 0.8): the
metadata, proposal.md's status, reference/STATUS.md and the README's
table. design.md's rollback now archives a withdrawn or rejected
proposal, as CONTRIBUTING.md says, instead of deleting it.
@pinhopro
pinhopro merged commit 1f79ab5 into main Nov 14, 2026
2 checks passed
pinhopro pushed a commit to webcpporg/webcpp that referenced this pull request Nov 14, 2026
The owner accepted webcpp::webrtc's genesis on 2026-11-14
(webcpporg/proposals#12), so its summary moves from chapter 18 to
chapter 17 as accepted and not built: the library "will be", and the
summary says that its repository is still to be created from the
reference code. Chapter 18's introduction keeps its wording for drafts
and proposals under discussion alike.
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.

1 participant