Skip to content

🌊 Streams - Better error handling#211197

Merged
flash1293 merged 3 commits intoelastic:mainfrom
flash1293:flash1293/fix-error-message-toast
Feb 14, 2025
Merged

🌊 Streams - Better error handling#211197
flash1293 merged 3 commits intoelastic:mainfrom
flash1293:flash1293/fix-error-message-toast

Conversation

@flash1293
Copy link
Copy Markdown
Contributor

@flash1293 flash1293 commented Feb 14, 2025

In a bunch of places we would directly show error.message in toasts. This is not always the right value, because the actual error is sometimes wrapped in an HttpError. At some places we would already unpack this correctly using a helper function - I made sure it's used everywhere.

One example where this can be tested is when trying to map a child in an incompatible way - let's say a field is mapped as long in logs.child.subchild, then the user tries to map the same field as keyword in logs.child. Previously it would just say "BadRequest", now it says:
Screenshot 2025-02-14 at 15 02 53

@flash1293 flash1293 added release_note:skip Skip the PR/issue when compiling release notes backport:version Backport to applied version labels v9.1.0 v8.19.0 labels Feb 14, 2025
@flash1293 flash1293 added the Feature:Streams This is the label for the Streams Project label Feb 14, 2025
@flash1293 flash1293 marked this pull request as ready for review February 14, 2025 14:05
@flash1293 flash1293 requested a review from a team as a code owner February 14, 2025 14:05
Copy link
Copy Markdown
Contributor

@miltonhultgren miltonhultgren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review only

@elasticmachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
streamsApp 279.9KB 279.9KB -60.0B

@flash1293 flash1293 merged commit 0a50f77 into elastic:main Feb 14, 2025
@kibanamachine
Copy link
Copy Markdown
Contributor

Starting backport for target branches: 8.x

https://github.com/elastic/kibana/actions/runs/13333122093

@kibanamachine
Copy link
Copy Markdown
Contributor

💔 All backports failed

Status Branch Result
8.x Backport failed because of merge conflicts

You might need to backport the following PRs to 8.x:
- [Streams] Schema Editor advanced field mapping options (#210667)

Manual backport

To create the backport manually run:

node scripts/backport --pr 211197

Questions ?

Please refer to the Backport tool documentation

flash1293 added a commit that referenced this pull request Feb 18, 2025
# Backport

This will backport the following commits from `main` to `8.x`:
- 🌊 Streams - Better error handling
(#211197)](#211197)

Co-authored-by: Marco Antonio Ghiani <marcoantonio.ghiani01@gmail.com>
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this pull request Mar 22, 2025
In a bunch of places we would directly show `error.message` in toasts.
This is not always the right value, because the actual error is
sometimes wrapped in an HttpError. At some places we would already
unpack this correctly using a helper function - I made sure it's used
everywhere.

One example where this can be tested is when trying to map a child in an
incompatible way - let's say a field is mapped as long in
`logs.child.subchild`, then the user tries to map the same field as
keyword in `logs.child`. Previously it would just say "BadRequest", now
it says:
<img width="378" alt="Screenshot 2025-02-14 at 15 02 53"
src="https://github.com/user-attachments/assets/0abb51db-2bac-407e-bb51-beb74b3f9adb"
/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels Feature:Streams This is the label for the Streams Project release_note:skip Skip the PR/issue when compiling release notes v8.19.0 v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants