[Cases][Webhook] - Better handle 204 responses#251090
[Cases][Webhook] - Better handle 204 responses#251090michaelolo24 merged 6 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/kibana-cases (Team:Cases) |
|
Fixes #251108 |
| const data = res.data; | ||
|
|
||
| // If status is 204 and there is no data, we just return | ||
| if (res.status === 204 && isEmpty(data)) { |
There was a problem hiding this comment.
We could also make sure requiredAttributesToBeInTheResponse is not undefined here.
There was a problem hiding this comment.
Good catch, will update, thanks!
⏳ Build in-progress, with failures
Failed CI StepsHistory
|
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
4 similar comments
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
5 similar comments
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
3 similar comments
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Friendly reminder: Looks like this PR hasn’t been backported yet. |
|
Starting backport for target branches: 8.19, 9.2, 9.3 |
## Summary Currently when an update is made to an external connector that returns a `204` no content response, the rest of the incident update fails. This should not occur as a 204 is a valid response Fixes elastic#251108 ### Checklist Check the PR satisfies following conditions. - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios (cherry picked from commit 926e3a2)
## Summary Currently when an update is made to an external connector that returns a `204` no content response, the rest of the incident update fails. This should not occur as a 204 is a valid response Fixes elastic#251108 ### Checklist Check the PR satisfies following conditions. - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios (cherry picked from commit 926e3a2)
## Summary Currently when an update is made to an external connector that returns a `204` no content response, the rest of the incident update fails. This should not occur as a 204 is a valid response Fixes elastic#251108 ### Checklist Check the PR satisfies following conditions. - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios (cherry picked from commit 926e3a2)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
|
Looks like this PR has backport PRs but they still haven't been merged. Please merge them ASAP to keep the branches relatively in sync. |
Summary
Currently when an update is made to an external connector that returns a
204no content response, the rest of the incident update fails. This should not occur as a 204 is a valid responseFixes #251108
Checklist
Check the PR satisfies following conditions.