Tabnine Logo
KafkaAvroEventReporter$Builder.withSchemaRegistry
Code IndexAdd Tabnine to your IDE (free)

How to use
withSchemaRegistry
method
in
org.apache.gobblin.metrics.kafka.KafkaAvroEventReporter$Builder

Best Java code snippets using org.apache.gobblin.metrics.kafka.KafkaAvroEventReporter$Builder.withSchemaRegistry (Showing top 3 results out of 315)

origin: apache/incubator-gobblin

if (Boolean.valueOf(properties.getProperty(ConfigurationKeys.METRICS_REPORTING_KAFKA_USE_SCHEMA_REGISTRY,
  ConfigurationKeys.DEFAULT_METRICS_REPORTING_KAFKA_USE_SCHEMA_REGISTRY))) {
 kafkaAvroEventReporterBuilder.withSchemaRegistry(new KafkaAvroSchemaRegistry(properties));
origin: apache/incubator-gobblin

KafkaEventReporter kafkaReporter =
  KafkaAvroEventReporter.forContext(context).withKafkaPusher(pusher)
    .withSchemaRegistry(registry).build("localhost:0000", "topic");
origin: org.apache.gobblin/gobblin-kafka-common

 /**
  * Get a {@link org.apache.gobblin.metrics.kafka.KafkaEventReporter.Builder} for this reporting format.
  * @param context {@link MetricContext} that should be reported.
  * @param properties {@link Properties} containing information to build reporters.
  * @return {@link org.apache.gobblin.metrics.kafka.KafkaEventReporter.Builder}.
  */
 public KafkaEventReporter.Builder<?> eventReporterBuilder(MetricContext context, Properties properties) {
  switch (this) {
   case AVRO:
    KafkaAvroEventReporter.Builder<?> builder = KafkaAvroEventReporter.Factory.forContext(context);
    if (Boolean.valueOf(properties.getProperty(ConfigurationKeys.METRICS_REPORTING_KAFKA_USE_SCHEMA_REGISTRY,
      ConfigurationKeys.DEFAULT_METRICS_REPORTING_KAFKA_USE_SCHEMA_REGISTRY))) {
     builder.withSchemaRegistry(new KafkaAvroSchemaRegistry(properties));
    }
    return builder;
   case JSON:
    return KafkaEventReporter.Factory.forContext(context);
   default:
    // This should never happen.
    throw new IllegalArgumentException("KafkaReportingFormat not recognized.");
  }
 }
}
org.apache.gobblin.metrics.kafkaKafkaAvroEventReporter$BuilderwithSchemaRegistry

Popular methods of KafkaAvroEventReporter$Builder

  • self
  • withKafkaPusher
  • build
    Builds and returns KafkaAvroEventReporter.

Popular in Java

  • Running tasks concurrently on multiple threads
  • setRequestProperty (URLConnection)
  • requestLocationUpdates (LocationManager)
  • findViewById (Activity)
  • FileInputStream (java.io)
    An input stream that reads bytes from a file. File file = ...finally if (in != null) in.clos
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Reference (javax.naming)
  • JFrame (javax.swing)
  • Option (scala)
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now