Chaos Handler not working as expected
@koros đang làm issue này rồi.
Từ ngày 21/7/2023.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
Bug Report
Prerequisites
- Can you reproduce the problem?
- Are you running the latest version?
- Are you reporting to the correct repository?
- Did you perform a cursory search?
For more information, see the CONTRIBUTING guide.
Description
I am trying to throw some throttling errors for a graph client using js randomly with 429 status code. So I created Chaos handler and added it as a middleware for that graph request via middlewareOptions and checked it, To my surprise, it received the correct response and didn't try to throw the error.
Steps to Reproduce
- Initialise a graphClient using @microsoft/microsoft-graph-client
- Added chaos Handler something like this:
await graphClient.api(path).middlewareOptions([
new ChaosHandlerOptions(
ChaosStrategy.MANUAL,
'Retry Error',
429,
100,
)]).get()
- So As the chaos percentage is 100%, I should be expecting all throtling exceptions, But it didn't happen.
Expected behavior:
I am expecting to throw error so that I can catch it and handle it accordingly.
Actual behavior:
It returns the response data from the API request.
Additional Context
Add any other context about the problem here..
Usage Information
Request ID - Value of the requestId field if you are receiving a Graph API error response
SDK Version - 3.0.5
- Node (Check, if using Node version of SDK)
Node Version - 18.13.0
- Browser (Check, if using Browser version of SDK)
Browser Name - [The name of Browser that you are using for SDK]
Version - [The version of the browser you are using]
- Ngôn ngữ chính
- TypeScript
- Star
- 833
- Fork
- 240
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
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 microsoftgraph/msgraph-sdk-javascript
-
status:waiting-for-triage
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 62/100
-
Is anyone here? Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 25/100
microsoftgraph/msgraph-sdk-javascript#2005 · 1 reaction ·
-
Is it really correct that the Javascript version of the graph SDK doesn't offer typed requests? Đang mởstatus:waiting-for-triage
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 42/100
-
status:waiting-for-triage type:bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
microsoftgraph/msgraph-sdk-javascript#1999 · 2 bình luận · 1 reaction ·
-
status:waiting-for-triage type:bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
Tất cả issue của microsoftgraph/msgraph-sdk-javascript
Issue tương tự
-
Type/Bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
OpenNSW/nsw-srilanka#497 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
0xMiden/bridge-portal#132 ·
-
react-doctor severity:warning tech-debt
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
digidem/comapeo-cloud-app#403 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100