You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/11/19 22:13:24 UTC

[GitHub] [incubator-druid] jihoonson commented on a change in pull request #8810: Make supervisor API similar to submit task API

jihoonson commented on a change in pull request #8810: Make supervisor API similar to submit task API
URL: https://github.com/apache/incubator-druid/pull/8810#discussion_r348191868
 
 

 ##########
 File path: extensions-core/kafka-indexing-service/src/main/java/org/apache/druid/indexing/kafka/supervisor/KafkaSupervisorSpec.java
 ##########
 @@ -42,8 +42,23 @@
 {
   private static final String TASK_TYPE = "kafka";
 
+  private static KafkaSupervisorTuningConfig getTuningConfig(
+      KafkaSupervisorIngestionSpec ingestionSchema,
+      KafkaSupervisorTuningConfig tuningConfig
+  )
+  {
+    if (ingestionSchema != null) {
+      return ingestionSchema.getTuningConfig() != null
+             ? ingestionSchema.getTuningConfig()
+             : KafkaSupervisorTuningConfig.defaultConfig();
+    } else {
+      return tuningConfig != null ? tuningConfig : KafkaSupervisorTuningConfig.defaultConfig();
+    }
+  }
+
   @JsonCreator
   public KafkaSupervisorSpec(
+      @JsonProperty("spec") KafkaSupervisorIngestionSpec ingestionSchema,
 
 Review comment:
   Please annotate `ingestionSchema`, `dataSchema`, `tuningConfig`, and `ioConfig` with `@Nullable`.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org