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

simplify storage SIGINT signal handler #3437

Merged
merged 2 commits into from
Dec 13, 2021

Conversation

liuyu85cn
Copy link
Contributor

@liuyu85cn liuyu85cn commented Dec 8, 2021

What type of PR is this?

  • bug
  • feature
  • enhancement

What does this PR do?

In short:

  1. let's say we(storage server) have a thread running some task.

  2. user send kill SIGINT signal, linux schedule the signal handler at the thread we talked about.

  3. now, we interrupt the previous task, executing the signal handler,
    it calls storage server->stop()
    trying to clear everything storage server has(also include this thread!!!!).

  4. Then we stuck.

Which issue(s)/PR(s) this PR relates to?

Storage hang at exit #3434

@liuyu85cn liuyu85cn added the ready-for-testing PR: ready for the CI test label Dec 8, 2021
@codecov-commenter
Copy link

Codecov Report

Merging #3437 (a668c1c) into master (ab73b4c) will increase coverage by 0.06%.
The diff coverage is 95.45%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3437      +/-   ##
==========================================
+ Coverage   85.23%   85.30%   +0.06%     
==========================================
  Files        1277     1278       +1     
  Lines      119088   119287     +199     
==========================================
+ Hits       101502   101754     +252     
+ Misses      17586    17533      -53     
Impacted Files Coverage Δ
src/graph/optimizer/rule/CollapseProjectRule.cpp 98.24% <ø> (ø)
...timizer/rule/OptimizeEdgeIndexScanByFilterRule.cpp 90.54% <ø> (ø)
...ptimizer/rule/OptimizeTagIndexScanByFilterRule.cpp 90.27% <ø> (ø)
...h/optimizer/rule/PushLimitDownGetNeighborsRule.cpp 93.54% <ø> (ø)
...timizer/rule/PushStepLimitDownGetNeighborsRule.cpp 93.75% <ø> (ø)
...imizer/rule/PushStepSampleDownGetNeighborsRule.cpp 93.93% <ø> (ø)
src/graph/planner/plan/Query.h 97.61% <ø> (+0.16%) ⬆️
src/graph/util/FTIndexUtils.cpp 4.12% <ø> (ø)
src/graph/validator/FindPathValidator.cpp 84.78% <ø> (ø)
src/graph/validator/MutateValidator.cpp 94.11% <ø> (+0.05%) ⬆️
... and 64 more

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 dd06a53...a668c1c. Read the comment docs.

Copy link
Contributor

@yixinglu yixinglu left a comment

Choose a reason for hiding this comment

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

LGTM

@yixinglu yixinglu requested a review from kikimo December 10, 2021 04:00
Copy link
Contributor

@kikimo kikimo left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@critical27 critical27 left a comment

Choose a reason for hiding this comment

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

Good job

@yixinglu yixinglu merged commit 701acd0 into vesoft-inc:master Dec 13, 2021
@heroicNeZha heroicNeZha mentioned this pull request Dec 23, 2021
7 tasks
yixinglu pushed a commit to yixinglu/nebula that referenced this pull request Mar 21, 2022
#### What type of PR is this?
- [x] bug
- [ ] feature
- [ ] enhancement

#### What does this PR do?
closes vesoft-inc#3441 
simplify graphd signal handler:Set stop condition instead of waiting all workers stop

#### Which issue(s)/PR(s) this PR relates to?
In vesoft-inc#3437 , it simplify storage SIGINT signal handler
  
#### Special notes for your reviewer, ex. impact of this fix, etc:


#### Additional context/ Design document:


#### Checklist:
- [ ] Documentation affected (Please add the label if documentation needs to be modified.)
- [ ] Incompatibility (If it breaks the compatibility, please describe it and add the corresponding label.)
- [ ] If it's needed to cherry-pick (If cherry-pick to some branches is required, please label the destination version(s).)
- [ ] Performance impacted: Consumes more CPU/Memory

#### Release notes:

Please confirm whether to be reflected in release notes and how to describe:
>                                                                 `


Migrated from vesoft-inc#3542

Co-authored-by: endy.li <25311962+heroicNeZha@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-testing PR: ready for the CI test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants