Connect to a Spark session
castKafkaStreamAsString(streamObj)
Spark Structured Streaming DataFrame returned by read.stream
function with source = 'kafka'
Updated Spark Structured Streaming DataFrame with key, value, topic and timestamp from the Kafka stream
Takes in a Structured Stream from Kafka created from read.stream(source = 'kafka', ...)
and returns
a Structured Streaming DataFrame where the key
and value
from the Kafka stream are cast to string
Other Spark utilities: convertKafkaValueFromJson
,
sparkRSessionCreateIfNotPresent