public BlockProgressService( IBlockchainProxyService web3, ulong defaultStartingBlockNumber, IBlockProgressRepository blockProgressRepository, uint minimumBlockConfirmations = 0) : base( defaultStartingBlockNumber, blockProgressRepository) { _web3 = web3; MinimumBlockConfirmations = minimumBlockConfirmations; }
public ElasticEventIndexingProcessor( IBlockchainProxyService blockchainProxyService, IElasticSearchService searchService, IEventFunctionProcessor functionProcessor, Func <ulong, ulong?, IBlockProgressService> blockProgressServiceCallBack = null, uint maxBlocksPerBatch = 2, IEnumerable <NewFilterInput> filters = null, uint minimumBlockConfirmations = 0) : base(blockchainProxyService, searchService, functionProcessor, blockProgressServiceCallBack, maxBlocksPerBatch, filters, minimumBlockConfirmations) { this._elasticSearchService = searchService; }
public static IBlockProcessor Create( IBlockchainProxyService web3, IVmStackErrorChecker vmStackErrorChecker, HandlerContainer handlers, FilterContainer filters = null, bool postVm = false, bool processTransactionsInParallel = true) { var transactionLogProcessor = new TransactionLogProcessor( filters?.TransactionLogFilters, handlers.TransactionLogHandler); var contractTransactionProcessor = new ContractTransactionProcessor( web3, vmStackErrorChecker, handlers.ContractHandler, handlers.TransactionHandler, handlers.TransactionVmStackHandler); var contractCreationTransactionProcessor = new ContractCreationTransactionProcessor( web3, handlers.ContractHandler, handlers.TransactionHandler); var valueTransactionProcessor = new ValueTransactionProcessor( handlers.TransactionHandler); var transactionProcessor = new TransactionProcessor( web3, contractTransactionProcessor, valueTransactionProcessor, contractCreationTransactionProcessor, transactionLogProcessor, filters?.TransactionFilters, filters?.TransactionReceiptFilters, filters?.TransactionAndReceiptFilters); if (postVm) { return new BlockVmPostProcessor( web3, handlers.BlockHandler, transactionProcessor) { ProcessTransactionsInParallel = processTransactionsInParallel } } ; transactionProcessor.ContractTransactionProcessor.EnabledVmProcessing = false; return(new BlockProcessor( web3, handlers.BlockHandler, transactionProcessor, filters?.BlockFilters) { ProcessTransactionsInParallel = processTransactionsInParallel }); } }
public AzureEventIndexingProcessor( IBlockchainProxyService blockchainProxyService, IAzureEventSearchService searchService, Func <ulong, ulong?, IBlockProgressService> blockProgressServiceCallBack = null, uint maxBlocksPerBatch = 2, IEnumerable <NewFilterInput> filters = null, uint minimumBlockConfirmations = 0) { SearchService = searchService; BlockchainProxyService = blockchainProxyService; MaxBlocksPerBatch = maxBlocksPerBatch; _filters = filters; MinimumBlockConfirmations = minimumBlockConfirmations; _blockProgressServiceCallBack = blockProgressServiceCallBack; _logProcessors = new List <ILogProcessor>(); _indexers = new List <IEventIndexer>(); }
public EventIndexingProcessor( IBlockchainProxyService blockchainProxyService, ISearchService searchService, IEventFunctionProcessor functionProcessor, Func <ulong, ulong?, IBlockProgressService> blockProgressServiceCallBack = null, uint maxBlocksPerBatch = 2, IEnumerable <NewFilterInput> filters = null, uint minimumBlockConfirmations = 0) { SearchService = searchService; BlockchainProxyService = blockchainProxyService; MaxBlocksPerBatch = maxBlocksPerBatch; Filters = filters; MinimumBlockConfirmations = minimumBlockConfirmations; BlockProgressServiceCallBack = blockProgressServiceCallBack; LogProcessors = new List <ILogProcessor>(); _indexers = new List <IIndexer>(); FunctionProcessor = functionProcessor ?? new EventFunctionProcessor(BlockchainProxyService); }
public EventFunctionProcessor( IBlockchainProxyService blockchainProxyService) { _blockchainProxyService = blockchainProxyService; _eventToHandlerMapping = new Dictionary <Type, List <ITransactionHandler> >(); }
public static IBlockProcessor Create(IBlockchainProxyService web3, HandlerContainer handlers, FilterContainer filters = null, bool postVm = false, bool processTransactionsInParallel = true) { return(Create(web3, new VmStackErrorCheckerWrapper(), handlers, filters, postVm, processTransactionsInParallel)); }