Package com.linkedin.databus.client.consumer

Examples of com.linkedin.databus.client.consumer.LoggingConsumer


    DatabusSourcesConnection.StaticConfig srcConnConf = clientConf.getConnectionDefaults();

    DatabusHttpClientImpl client = new DatabusHttpClientImpl(clientConf);

    if (bootstrapEnabled)
      client.registerDatabusBootstrapListener(new LoggingConsumer(), null, "source1");

    Assert.assertNotNull(client, "client instantiation ok");

    DatabusHttpClientImpl.RuntimeConfig clientRtConf = clientConf.getRuntime().build();
View Full Code Here


    } else {
      _consumerCallbackExecutor = Executors.newFixedThreadPool(
          consumerParallelism, new NamedThreadFactory("callback"));
    }

    LoggingConsumer loggingConsumer = null;
    if (serverHandle != null)
    {
      try
      {
        // we intentionally don't use serverHandle.getLoggingListener(); LoggingConsumer
        // isn't thread-safe, so we need one instance per connection
        loggingConsumer = new LoggingConsumer(serverHandle.getClientStaticConfig().getLoggingListener());
      }
      catch (InvalidConfigException e)
      {
        throw new DatabusRuntimeException(e)// alternatively:  declare InvalidConfigException, let it go
      }
View Full Code Here

                                                  true,
                                                  getMbeanServer());
    }
    _httpStatsCollector = httpStatsColl;

    _loggingConsumer = new LoggingConsumer(_clientStaticConfig.getLoggingListener());

    _clientStaticConfig.getRuntime().setManagedInstance(this);
    _configManager = new ConfigManager<RuntimeConfig>(_clientStaticConfig.getRuntimeConfigPrefix(),
                                                      _clientStaticConfig.getRuntime());
View Full Code Here

    DatabusHttpClientImpl.StaticConfig clientConf = clientConfBuilder.build();
    DatabusSourcesConnection.StaticConfig srcConnConf = clientConf.getConnectionDefaults();

    DatabusHttpClientImpl client = new DatabusHttpClientImpl(clientConf);

    client.registerDatabusBootstrapListener(new LoggingConsumer(), null, "source1");

    Assert.assertNotNull(client, "client instantiation failed");

    DatabusHttpClientImpl.RuntimeConfig clientRtConf = clientConf.getRuntime().build();
View Full Code Here

    DatabusHttpClientImpl.StaticConfig clientConf = clientConfBuilder.build();
    DatabusSourcesConnection.StaticConfig srcConnConf = clientConf.getConnectionDefaults();

    DatabusHttpClientImpl client = new DatabusHttpClientImpl(clientConf);

    client.registerDatabusBootstrapListener(new LoggingConsumer(), null, "source1");

    Assert.assertNotNull(client, "client instantiation ok");

    DatabusHttpClientImpl.RuntimeConfig clientRtConf = clientConf.getRuntime().build();
View Full Code Here

      client.registerDatabusStreamListener(listener2 , null, "S1");
      int consumersNum = safeListSize(client.getRelayGroupStreamConsumers().get(ls1)) +
      safeListSize(client.getRelayGroupStreamConsumers().get(ls2));
      assertEquals("expect two consumers in (S1,S2) or (S1,S3)", 2, consumersNum);

      DatabusStreamConsumer listener3 = new LoggingConsumer(clientConfig.getLoggingListener());
      client.registerDatabusStreamListener(listener3, null, "S5");
      assertEquals("expect one consumer in (S3,S4,S5)", 1,
                   safeListSize(client.getRelayGroupStreamConsumers().get(ls3)));

View Full Code Here

TOP

Related Classes of com.linkedin.databus.client.consumer.LoggingConsumer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.