[ 
https://issues.apache.org/jira/browse/SPARK-62249?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated SPARK-62249:
-----------------------------------
    Labels: pull-request-available  (was: )

> Report the Python objects of the options of readers and writers to the 
> garbage collector only as gc-shared's rules allow: clone them and hold their 
> state's lock only with the GIL
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: SPARK-62249
>                 URL: https://issues.apache.org/jira/browse/SPARK-62249
>             Project: Spark
>          Issue Type: Improvement
>          Components: Connect
>    Affects Versions: 5.0.0
>            Reporter: Hyukjin Kwon
>            Priority: Major
>              Labels: pull-request-available
>
> The Python client reports the Python objects of the options of readers and 
> writers to Python's garbage collector by conditions that a call without the 
> GIL can change between the collector's passes: 
> UnencodableOptions::visit_objects (crates/pyspark-rs/src/options.rs) reports 
> them only while Arc::strong_count == 1, and WriterState::visit reports 
> nothing while try_lock of its state fails. No call clones them or holds that 
> lock without the GIL today, but nothing enforces it, so a later change could 
> make the collector see inconsistent references. Report them only as the rules 
> of the garbage collection of shared parts (SPARK-62235) allow: clone the 
> options and hold the writer state's lock only with the GIL, enforced by 
> construction, with a test.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to