Don't let client slowness possibly block JVM threads

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

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

評価

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

調査の方向性

まず、issue で説明されている logging call を追跡し、提案されている executor、メッセージパッシング、reset コマンドのアプローチを確認します。完了条件は、低速または不具合のあるクライアントが log call を実行している JVM スレッドをブロックできず、この動作を維持する場合には、停止した executor をリセットする方法があることです。

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

説明

Context

As discussed in https://github.com/clojure-emacs/cider-nrepl/pull/773#discussion_r1227086600, it seems possible that given a slow- or buggy-enough client, sending logs from the JVM would actually block the given JVM thread that is performing the logging.

i.e., clojure code like:

(log/error :foo)

might block if Emacs happens to have some sort of issue. Which doesn't seem incredibly rare given Emacs' customizability.

Proposed solution

Make sure that the actual logging call happens from a thread executor. One communicates with said thread by message passing. One can check whether the thread is alive by using e.g. deref with its [ref timeout-ms timeout-val] extended signature.

And one could have a nrepl command for "resetting" the executor to a new one, which would help if it ever got stuck.

主要言語
Clojure
スター
2
フォーク
1
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

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

clojure-emacs/logjam のほかの issue

clojure-emacs/logjam の issue をすべて見る

似ている issue

Clojure の issue をもっと見る

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

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