Crate ckb_chain

Crate ckb_chain 

Source
Expand description

CKB chain service.

ChainService background base on database, handle block importing, the ChainController is responsible for receive the request and returning response

Modules§

verify

Structs§

ChainController
Controller to the chain service.
ChainServiceScope
This structure restricts the scope of chain service, and forces chain service threads to terminate before dropping the structure. The content of this struct will always be present, the reason we wrap them in an option, is that we will need to consume them in Drop trait impl of this struct.
LonelyBlock
LonelyBlock is the block which we have not check weather its parent is stored yet
LonelyBlockHash
LonelyBlock is the block which we have not check weather its parent is stored yet
RemoteBlock
RemoteBlock is received from ckb-sync and ckb-relayer

Functions§

build_chain_services
Please refer to +start_chain_services+ for difference between build_chain_services and start_chain_services
start_chain_services
Here we distinguish between build_chain_services and start_chain_services:

Type Aliases§

VerifyCallback
VerifyCallback is the callback type to be called after block verification
VerifyResult
VerifyResult is the result type to represent the result of block verification