From 4cf81285dac0a4e901179a44bfa62cb51e33bee6 Mon Sep 17 00:00:00 2001 From: cyq89051127 Date: Tue, 27 Aug 2019 08:13:39 -0500 Subject: [PATCH] [SPARK-28871][MINOR][DOCS] WaterMark doc fix ### What changes were proposed in this pull request? The code style in the 'Policy for handling multiple watermarks' in structured-streaming-programming-guide.md ### Why are the changes needed? Making it look friendly to user. ### Does this PR introduce any user-facing change? NO ### How was this patch tested? cd docs SKIP_API=1 jekyll build Closes #25580 from cyq89051127/master. Authored-by: cyq89051127 Signed-off-by: Sean Owen --- docs/structured-streaming-programming-guide.md | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/structured-streaming-programming-guide.md b/docs/structured-streaming-programming-guide.md index b0d3e162c2..deaf262c5f 100644 --- a/docs/structured-streaming-programming-guide.md +++ b/docs/structured-streaming-programming-guide.md @@ -1583,10 +1583,18 @@ be tolerated for stateful operations. You specify these thresholds using ``withWatermarks("eventTime", delay)`` on each of the input streams. For example, consider a query with stream-stream joins between `inputStream1` and `inputStream2`. - inputStream1.withWatermark("eventTime1", "1 hour") - .join( - inputStream2.withWatermark("eventTime2", "2 hours"), - joinCondition) +
+
+ +{% highlight scala %} +inputStream1.withWatermark("eventTime1", "1 hour") + .join( + inputStream2.withWatermark("eventTime2", "2 hours"), + joinCondition) +{% endhighlight %} + +
+
While executing the query, Structured Streaming individually tracks the maximum event time seen in each input stream, calculates watermarks based on the corresponding delay,