Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewValidator ¶
func NewValidator( channelID string, sem Semaphore, cr ChannelResources, ler LedgerResources, lcr plugindispatcher.LifecycleResources, cor plugindispatcher.CollectionResources, pm plugin.Mapper, channelPolicyManagerGetter policies.ChannelPolicyManagerGetter, cryptoProvider bccsp.BCCSP, ) txvalidator.Validator
NewValidator returns a new block validator. If using V2 validation and distributed validation is enabled then the distributed validator is used. Distributed validation is not supported for V14 validation.
Types ¶
type ChannelResources ¶
type ChannelResources interface { // MSPManager returns the MSP manager for this channel MSPManager() msp.MSPManager // Apply attempts to apply a configtx to become the new config Apply(configtx *common.ConfigEnvelope) error // GetMSPIDs returns the IDs for the application MSPs // that have been defined in the channel GetMSPIDs() []string // Capabilities defines the capabilities for the application portion of this channel Capabilities() channelconfig.ApplicationCapabilities // Ledger returns the ledger associated with this validator Ledger() ledger.PeerLedger }
ChannelResources provides access to channel artefacts or functions to interact with them
type LedgerResources ¶
type LedgerResources interface { // GetTransactionByID retrieves a transaction by id GetTransactionByID(txID string) (*peer.ProcessedTransaction, error) // NewQueryExecutor gives handle to a query executor. // A client can obtain more than one 'QueryExecutor's for parallel execution. // Any synchronization should be performed at the implementation level if required NewQueryExecutor() (ledger.QueryExecutor, error) }
LedgerResources provides access to ledger artefacts or functions to interact with them
Click to show internal directories.
Click to hide internal directories.