Skip to content

Fix query_timeout validation to use AnalysisException#60558

Open
plchy2 wants to merge 1 commit intoapache:masterfrom
plchy2:fix-workload-validation
Open

Fix query_timeout validation to use AnalysisException#60558
plchy2 wants to merge 1 commit intoapache:masterfrom
plchy2:fix-workload-validation

Conversation

@plchy2
Copy link

@plchy2 plchy2 commented Feb 5, 2026

What problem was fixed?
The session variable query_timeout validation currently throws UnsupportedOperationException
for invalid values. This is inconsistent with other FE validations and results in unclear
error handling for invalid user input.

Additionally, non-numeric values could cause an unhandled NumberFormatException.

How was it fixed?
Replaced UnsupportedOperationException with AnalysisException
Added explicit number format validation for query_timeout
Improved error messages for invalid values
Behavior changes
Before

Invalid query_timeout values threw UnsupportedOperationException
Non-numeric values could cause unclear runtime exceptions
After

Invalid values throw AnalysisException
Non-numeric input is handled gracefully with clear error messages
Impact
This change improves consistency of session variable validation and provides clearer
feedback to users without affecting existing valid configurations.

@Thearas
Copy link
Contributor

Thearas commented Feb 5, 2026

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants