| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Ouroboros.Consensus.Node.Recovery
Synopsis
- createMarkerOnCleanShutdown :: IOLike m => HasFS m h -> m a -> m a
- hasCleanShutdownMarker :: HasFS m h -> m Bool
- createCleanShutdownMarker :: IOLike m => HasFS m h -> m ()
- removeCleanShutdownMarker :: HasFS m h -> m ()
Documentation
createMarkerOnCleanShutdown Source #
When the given action terminates with a clean exception, create the clean shutdown marker file.
NOTE: we assume the action (i.e., the node itself) never terminates without an exception.
A clean exception is an exception for exceptionRequiresRecovery returns
False.
hasCleanShutdownMarker :: HasFS m h -> m Bool Source #
Return True when cleanShutdownMarkerFile exists.
createCleanShutdownMarker :: IOLike m => HasFS m h -> m () Source #
Create the cleanShutdownMarkerFile.
Idempotent.
removeCleanShutdownMarker :: HasFS m h -> m () Source #
Remove cleanShutdownMarkerFile.
Will throw an FsResourceDoesNotExist error when it does not exist.