Avoid restarting the query server while there are running queries
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- 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
- Đình trệ
- Công nghệ
- typescript
- Lĩnh vực
- devtools
Hướng nghiên cứu
Không có tệp hoặc bài kiểm thử nào được nêu. Hãy bắt đầu bằng cách xác định client của query-server, các callback cho những thao tác đang chờ của nó và luồng cài đặt query-server; sau đó truy vết cách các thay đổi cài đặt kích hoạt việc khởi động lại. Công việc được xem là hoàn tất khi, sau một thay đổi cài đặt trong lúc có các thao tác đang chờ, một popup xác nhận không-modal được hiển thị, đồng thời vẫn cho phép các truy vấn mới và cung cấp một nút để khởi động lại cũng như hủy các truy vấn hiện tại.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Currently, if someone changes any query server settings, the query server is immediately stopped. Any running queries will complete with an error.
It should be possible to avoid restarting the server while there are running queries. The way that the query-server client is implemented, there are callbacks registered for any query or operation that is currently running. When completed, the callback is removed. Every time, after a callback is removed, we can check if the list of open callbacks is empty, and only then restart the server.
There are several potential edge cases to consider:
- If there is a zombie callback that is registered even though the thing it is registered for is no longer calling back, it will never be removed and the query server will never restart. This shouldn't happen, but we have nothing in place to ensure this.
- Consider the following pattern:
- User starts query1
- User changes a query server setting
- Query server restart is registered and is waiting for query1 to complete
- User starts query2. Query server restart is now waiting for both query1 and query2 to start
It may be confusing for a user that their next query is using the old settings even though they requested a change.
For (1), perhaps we can set a timeout where if there are no callbacks triggered after X seconds, we assume they are all zombies and restart anyway. Long running queries will still invoke the callbacks on a regular basis, so this is safe.
For (2), I am less certain. Perhaps we can prevent starting new queries if a server restart is requested.
EDIT- After discussion with @adityasharad the simplest implementation that will suit are purposes is:
After editing any of the query server settings and there are server operations outstanding, open a popup saying something like: "Settings will not come into effect until the query server is restarted. Restart now? (This will cancel any currently executing queries.)" And add a button on the popup that triggers the restart.
The popup should be non-modal, allowing a user to potentially run new queries under the old settings. This is OK because it is clear what is happening.
- Ngôn ngữ chính
- TypeScript
- Star
- 539
- Fork
- 240
- Merge trung bình
- 2 ngày 18 giờ
- Pull request đã merge (30 ngày)
- 37
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của github/vscode-codeql
-
bug VSCode
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
github/vscode-codeql#4471 · 1 bình luận ·
-
bug enhancement VSCode
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
github/vscode-codeql#592 · 2 bình luận ·
-
enhancement VSCode
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
github/vscode-codeql#4432 · 1 bình luận ·
-
bug VSCode
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
github/vscode-codeql#4356 ·
-
bug VSCode
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 64/100
github/vscode-codeql#4339 · 1 bình luận ·
Tất cả issue của github/vscode-codeql
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
bug v2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
modelcontextprotocol/inspector#2458 · 1 bình luận ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
railmapgen/rmp-gallery#4068 ·
-
Mend: dependency security vulnerability status: needs triage 🕵️♀️
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
carbon-design-system/ibm-products#9907 ·