Document the admin real-time channel (POST /_/realtime) and X-CWA-Client-Id
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 67/100
- issue の種類
- ドキュメント
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- typescript
調査の方向性
Start in the bundle's content/4.api/ documentation and identify the endpoint and writer sections to update; check the linked bundle issue and PR for implementation details. Then find the template deployment guidance for Nelmio allow_headers and Mercure history settings. Done when the docs cover the endpoint behavior, payload, limits, writer echo, configuration, and deployment settings listed in this issue.
索引モデルが issue の本文から書いたものです。
説明
The bundle is adding an admin real-time channel (api-components-bundle#559, PR #560). Please document the following.
Bundle (content/4.api/)
- Endpoint:
POST /_/realtime(/_api/_/realtimeunder the template).ROLE_ADMIN.- Body:
{clientId, event, iri?, data?}, 16 KB at most. - Responds 202, and stores nothing.
- Content types:
- JSON accepts any event.
text/plain(navigator.sendBeacon) is accepted only forevent: "presence"withdata.state: "left".- Anything else is 415.
- A cross-site request (
Sec-Fetch-Site) is 403.
- Payload, published privately on one site-wide topic that only admins' subscriber cookies grant:
{"@type": "CwaRealtimeEvent", "v": 1, clientId, user: {id, name}, event, iri, data, sentAt, expiresAt} - Rate limits:
- 20 burst / 10 a second per user and
clientId. - 60 burst / 30 a second per user across all their clients.
- Above either: 429 with
Retry-After. - The limiter pool
silverback.api_components.realtime.rate_limiter_cacheusescache.appby default, so the limits apply per pod. Point it at a shared adapter inframework.cache.poolsto make them exact.
- 20 burst / 10 a second per user and
- Publishing: bounded at 1 s. A failed or timed-out publish is logged and still answers 202.
- Config:
silverback_api_components.realtime.enabled(defaulttrue). Whenfalse, the endpoint is a 404 and no cookie grants the topic. - Writer echo: a write carrying
X-CWA-Client-Idgets_metadata.lastWrite: {clientId, userId, at}in the writer's response and in the private?draft=1update.atis server time, RFC 3339 with milliseconds.- Use
at, notmodifiedAt, to order draft updates.
Deployment
- The front end must be allowed to send
X-CWA-Client-Id. In the template, add it to nelmio'sallow_headers. The bundle has no Flex recipe yet (#259). - Presence events stay in the Mercure hub's replay history, so mention the hub's history size and retention settings.
- 主要言語
- TypeScript
- スター
- 0
- フォーク
- 0
- 平均マージ
- 1時間 20分
- マージ済み PR(30日)
- 1
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
components-web-app/docs のほかの issue
-
documentation
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
components-web-app/docs#290 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
components-web-app/docs#289 · コメント 2 件 ·
-
documentation
難易度 4/5 3〜5日 初心者へのやさしさ 43/100
components-web-app/docs#285 ·
-
documentation
難易度 4/5 1〜2日 初心者へのやさしさ 35/100
components-web-app/docs#284 ·
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
components-web-app/docs#237 · コメント 2 件 ·
components-web-app/docs の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1〜3時間 初心者へのやさしさ 72/100
zts212653/clowder-ai#1678 ·
メンテナーはふだん 1 日以内に返信
-
good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
Progressive-Victory/the-website#680 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100