Beispiel #1
0
  @Override
  public void configure(Binder binder) {
    JsonConfigProvider.bind(binder, "druid.emitter.http", HttpEmitterConfig.class);

    final SSLContext context;
    try {
      context = SSLContext.getDefault();
    } catch (NoSuchAlgorithmException e) {
      throw Throwables.propagate(e);
    }

    binder.bind(SSLContext.class).toProvider(Providers.of(context)).in(LazySingleton.class);
  }
  @Override
  public void configure(Binder binder) {
    Binders.dataSegmentPullerBinder(binder)
        .addBinding("c*")
        .to(CassandraDataSegmentPuller.class)
        .in(LazySingleton.class);

    PolyBind.optionBinder(binder, Key.get(DataSegmentPusher.class))
        .addBinding("c*")
        .to(CassandraDataSegmentPusher.class)
        .in(LazySingleton.class);
    JsonConfigProvider.bind(binder, "druid.storage", CassandraDataSegmentConfig.class);
  }
  @Override
  public void configure(Binder binder) {
    JsonConfigProvider.bind(binder, "druid.azure", AzureAccountConfig.class);

    Binders.dataSegmentPullerBinder(binder)
        .addBinding(SCHEME)
        .to(AzureDataSegmentPuller.class)
        .in(LazySingleton.class);

    Binders.dataSegmentPusherBinder(binder)
        .addBinding(SCHEME)
        .to(AzureDataSegmentPusher.class)
        .in(LazySingleton.class);

    Binders.dataSegmentKillerBinder(binder)
        .addBinding(SCHEME)
        .to(AzureDataSegmentKiller.class)
        .in(LazySingleton.class);

    Binders.taskLogsBinder(binder).addBinding(SCHEME).to(AzureTaskLogs.class);
    JsonConfigProvider.bind(binder, "druid.indexer.logs", AzureTaskLogsConfig.class);
    binder.bind(AzureTaskLogs.class).in(LazySingleton.class);
  }