Context doesn't cancel if I cancel the api.
- 主要言語
- Go
- スター
- 11
- フォーク
- 6
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Let's say I am calling an api "getObject", and after making the request, I press ctrl + c or cancel the request. The code should not execute as the context is canceled.
## Expected Behavior
After pressing ctrl + c after api call, code execution should stop immediately.
## Current Behavior
Code execution doesn't stop. For some upload requests, it runs for 10 mins.
## Possible Solution
Fair use of Golang context should solve this problem
## Steps to Reproduce (for bugs)
1.
2.
3.
4.
## Context
## Regression
## Your Environment
* Version used (`minio --version`):
* Server setup and configuration:
* Operating System and version (`uname -a`):
コントリビューションガイド
調査の方向性
APIリクエスト処理コード(おそらくハンドラー層またはサービス層)を調べ、コンテキストキャンセルがどのように伝播されるかを確認します。ctx.Done()をチェックしていない可能性のある長時間実行されるアップロードプロセスがないか確認してください。この課題は'getObject'とアップロードリクエストに言及しています。対応する関数を見つけ、それらがコンテキストキャンセルを尊重していることを確認してください。サーバーを実行し、キャンセルされたリクエストでテストすることで修正を検証できます。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- go
- 領域
- api, backend
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 35/100