func New(conf *Config) *BlockProcessor {
	return &BlockProcessor{
		blockOneQueueBarrier: conf.BlockOneQueueBarrier,
		blockStore:           conf.BlockStore,
		validator:            newValidator(conf),
		committer:            newCommitter(conf),
		listeners:            newBlockCommitListeners(conf.Logger),
		started:              make(chan struct{}),
		stop:                 make(chan struct{}),
		stopped:              make(chan struct{}),
		logger:               conf.Logger,
	}
}
New creates a ValidatorAndCommitter
package blockprocessor
import (
	"sync"
	"github.com/hyperledger-labs/orion-server/internal/blockstore"
	"github.com/hyperledger-labs/orion-server/internal/mptrie"
	"github.com/hyperledger-labs/orion-server/internal/mtree"
	"github.com/hyperledger-labs/orion-server/internal/provenance"
	"github.com/hyperledger-labs/orion-server/internal/queue"
	"github.com/hyperledger-labs/orion-server/internal/worldstate"
	"github.com/hyperledger-labs/orion-server/pkg/logger"
	"github.com/hyperledger-labs/orion-server/pkg/types"
	"github.com/pkg/errors"
	"github.com/syndtr/goleveldb/leveldb"
)
type BlockProcessor struct {
	blockOneQueueBarrier *queue.OneQueueBarrier
	blockStore           *blockstore.Store
	validator            *validator
	committer            *committer
	listeners            *blockCommitListeners
	started              chan struct{}
	stop                 chan struct{}
	stopped              chan struct{}
	logger               *logger.SugarLogger
}
type Config struct {
	BlockOneQueueBarrier *queue.OneQueueBarrier
	BlockStore           *blockstore.Store
	DB                   worldstate.DB
	ProvenanceStore      *provenance.Store
	StateTrieStore       mptrie.Store
	Logger               *logger.SugarLogger
}