BryanCutler commented on a change in pull request #24834:
[WIP][SPARK-27992][PYTHON] Synchronize with Python connection thread to
propagate errors
URL: https://github.com/apache/spark/pull/24834#discussion_r292221803
##########
File path: core/src/main/scala/org/apache/spark/api/python/PythonRDD.scala
##########
@@ -470,6 +470,29 @@ private[spark] object PythonRDD extends Logging {
SocketAuthHelper.serveToStream(threadName, authHelper)(writeFunc)
}
+ /**
+ * Create a socket server object and background thread to execute the
writeFunc
+ * with the given OutputStream.
+ *
+ * This is the same as serveToStream, only it returns a server object that
+ * can be used to sync in Python.
+ */
+ private[spark] def serveToStreamWithSync(
Review comment:
This could be cleaned up and replace the existing `serveToStream`. It just
returns the `SocketAuthServer` object as the third element in the Array, and it
could be ignored if no synchronization is needed.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]