@Override public void configure() { bind(ThriftClientProvider.class).toProvider(ThriftClientProviderSupplier.class); bind(HBaseTableUtil.class).toProvider(HBaseTableUtilFactory.class); // bind transactions bind(TransactionSystemClientService.class).to(DistributedTransactionSystemClientService.class); install(Modules.override(new TransactionModules(txClientId).getDistributedModules()).with(new AbstractModule() { @Override protected void configure() { // Binds the tephra MetricsCollector to the one that emit metrics via MetricsCollectionService bind(MetricsCollector.class).to(TransactionManagerMetricsCollector.class).in(Scopes.SINGLETON); } })); install(new TransactionExecutorModule()); install(new StorageModule()); }
@Override public void configure() { bind(LevelDBTableService.class).in(Scopes.SINGLETON); // bind transactions bind(TransactionSystemClientService.class).to(DelegatingTransactionSystemClientService.class); install(Modules.override(new TransactionModules().getSingleNodeModules()).with(new AbstractModule() { @Override protected void configure() { // Binds the tephra MetricsCollector to the one that emit metrics via MetricsCollectionService bind(MetricsCollector.class).to(TransactionManagerMetricsCollector.class).in(Scopes.SINGLETON); } })); install(new TransactionExecutorModule()); install(new StorageModule()); } }
@Override protected void configure() { // bind transactions bind(TransactionSystemClientService.class).to(DelegatingTransactionSystemClientService.class); install(Modules.override(new TransactionModules(txClientId).getInMemoryModules()).with(new AbstractModule() { @Override protected void configure() { // Binds the tephra MetricsCollector to the one that emit metrics via MetricsCollectionService bind(MetricsCollector.class).to(TransactionManagerMetricsCollector.class).in(Scopes.SINGLETON); } })); install(new TransactionExecutorModule()); install(new StorageModule()); } }