Repository navigation
IGNITE-28730 Add query parameters to SQL heavy query warnings - #13745
Open
rezataroosheh wants to merge 1 commit into
Open
rezataroosheh wants to merge 1 commit into
rezataroosheh wants to merge 1 commit into
Conversation
rezataroosheh
marked this pull request as ready for review
October 24, 2026 20:26
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.
What
Heavy query warnings ("Query execution is too long", "Long running query is finished", "Query produced big result set") now contain the bound parameter values as
params=[...]whenIGNITE_TO_STRING_INCLUDE_SENSITIVEis enabled. When it is disabled, parameters are not printed.Both engines are covered:
sql='...', so that is fixed too, to keep parameters apart from the SQL text.Why
The warnings show the SQL text but not the parameter values, so it is hard to find which values caused a slow query or a big result set.
Tests
LongRunningQueryTest#testQueryParameters: H2 LOCAL, MAP and REDUCE queries.SqlDiagnosticIntegrationTest#testLongQueryParametersInLog: Calcite.Both check that parameters print when sensitive data is enabled and don't print when it is disabled.
Notes for review
IGNITE_TO_STRING_INCLUDE_SENSITIVEistrueby default, so parameters are printed by default. This is the same as SQL literals, which are also printed unless you disable the flag.S.arrayToString, so the number of values is limited byIGNITE_TO_STRING_COLLECTION_LIMIT. A single value's length is not limited, the same as thesqlandplanparts of the warning.H2DmlInfo) are not changed.The Contribution Checklist
The description explains WHAT and WHY was made instead of HOW.
The following pattern must be used:
IGNITE-XXXX Change summarywhereXXXX- number of JIRA issue.(see the Maintainers list)
the
green visaattached to the JIRA ticket (see tabPR Checkat TC.Bot - Instance 1 or TC.Bot - Instance 2)Notes
If you need any help, please email dev@ignite.apache.org or ask any advice on https://the-asf.slack.com #ignite channel.