Repository: kafka Updated Branches: refs/heads/trunk afeadbef5 -> 6ba98f6e5
MINOR: Improve topic management instructions for Kafka Streams examples Author: Michael G. Noll <[email protected]> Reviewers: Matthias J. Sax <[email protected]>, Eno Thereska <[email protected]>, Ismael Juma <[email protected]> Closes #2812 from miguno/trunk-streams-examples-docs Project: http://git-wip-us.apache.org/repos/asf/kafka/repo Commit: http://git-wip-us.apache.org/repos/asf/kafka/commit/6ba98f6e Tree: http://git-wip-us.apache.org/repos/asf/kafka/tree/6ba98f6e Diff: http://git-wip-us.apache.org/repos/asf/kafka/diff/6ba98f6e Branch: refs/heads/trunk Commit: 6ba98f6e5ad8776b7268441b5392330496565814 Parents: afeadbe Author: Michael G. Noll <[email protected]> Authored: Thu Apr 6 12:34:19 2017 +0100 Committer: Ismael Juma <[email protected]> Committed: Thu Apr 6 12:34:19 2017 +0100 ---------------------------------------------------------------------- .../kafka/streams/examples/pageview/PageViewTypedDemo.java | 7 ++++--- .../kafka/streams/examples/pageview/PageViewUntypedDemo.java | 5 +++-- .../java/org/apache/kafka/streams/examples/pipe/PipeDemo.java | 5 +++-- .../kafka/streams/examples/wordcount/WordCountDemo.java | 5 +++-- .../streams/examples/wordcount/WordCountProcessorDemo.java | 5 +++-- 5 files changed, 16 insertions(+), 11 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/kafka/blob/6ba98f6e/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewTypedDemo.java ---------------------------------------------------------------------- diff --git a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewTypedDemo.java b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewTypedDemo.java index a194f0f..f235044 100644 --- a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewTypedDemo.java +++ b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewTypedDemo.java @@ -41,12 +41,13 @@ import java.util.Properties; * using specific data types (here: JSON POJO; but can also be Avro specific bindings, etc.) for serdes * in Kafka Streams. * - * In this example, we join a stream of pageviews (aka clickstreams) that reads from a topic named "streams-pageview-input" + * In this example, we join a stream of pageviews (aka clickstreams) that reads from a topic named "streams-pageview-input" * with a user profile table that reads from a topic named "streams-userprofile-input", where the data format * is JSON string representing a record in the stream or table, to compute the number of pageviews per user region. * - * Before running this example you must create the source topic (e.g. via bin/kafka-topics.sh --create ...) - * and write some data to it (e.g. via bin-kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. + * Before running this example you must create the input topics and the output topic (e.g. via + * bin/kafka-topics.sh --create ...), and write some data to the input topics (e.g. via + * bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. */ public class PageViewTypedDemo { http://git-wip-us.apache.org/repos/asf/kafka/blob/6ba98f6e/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewUntypedDemo.java ---------------------------------------------------------------------- diff --git a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewUntypedDemo.java b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewUntypedDemo.java index 37b2bca..39e84e8 100644 --- a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewUntypedDemo.java +++ b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pageview/PageViewUntypedDemo.java @@ -49,8 +49,9 @@ import java.util.Properties; * with a user profile table that reads from a topic named "streams-userprofile-input", where the data format * is JSON string representing a record in the stream or table, to compute the number of pageviews per user region. * - * Before running this example you must create the source topic (e.g. via bin/kafka-topics.sh --create ...) - * and write some data to it (e.g. via bin-kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. + * Before running this example you must create the input topics and the output topic (e.g. via + * bin/kafka-topics.sh --create ...), and write some data to the input topics (e.g. via + * bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. */ public class PageViewUntypedDemo { http://git-wip-us.apache.org/repos/asf/kafka/blob/6ba98f6e/streams/examples/src/main/java/org/apache/kafka/streams/examples/pipe/PipeDemo.java ---------------------------------------------------------------------- diff --git a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pipe/PipeDemo.java b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pipe/PipeDemo.java index b1764d8..62b52c0 100644 --- a/streams/examples/src/main/java/org/apache/kafka/streams/examples/pipe/PipeDemo.java +++ b/streams/examples/src/main/java/org/apache/kafka/streams/examples/pipe/PipeDemo.java @@ -31,8 +31,9 @@ import java.util.Properties; * In this example, we implement a simple "pipe" program that reads from a source topic "streams-file-input" * and writes the data as-is (i.e. unmodified) into a sink topic "streams-pipe-output". * - * Before running this example you must create the source topic (e.g. via bin/kafka-topics.sh --create ...) - * and write some data to it (e.g. via bin-kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. + * Before running this example you must create the input topic and the output topic (e.g. via + * bin/kafka-topics.sh --create ...), and write some data to the input topic (e.g. via + * bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. */ public class PipeDemo { http://git-wip-us.apache.org/repos/asf/kafka/blob/6ba98f6e/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java ---------------------------------------------------------------------- diff --git a/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java b/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java index 74f0d5e..616228a 100644 --- a/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java +++ b/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java @@ -39,8 +39,9 @@ import java.util.Properties; * represent lines of text; and the histogram output is written to topic "streams-wordcount-output" where each record * is an updated count of a single word. * - * Before running this example you must create the source topic (e.g. via bin/kafka-topics.sh --create ...) - * and write some data to it (e.g. via bin-kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. + * Before running this example you must create the input topic and the output topic (e.g. via + * bin/kafka-topics.sh --create ...), and write some data to the input topic (e.g. via + * bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. */ public class WordCountDemo { http://git-wip-us.apache.org/repos/asf/kafka/blob/6ba98f6e/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java ---------------------------------------------------------------------- diff --git a/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java b/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java index d52d374..9ef24f0 100644 --- a/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java +++ b/streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java @@ -40,8 +40,9 @@ import java.util.Properties; * represent lines of text; and the histogram output is written to topic "streams-wordcount-processor-output" where each record * is an updated count of a single word. * - * Before running this example you must create the source topic (e.g. via bin/kafka-topics.sh --create ...) - * and write some data to it (e.g. via bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. + * Before running this example you must create the input topic and the output topic (e.g. via + * bin/kafka-topics.sh --create ...), and write some data to the input topic (e.g. via + * bin/kafka-console-producer.sh). Otherwise you won't see any data arriving in the output topic. */ public class WordCountProcessorDemo {
