Yicong Huang created SPARK-56189:
------------------------------------
Summary: Refactor SQL_GROUPED_AGG_ARROW_UDF and
SQL_GROUPED_AGG_ARROW_ITER_UDF to use ArrowStreamSerializer
Key: SPARK-56189
URL: https://issues.apache.org/jira/browse/SPARK-56189
Project: Spark
Issue Type: Sub-task
Components: SQL, PySpark
Affects Versions: 4.2.0
Reporter: Yicong Huang
Move the processing logic for SQL_GROUPED_AGG_ARROW_UDF and
SQL_GROUPED_AGG_ARROW_ITER_UDF out of ArrowStreamAggArrowUDFSerializer and into
read_udfs() in worker.py, using ArrowStreamSerializer as a pure I/O layer.
This is part of the incremental serializer refactor (SPARK-55388). The change:
- Deletes wrap_grouped_agg_arrow_udf() and wrap_grouped_agg_arrow_iter_udf()
wrapper functions
- Returns raw (func, args_offsets, kwargs_offsets, return_type) from
read_single_udf()
- Adds self-contained processing blocks in read_udfs() that handle grouped
input, UDF invocation, and output coercion
- Replaces ArrowStreamAggArrowUDFSerializer with
ArrowStreamSerializer(write_start_stream=True, num_dfs=1)
- Fixes a latent infinite recursion bug in _load_group_dataframes when num_dfs
!= 0 by extracting _read_arrow_stream()
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]