[FEATURE] Add Read Only mode for skipping write queries
- Dominant language
- Scala
- Stars
- 2.4k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
### Code of Conduct
- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
### Search before asking
- [X] I have searched in the [issues](https://github.com/apache/incubator-kyuubi/issues?q=is%3Aissue) and found no similar issues.
### Describe the feature
Introduce a session-level / server-level configuration to skip running writes in excuting the ExecuteStatement.
The feature aims to facilitate the handy usage in read-only senarios like Adhoc query, BI graph tools by skipping execution of write commands like `INSERT`, `INSERT OVERWRITE`, `UPDATE` and etc, to prevent side effects of writing data.
### Motivation
_No response_
### Describe the solution
_No response_
### Additional context
_No response_
### Are you willing to submit PR?
- [X] Yes I am willing to submit a PR!
Contributor guide
Research direction
Start by tracing the ExecuteStatement entry point and the existing session- and server-level configuration handling. Determine how write commands such as INSERT, INSERT OVERWRITE, and UPDATE are identified, then verify that read-only mode skips them without side effects at both requested scopes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- scala, sql
- Domain
- backend-api-design, databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100