ableegoldman commented on a change in pull request #11272: URL: https://github.com/apache/kafka/pull/11272#discussion_r711723716
########## File path: streams/src/main/java/org/apache/kafka/streams/processor/internals/namedtopology/KafkaStreamsNamedTopologyWrapper.java ########## @@ -112,10 +113,42 @@ private KafkaStreamsNamedTopologyWrapper(final Collection<NamedTopology> topolog ); } + /** + * Provides a high-level DSL for specifying the processing logic of your application and building it into an + * independent topology that can be executed by this {@link KafkaStreams}. + * + * @param topologyName The name for this topology + * @param topologyConfigs The properties and any config overrides for this topology + * + * @throws IllegalArgumentException if the name contains the character sequence "__" + */ + public NamedTopologyBuilder newNamedTopologyBuilder(final String topologyName, final Properties topologyConfigs) { + if (topologyName.contains(TaskId.NAMED_TOPOLOGY_DELIMITER)) { + throw new IllegalArgumentException("The character sequence '__' is not allowed in a NamedTopology, please select a new name"); + } + return new NamedTopologyBuilder(topologyName, applicationConfigs, topologyConfigs); + } + + /** + * Returns an empty topology for full control over the graph of streams and processor nodes that define the processing + * logic to be executed by this {@link KafkaStreams}. + * + * @param topologyName The name for this topology + * @param topologyConfigs The properties and any config overrides for this topology + * + * @throws IllegalArgumentException if the name contains the character sequence "__" + */ + public NamedTopology newNamedTopology(final String topologyName, final Properties topologyConfigs) { Review comment: Well eventually we'll want to support building a NamedTopology with the PAPI rather than the DSL, but I can remove this for the time being to keep the API minimal until we've figured out exactly what it will look like & gone through the KIP -- 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. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org