@Override
        public void process(final Record<String, String> record) {
            final String[] words = record.value().toLowerCase(Locale.getDefault()).split("\\W+");

            for (final String word : words) {
                final Integer oldValue = kvStore.get(word);

                if (oldValue == null) {
                    kvStore.put(word, 1);
                } else {
                    kvStore.put(word, oldValue + 1);
                }
            }
        }
Demonstrates, using the low-level Processor APIs, how to implement the WordCount program
that computes a simple word occurrence histogram from an input text.
<p>
<strong>Note: This is simplified code that only works correctly for single partition input topics.
Check out {@link WordCountDemo} for a generic example.</strong>
<p>
In this example, the input stream reads from a topic named "streams-plaintext-input", where the values of messages
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.
<p>
Before running this example you must create the input topic and the output topic (e.g. via
{@code bin/kafka-topics.sh --create ...}), and write some data to the input topic (e.g. via
{@code bin/kafka-console-producer.sh}). Otherwise you won't see any data arriving in the output topic.
streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountProcessorDemo.java