New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SPARK-22340][PYTHON][FOLLOW-UP] Add a better message and improve documentation for pinned thread mode #26588
Conversation
cc @squito and @WeichenXu123 |
Test build #114044 has finished for PR 26588 at commit
|
Test build #114050 has finished for PR 26588 at commit
|
retest this please |
Test build #114054 has finished for PR 26588 at commit
|
I like improving the error msg. I'm not so sure about including the extra msg explaining the custom thread code, I have a feeling its more confusing than useful. I feel like users often won't even be creating threads themselves -- eg. they're running an http server which has a thread pool in it somewhere, but the developer doesn't even see it. It seems much more straightforward to just reset the relevant properties in each thread. Maybe I'm not properly understanding how folks use the inheritable properties? |
Hm, right. I just realised that the use cases can be different. In our case, it needs to launch multiple jobs in multiple threads with each group id. Later, in the main thread, it cancels the jobs by the job group id. Let me just remove the workaround codes. I think I agree that it might more cause confusions. |
Test build #114182 has finished for PR 26588 at commit
|
Let me merge this one as is. I think it's now pretty conservative. |
👍 |
What changes were proposed in this pull request?
This PR proposes to show different warning message when the pinned thread mode is enabled:
When enabled:
When disabled:
Why are the changes needed?
Currently, it shows the same warning message regardless of PYSPARK_PIN_THREAD being set. In the warning message it says "you can set PYSPARK_PIN_THREAD to true ..." which is confusing.
Does this PR introduce any user-facing change?
Documentation and warning message as shown above.
How was this patch tested?
Manually tested.