[
https://issues.apache.org/jira/browse/SPARK-62287?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated SPARK-62287:
-----------------------------------
Labels: pull-request-available (was: )
> Deep-copy a data type of the Python client natively when its class is the
> native one, as PySpark's copy reconstructs it
> -----------------------------------------------------------------------------------------------------------------------
>
> Key: SPARK-62287
> URL: https://issues.apache.org/jira/browse/SPARK-62287
> Project: Spark
> Issue Type: Improvement
> Components: Connect
> Affects Versions: 5.0.0
> Reporter: Hyukjin Kwon
> Priority: Major
> Labels: pull-request-available
>
> Once SPARK-62251's StructType keeps its fields in its __dict__, copy.deepcopy
> of a StructType of 1,000 fields takes 8.3 ms in the Python client, against
> 5.9 ms in PySpark 4.3.0 (8.1 ms on master); df.schema and df.to(...).schema
> run that copy. Deep-copy a data type natively when its class is exactly the
> native one, honoring the memo of copy.deepcopy as Python's _reconstruct does
> (shared objects map to one copy, with the same memo entries); subclasses keep
> Python's protocol and their __reduce_ex__.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]