Kernels: Connect via IPC/Domain sockets instead of TCP

Đang mở
#17,618 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
typescript

Hướng nghiên cứu

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.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

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.

Ngôn ngữ chính
TypeScript
Star
4.4k
Fork
207
Merge trung bình
1 ngày 16 giờ
Pull request đã merge (30 ngày)
308

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của posit-dev/positron

Tất cả issue của posit-dev/positron

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.