MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / Stop

Method Stop

sqlchain/chain.go:866–879  ·  view source on GitHub ↗

Stop stops the main process of the sql-chain.

()

Source from the content-addressed store, hash-verified

864
865// Stop stops the main process of the sql-chain.
866func (c *Chain) Stop() (err error) {
867 // Stop main process
868 le := c.logEntry()
869 le.Debug("stopping chain")
870 c.rt.stop(c.databaseID)
871 le.Debug("chain service and workers stopped")
872 // Close state
873 var ierr error
874 if ierr = c.st.Close(false); ierr != nil && err == nil {
875 err = ierr
876 }
877 le.WithError(ierr).Debug("chain state storage closed")
878 return
879}
880
881// FetchBlock fetches the block at specified height from local cache.
882func (c *Chain) FetchBlock(height int32) (b *types.Block, err error) {

Callers 5

StartMethod · 0.95
runNodeFunction · 0.95
TestMultiChainFunction · 0.45
stopMethod · 0.45
waitProfileCheckingFunction · 0.45

Calls 5

logEntryMethod · 0.95
DebugMethod · 0.80
WithErrorMethod · 0.80
CloseMethod · 0.65
stopMethod · 0.45

Tested by 2

TestMultiChainFunction · 0.36
waitProfileCheckingFunction · 0.36