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

Reject request when there is too little free memory #476

Merged
merged 4 commits into from
May 23, 2019
Merged

Conversation

Linary
Copy link
Contributor

@Linary Linary commented Apr 22, 2019

Change-Id: Ibac88733530b55d267da88e08055d71bce9b07d7

zhoney
zhoney previously approved these changes Apr 26, 2019
"will be rejected when the available memory of system " +
"is lower than this value.",
positiveInt(),
128L
Copy link
Contributor

Choose a reason for hiding this comment

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

is it a suitable default value?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Choosed 512M, which is also the minimum memory required to start the service.

@@ -63,7 +63,7 @@ public static synchronized ServerOptions instance() {
"will be rejected when the available memory of system " +
"is lower than this value.",
positiveInt(),
128L
512L
Copy link
Contributor

Choose a reason for hiding this comment

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

if the program is allocated with 512M memory, in general, the program itself occupies part of the memory, so it may not be unable to serve.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

seems 256M is better

@Linary Linary force-pushed the memory-threshold branch from 0a29926 to 719867d Compare May 14, 2019 08:04
@Linary Linary requested a review from javeme May 17, 2019 02:50
Linary added 3 commits May 22, 2019 19:31
Change-Id: Ibac88733530b55d267da88e08055d71bce9b07d7
Change-Id: I6a776fc78a836bf7053ac92b222858e59a96c758
Change-Id: I66819d276c4bd3db34ba7869bd6bfee176b50b7e
@Linary Linary force-pushed the memory-threshold branch 2 times, most recently from 0b7615d to 53ef577 Compare May 22, 2019 12:26
@apache apache deleted a comment from codecov bot May 22, 2019
@Linary Linary force-pushed the memory-threshold branch from 53ef577 to 9dd391c Compare May 22, 2019 12:43
@codecov
Copy link

codecov bot commented May 22, 2019

Codecov Report

Merging #476 into master will increase coverage by 0.01%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #476      +/-   ##
============================================
+ Coverage     69.37%   69.39%   +0.01%     
- Complexity     3344     3352       +8     
============================================
  Files           216      216              
  Lines         16450    16450              
  Branches       2352     2352              
============================================
+ Hits          11413    11416       +3     
- Misses         3776     3777       +1     
+ Partials       1261     1257       -4
Impacted Files Coverage Δ Complexity Δ
...c/main/java/com/baidu/hugegraph/util/JsonUtil.java 52.83% <0%> (-5.67%) 4% <0%> (-1%)
...ain/java/com/baidu/hugegraph/task/TaskManager.java 60.86% <0%> (-4.35%) 10% <0%> (-1%)
...e/src/main/java/com/baidu/hugegraph/HugeGraph.java 70.6% <0%> (-0.96%) 60% <0%> (ø)
...va/com/baidu/hugegraph/type/define/Directions.java 83.33% <0%> (+33.33%) 19% <0%> (+10%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7def830...77956a9. Read the comment docs.

Change-Id: Ibbc1334a777e07db029ee65d7a94a249179fb96e
@Linary Linary force-pushed the memory-threshold branch from 9dd391c to 77956a9 Compare May 23, 2019 02:50
@zhoney zhoney merged commit 27f23c5 into master May 23, 2019
@zhoney zhoney deleted the memory-threshold branch May 23, 2019 07:18
javeme added a commit that referenced this pull request May 24, 2019
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.

3 participants