KafkaStorageBuilder extends StorageComponent.Builder { public KafkaStorageBuilder storageStateDir(String storageStateDir) { if (storageStateDir == null) throw new NullPointerException("storageStateDir == null"); spanAggregation.storageStateDir(storageStateDir); traceStorage.storageStateDir(storageStateDir); dependencyStorage.storageStateDir(storageStateDir); return this; } KafkaStorageBuilder(); @Override KafkaStorageBuilder strictTraceId(boolean strictTraceId); @Override KafkaStorageBuilder searchEnabled(boolean searchEnabled); @Override KafkaStorageBuilder autocompleteKeys(List<String> keys); KafkaStorageBuilder bootstrapServers(String bootstrapServers); KafkaStorageBuilder storageStateDir(String storageStateDir); final KafkaStorageBuilder overrides(Map<String, ?> overrides); KafkaStorageBuilder hostname(String hostname); KafkaStorageBuilder serverPort(int serverPort); KafkaStorageBuilder spanPartitioningBuilder(SpanPartitioningBuilder builder); KafkaStorageBuilder spanAggregationBuilder(SpanAggregationBuilder builder); KafkaStorageBuilder traceStorageBuilder(TraceStorageBuilder builder); KafkaStorageBuilder dependencyStorageBuilder(DependencyStorageBuilder builder); @Override StorageComponent build();  }
@Test void buildDefaultBuilder() { KafkaStorageBuilder builder = KafkaStorage.newBuilder(); assertThatThrownBy(() -> builder.spanPartitioning.spansTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.spanAggregation.spansTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.spanAggregation.traceTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.spanAggregation.dependencyTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.traceStorage.spansTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.dependencyStorage.dependencyTopic(null)) .isInstanceOf(NullPointerException.class); assertThatThrownBy(() -> builder.storageStateDir(null)) .isInstanceOf(NullPointerException.class); }