Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Enhancement] Support profile for only big query (2) (backport #39855) #40207

Closed
wants to merge 1 commit into from

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jan 29, 2024

This is an automatic backport of pull request #39855 done by Mergify.
Cherry-pick of a3758df has failed:

On branch mergify/bp/branch-3.1/pr-39855
Your branch is up to date with 'origin/branch-3.1'.

You are currently cherry-picking commit a3758dfd36.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   be/src/exec/pipeline/fragment_executor.cpp
	modified:   be/src/exec/pipeline/query_context.h
	modified:   docs/en/administration/query_profile_overview.md
	modified:   docs/en/reference/System_variable.md
	modified:   docs/zh/administration/query_profile_overview.md
	modified:   docs/zh/reference/System_variable.md
	modified:   fe/fe-core/src/main/java/com/starrocks/monitor/unit/TimeValue.java
	modified:   fe/fe-core/src/main/java/com/starrocks/qe/ConnectContext.java
	modified:   fe/fe-core/src/main/java/com/starrocks/qe/SessionVariable.java
	new file:   fe/fe-core/src/test/java/com/starrocks/monitor/TimeValueTest.java

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   fe/fe-core/src/main/java/com/starrocks/sql/analyzer/SetStmtAnalyzer.java
	both modified:   gensrc/thrift/InternalService.thrift

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com

## Why I'm doing:

In the previous pr #33825, we've supported the profile only for big query with the session variable big_query_profile_second_threshold

Unfortunately, for some of our uses, most of the queries can be done within 200ms with a latency spike over 400ms, we cannot catch the slow query(400ms) with the session variable mentioned above.

What I'm doing & Behavior Change

  • Remove session variable big_query_profile_second_threshold with type int.
  • Add session variable big_query_profile_threshold with type string, it can support time duration like 1s/500ms/15m etc.

This change won't lead to compatible problem when performing grey upgrading.

  • Only upgrade some of the backends, it works fine with the previous session variable big_query_profile_second_threshold.
  • Only upgrade all of the backends, it works fine with the previous session variable big_query_profile_second_threshold
  • And after upgrading the frontend, the user need to set up the big_query_profile_threshold corresponding to the previous configuration manually.

What type of PR is this:

  • BugFix
  • Feature
  • Enhancement
  • Refactor
  • UT
  • Doc
  • Tool

Does this PR entail a change in behavior?

  • Yes, this PR will result in a change in behavior.
  • No, this PR will not result in a change in behavior.

If yes, please specify the type of change:

  • Interface/UI changes: syntax, type conversion, expression evaluation, display information
  • Parameter changes: default values, similar parameters but with different default values
  • Policy changes: use new policy to replace old one, functionality automatically enabled
  • Feature removed
  • Miscellaneous: upgrade & downgrade compatibility, etc.

Checklist:

  • I have added test cases for my bug fix or my new feature
  • This pr needs user documentation (for new or modified features or behaviors)
    • I have added documentation for my new feature or new function
  • This is a backport pr

Signed-off-by: liuyehcf <[email protected]>
(cherry picked from commit a3758df)

# Conflicts:
#	fe/fe-core/src/main/java/com/starrocks/sql/analyzer/SetStmtAnalyzer.java
#	gensrc/thrift/InternalService.thrift
@mergify mergify bot added the conflicts label Jan 29, 2024
@github-actions github-actions bot added the documentation Improvements or additions to documentation label Jan 29, 2024
@mergify mergify bot closed this Jan 29, 2024
Copy link
Contributor Author

mergify bot commented Jan 29, 2024

@mergify[bot]: Backport conflict, please reslove the conflict and resubmit the pr

@mergify mergify bot deleted the mergify/bp/branch-3.1/pr-39855 branch January 29, 2024 03:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge conflicts documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant