Reply database REPL errors to the WebSocket client#50613
Merged
gabrielcorado merged 1 commit intomasterfrom Jan 2, 2025
Merged
Reply database REPL errors to the WebSocket client#50613gabrielcorado merged 1 commit intomasterfrom
gabrielcorado merged 1 commit intomasterfrom
Conversation
zmb3
reviewed
Dec 30, 2024
zmb3
approved these changes
Dec 31, 2024
greedy52
approved these changes
Jan 2, 2025
|
@gabrielcorado See the table below for backport results.
|
This was referenced Jan 2, 2025
carloscastrojumo
pushed a commit
to carloscastrojumo/teleport
that referenced
this pull request
Feb 19, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relate to #50221
Currently, when there is an error on the database REPL, those errors are logged but not returned to the client. Here is an example with a connect error:
This PR updates the database web socket handler to avoid closing the connection (and terminal stream) when there is a session error. The middleware can send the handler error to the client when the connection is opened. In addition to this change, we're updating the connect error message from PostgreSQL REPL.
With this change, errors will propagate to the client and be presented to users, for example, the connect error:
changelog: Present connection errors to the Web UI terminal during database sessions.