6 #ifndef KAGOME_PARACHAIN_AVAILABILITY_BITFIELD_SIGNER_HPP 7 #define KAGOME_PARACHAIN_AVAILABILITY_BITFIELD_SIGNER_HPP 9 #include <libp2p/basic/scheduler.hpp> 23 std::shared_ptr<ValidatorSignerFactory> signer_factory,
24 std::shared_ptr<libp2p::basic::Scheduler> scheduler,
25 std::shared_ptr<runtime::ParachainHost> parachain_api,
26 std::shared_ptr<AvailabilityStore> store,
27 std::shared_ptr<BitfieldStore> bitfield_store);
30 void start(std::shared_ptr<primitives::events::ChainSubscriptionEngine>
45 std::shared_ptr<AvailabilityStore>
store_;
47 std::shared_ptr<primitives::events::ChainEventSubscriber>
chain_sub_;
51 #endif // KAGOME_PARACHAIN_AVAILABILITY_BITFIELD_SIGNER_HPP std::shared_ptr< runtime::ParachainHost > parachain_api_
std::shared_ptr< BitfieldStore > bitfield_store_
std::shared_ptr< crypto::Hasher > hasher_
outcome::result< void > sign(const ValidatorSigner &signer)
Sign bitfield for given block.
std::shared_ptr< libp2p::basic::Scheduler > scheduler_
outcome::result< void > onBlock(const BlockHash &relay_parent)
std::shared_ptr< primitives::events::ChainEventSubscriber > chain_sub_
std::shared_ptr< AvailabilityStore > store_
BitfieldSigner(std::shared_ptr< crypto::Hasher > hasher, std::shared_ptr< ValidatorSignerFactory > signer_factory, std::shared_ptr< libp2p::basic::Scheduler > scheduler, std::shared_ptr< runtime::ParachainHost > parachain_api, std::shared_ptr< AvailabilityStore > store, std::shared_ptr< BitfieldStore > bitfield_store)
common::Hash256 BlockHash
Signs payload with signing context and validator keypair.
Signs, stores and broadcasts bitfield for every new head.
std::shared_ptr< ValidatorSignerFactory > signer_factory_
void start(std::shared_ptr< primitives::events::ChainSubscriptionEngine > chain_sub_engine)
Subscribes to new heads.