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

Fix rocksdb instance not close properly #1264

Merged
merged 4 commits into from
Nov 17, 2020
Merged

Conversation

Linary
Copy link
Contributor

@Linary Linary commented Nov 16, 2020

  • The open-pool opened session is always exist

Change-Id: I30504565155848659a818fbc1b57999547f0502f

* The open-pool opened session is always exist

Change-Id: I30504565155848659a818fbc1b57999547f0502f
@@ -217,6 +218,16 @@ private static void waitOpenFinish(List<Future<?>> futures,
if (openPool.isShutdown()) {
return;
}

this.sessions.session();
Copy link
Contributor

Choose a reason for hiding this comment

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

add comments for why

Change-Id: I5ce6d06d340d8ded8096b1f016e6a1d7f7edeea8
@codecov
Copy link

codecov bot commented Nov 16, 2020

Codecov Report

Merging #1264 (41563df) into master (836956d) will increase coverage by 0.03%.
The diff coverage is 75.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1264      +/-   ##
============================================
+ Coverage     62.39%   62.43%   +0.03%     
- Complexity     5758     5766       +8     
============================================
  Files           374      374              
  Lines         31295    31307      +12     
  Branches       4398     4398              
============================================
+ Hits          19528    19546      +18     
+ Misses         9779     9778       -1     
+ Partials       1988     1983       -5     
Impacted Files Coverage Δ Complexity Δ
...ain/java/com/baidu/hugegraph/task/TaskManager.java 70.50% <50.00%> (-2.05%) 25.00 <0.00> (-3.00)
.../hugegraph/backend/store/rocksdb/RocksDBStore.java 66.50% <66.66%> (+0.51%) 63.00 <1.00> (+3.00)
.../main/java/com/baidu/hugegraph/util/Consumers.java 54.09% <85.00%> (+6.05%) 18.00 <4.00> (+4.00)
...raph/backend/store/rocksdb/RocksDBStdSessions.java 65.94% <0.00%> (+0.39%) 36.00% <0.00%> (+1.00%)
...va/com/baidu/hugegraph/task/ServerInfoManager.java 70.78% <0.00%> (+0.56%) 51.00% <0.00%> (+1.00%)
...du/hugegraph/backend/store/BackendSessionPool.java 83.33% <0.00%> (+6.94%) 19.00% <0.00%> (+2.00%)

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 836956d...0986046. Read the comment docs.

this.sessions.session();
try {
Consumers.executeOncePerThread(openPool, OPEN_POOL_THREADS,
() -> this.sessions.closeSession());
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 ok if there are multi disks

Change-Id: I184c428b09420c435121f1076e830a992ad171fd
javeme
javeme previously approved these changes Nov 17, 2020
Change-Id: I19e3d33fef1aa7db9c60bc38c3942dc94f979faf
@Linary Linary merged commit 5a68f50 into master Nov 17, 2020
@Linary Linary deleted the fix-rocksdb-not-close branch November 17, 2020 07:34
tmljob pushed a commit to tmljob/hugegraph that referenced this pull request Dec 10, 2020
* The open-pool opened session is always exist
* Fix other disk sessions not close

Change-Id: I30504565155848659a818fbc1b57999547f0502f
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.

None yet

2 participants