Connection State Recovery: Client->Server resync

オープン
#5,363 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
javascript, nodejs, typescript

調査の方向性

この issue ではファイル、テスト、エントリーポイントが指定されていません。まず、クライアントとサーバーの両方で既存の接続状態の復旧フローと再接続フローを追跡し、その後 wire format を調べます。完了条件は、再接続後に不足しているクライアントからサーバーへのイベントを再試行でき、確認済みの offset によってクライアントがバッファリングされたイベントを破棄できることです。

索引モデルが issue の本文から書いたものです。

説明

enhancement

Is your feature request related to a problem? Please describe.
Connection state recovery only recovers packets that are buffered on the server. On reconnect, these are then sent to the client. But client->server packets are not handled this way.

Describe the solution you'd like
I'd like to have connection state recovery support packet retry from client to server as well. All client->server events would include an offset. On reconnect the server would send the latest client->server offset to the client and the client would repeat any missing events.

It would be nice to send the client->server offset back to the client periodically, or perhaps on every server->client event. This way the client could quickly purge events from its buffer.

This would probably involve a change to the wire format.

Describe alternatives you've considered
Practically, we end up writing a lot of extra handlers on reconnect to resync client state back to the server.

主要言語
TypeScript
スター
63.2k
フォーク
10.2k
平均マージ
6日 4時間
マージ済み PR(30日)
6

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

socketio/socket.io のほかの issue

socketio/socket.io の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。