hiero-ledger / hiero-ledger/hiero-consensus-node

Specify shutdown behavior for a consensus node

Open
#8,278 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
407
Forks
226
Avg merge
3d 4h
Merged PRs (30d)
210

Description

### Problem

When a consensus node is shutdown, there are a number of activities that should be taken to shut down gracefully. The `SwirldMain` interface has a `run` method, but no `shutdown`. We should add one and specify the behavior of the system on shutdown. There is some workaround in `MerkleHederaState#close` but we should get a proper solution.

### Solution

Add lifecycle methods to `SwirldMain`, or if we have a platform context, have some kind of way to shutdown the platform and cause it to gracefully shut things down.

### Alternatives

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the SwirldMain interface and the existing workaround in MerkleHederaState#close. Determine the required lifecycle methods or platform shutdown path and specify how a consensus node should gracefully stop its activities. Done means the shutdown behavior is defined and the selected lifecycle approach is implemented consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
distributed-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.