Kernels: Connect via IPC/Domain sockets instead of TCP

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

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

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

評価

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

調査の方向性

The issue identifies Kallichore and Ark as the components that need domain socket support, and notes that IPyKernel reportedly supports it through an undocumented connection file format. Start by reading the linked IPyKernel discussion and checking the existing kernel connection paths in Positron. Done means Positron can connect to kernels over domain sockets; the issue does not specify tests or acceptance criteria.

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

説明

area: kallichore area: kernels performance

Today, the connection between Positron and Kallichore is typically done over a domain socket, but the connection from Kallichore to the kernels happens over TCP.

graph LR
Positron -- socket --> Kallichore -- TCP --> Kernels

TCP is simple and widely supported. It's the standard way to connect to Jupyter kernels that is used by almost every front end. However, it has some real drawbacks:

  • Higher latency; going through the TCP stack adds overhead
  • Security concerns; any process on the machine can connect to TCP, but domain sockets can be protected by filesystem permissions
  • Race conditions; the Jupyter protocol has an inherent TCP race condition that sometimes results in a ZMQ "address already in use" error, a longstanding Positron issue we have never been able to fix, because it is not fixable without changes to the protocol (JEP 66), which Ark supports but IPyKernel doesn't
  • Antivirus issues; perhaps most importantly, opening up a bunch of TCP ports often gets software flagged by aggressive or corporate AV software.

IPyKernel reportedly supports domain sockets via a somewhat undocumented connection file format: https://github.com/ipython/ipykernel/issues/925

Ark does not yet support domain sockets, and neither does Kallichore, but both could be made to do so.

主要言語
TypeScript
スター
4.4k
フォーク
207
平均マージ
1日 16時間
マージ済み PR(30日)
308

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

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

posit-dev/positron のほかの issue

posit-dev/positron の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

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

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