From a9bf9487dd84c8a874f5a71b2557b57801308249 Mon Sep 17 00:00:00 2001 From: Sergey Prokofiev Date: Wed, 26 Jun 2019 00:46:44 +0300 Subject: [PATCH] MINOR: Fix for typos in processor-api.html (#6961) This PR intendent to address some typos in https://kafka.apache.org/documentation/streams/developer-guide/processor-api.html page. Invalid configuration option specified in the example. I've replaced with closest constant TopicConfig.MIN_IN_SYNC_REPLICAS_CONFIG, since LogConfig.MinInSyncReplicasProp() requires Scala stuff Reference to LogConfig seems to be obsolete, I believe I've moved it to correct line Apostrophe displayed incorrectly Reviewers: John Roesler , Bill Bejeck --- docs/streams/developer-guide/processor-api.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/streams/developer-guide/processor-api.html b/docs/streams/developer-guide/processor-api.html index 31c11edc169..89d3447cdd7 100644 --- a/docs/streams/developer-guide/processor-api.html +++ b/docs/streams/developer-guide/processor-api.html @@ -309,7 +309,7 @@

Enable or Disable Fault Tolerance of State Stores (Store Changelogs)

You can enable or disable fault tolerance for a state store by enabling or disabling the change logging of the store through enableLogging() and disableLogging(). - You can also fine-tune the associated topic’s configuration if needed.

+ You can also fine-tune the associated topic’s configuration if needed.

Example for disabling fault-tolerance:

import org.apache.kafka.streams.state.StoreBuilder;
 import org.apache.kafka.streams.state.Stores;
@@ -326,14 +326,14 @@
                     

If the changelog is disabled then the attached state store is no longer fault tolerant and it can’t have any standby replicas.

Here is an example for enabling fault tolerance, with additional changelog-topic configuration: - You can add any log config from kafka.log.LogConfig. + You can add any log config from kafka.log.LogConfig. Unrecognized configs will be ignored.

import org.apache.kafka.streams.state.StoreBuilder;
 import org.apache.kafka.streams.state.Stores;
 
 Map<String, String> changelogConfig = new HashMap();
 // override min.insync.replicas
-changelogConfig.put("min.insyc.replicas", "1")
+changelogConfig.put(TopicConfig.MIN_IN_SYNC_REPLICAS_CONFIG, "1")
 
 StoreBuilder<KeyValueStore<String, Long>> countStoreSupplier = Stores.keyValueStoreBuilder(
   Stores.persistentKeyValueStore("Counts"),