gaogaotiantian commented on code in PR #54258:
URL: https://github.com/apache/spark/pull/54258#discussion_r2801244383
##########
python/pyspark/worker_util.py:
##########
@@ -155,39 +155,42 @@ def setup_spark_files(infile: IO) -> None:
def setup_broadcasts(infile: IO) -> None:
"""
Set up broadcasted variables.
+ {
+ "conn_info": int | str | None,
+ "auth_secret": str | None,
+ "broadcast_variables": [
+ {
+ "bid": int,
+ "path": str | None,
+ }
+ ]
+ }
"""
if not is_remote_only():
from pyspark.core.broadcast import Broadcast, _broadcastRegistry
- # fetch names and values of broadcast variables
- needs_broadcast_decryption_server = read_bool(infile)
- num_broadcast_variables = read_int(infile)
- if needs_broadcast_decryption_server:
+ data = json.loads(utf8_deserializer.loads(infile))
Review Comment:
Sorry use what? This is part of the JVM <-> Python worker protocol. We are
not adding any new features. JVM used to send broadcast variable information
integer by integer (with some strings in the middle) to Python. Now instead of
that raw fragile protocol, we send all of the broadcast variable information in
a JSON string.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]