algolia / algolia/algoliasearch-client-python
retryable error doesn't increment connection timeout number
- 主要言語
- Python
- スター
- 207
- フォーク
- 63
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Looking at the retry specs, we see that:
```
When retrying, use the next host in your array.
When retrying because of a timeout, raise the timeouts like this:
number_of_tries * base_timeout
Example: Search (5s timeout) → Search timeout → Search (10s timeout) → Repeat.
```
At the moment, on the Python API Client we don't use yet the `retry_count` for this.
**Goal**:
1. Multiple timeouts by the number of tries on the line https://github.com/algolia/algoliasearch-client-python/blob/97a6f15542f6a8951cdbcd0d2881a744ec24e329/algoliasearch/http/transporter.py#L72.
2. Add a test on it.
Implementation on C#: https://github.com/algolia/algoliasearch-client-csharp/blob/42ab1842f859df87482602b12d5cb714bfa8ec71/src/Algolia.Search/Transport/HttpTransport.cs#L118
コントリビューションガイド
調査の方向性
algoliasearch/http/transporter.py のリンク先の行から開始し、C# 実装を参考にして、タイムアウトの動作に関するリトライの仕様を確認してください。リトライ回数に応じたタイムアウトの増加をカバーするテストを追加し、指定どおりにリトライ可能な接続タイムアウトが増加し、テストが通れば作業完了としてください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- api, search
- issue の種類
- バグ
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 50/100