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

optimize jvm parameters #708

Merged
merged 3 commits into from
Dec 6, 2023
Merged

optimize jvm parameters #708

merged 3 commits into from
Dec 6, 2023

Conversation

nlu90
Copy link
Contributor

@nlu90 nlu90 commented Dec 5, 2023

(If this PR fixes a github issue, please add Fixes #<xyz>.)

Fixes #

(or if this PR is one task of a github issue, please add Master Issue: #<xyz> to link to the master issue.)

Master Issue: #

Motivation

Reducing resource requirements and improving the process stability.

Modifications

  1. Allocate JVM memory based on the container memory and percentage. By default, the direct memory equals the max percentage. So the final allocation is 40% max heap + 40% max direct memory + 20% misc.
  2. Turn on GC logs
  3. Turn on heapdump

Describe the modifications you've done.

Verifying this change

  • Make sure that the change passes the CI checks.

(Please pick either of the following options)

This change is a trivial rework / code cleanup without any test coverage.

(or)

This change is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

(example:)

  • Added integration tests for end-to-end deployment with large payloads (10MB)
  • Extended integration test for recovery after broker failure

Documentation

Check the box below.

Need to update docs?

  • doc-required

    (If you need help on updating docs, create a doc issue)

  • no-need-doc

    (Please explain why)

  • doc

    (If this PR contains doc changes)

@nlu90 nlu90 requested review from freeznet and a team as code owners December 5, 2023 17:39
@nlu90 nlu90 self-assigned this Dec 5, 2023
Copy link

github-actions bot commented Dec 5, 2023

@nlu90:Thanks for your contribution. For this PR, do we need to update docs?
(The PR template contains info about doc, which helps others know more about the changes. Can you provide doc-related info in this and future PR descriptions? Thanks)

@github-actions github-actions bot added the doc-info-missing This pr needs to mark a document option in description label Dec 5, 2023
"-Xmx" + getDecimalSIMemory(memory),
"-Xms" + getDecimalSIMemory(xmsMemory),
"-XX:InitialRAMPercentage=20",
"-XX:MaxRAMPercentage=40",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this MaxRAMPercentage means -Xmx?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes.

@freeznet freeznet merged commit 759cbf6 into master Dec 6, 2023
12 checks passed
@freeznet freeznet deleted the neng/jvm-mem-tuning branch December 6, 2023 16:34
freeznet pushed a commit that referenced this pull request Dec 6, 2023
* optimize jvm parameters

* check style

* update
# Conflicts:
#	controllers/spec/common.go
#	controllers/spec/sink.go
#	controllers/spec/source.go
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc-info-missing This pr needs to mark a document option in description
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants