Skip to content

Commit e322c1c

Browse files
authored
Fix invalid documentation for StreamingQueryManager Class
When following the example for using `spark.streams().awaitAnyTermination()` a valid pyspark code will output the following error: ```Traceback (most recent call last): File "pyspark_app.py", line 182, in <module> spark.streams().awaitAnyTermination() TypeError: 'StreamingQueryManager' object is not callable``` This changes the documentation line to properly call the method under the StreamingQueryManager Class https://spark.apache.org/docs/latest/api/python/pyspark.sql.html#pyspark.sql.streaming.StreamingQueryManager
1 parent eec1a3c commit e322c1c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/structured-streaming-programming-guide.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2554,11 +2554,11 @@ spark.streams().awaitAnyTermination(); // block until any one of them terminat
25542554
{% highlight python %}
25552555
spark = ... # spark session
25562556

2557-
spark.streams().active # get the list of currently active streaming queries
2557+
spark.streams.active # get the list of currently active streaming queries
25582558

2559-
spark.streams().get(id) # get a query object by its unique id
2559+
spark.streams.get(id) # get a query object by its unique id
25602560

2561-
spark.streams().awaitAnyTermination() # block until any one of them terminates
2561+
spark.streams.awaitAnyTermination() # block until any one of them terminates
25622562
{% endhighlight %}
25632563

25642564
</div>

0 commit comments

Comments
 (0)