You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/02/26 09:10:21 UTC

[GitHub] Nimfadora commented on a change in pull request #23791: [SPARK-20597][SQL][SS][WIP] KafkaSourceProvider falls back on path as synonym for topic

Nimfadora commented on a change in pull request #23791: [SPARK-20597][SQL][SS][WIP] KafkaSourceProvider falls back on path as synonym for topic
URL: https://github.com/apache/spark/pull/23791#discussion_r260187263
 
 

 ##########
 File path: docs/structured-streaming-kafka-integration.md
 ##########
 @@ -499,20 +522,28 @@ StreamingQuery ds = df
   .option("topic", "topic1")
   .start();
 
-// Write key-value data from a DataFrame to Kafka using a topic specified in the data
+// Write key-value data from a DataFrame to Kafka using the topic specified in the data
 StreamingQuery ds = df
   .selectExpr("topic", "CAST(key AS STRING)", "CAST(value AS STRING)")
   .writeStream()
   .format("kafka")
   .option("kafka.bootstrap.servers", "host1:port1,host2:port2")
   .start();
 
+// Write key-value data from a DataFrame to Kafka using the topic specified in the path option
+StreamingQuery ds = df
+  .selectExpr("CAST(key AS STRING)", "CAST(value AS STRING)")
 
 Review comment:
   would it be better to change it in all places in this doc file if we anyway touch it?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org