You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[C++][Dataset] Use an ExecPlan for synchronous scans or drop synchronous scans #29004
ARROW-13238 ensured that asynchronous dataset scans are internally backed by ExecPlans, allowing easier integration with new ExecNode sinks.
However synchronous scans are still backed by FilterAndProjectScanTask and are not consumable using ExecNodes. Ideally, we should route synchronous scans through an ExecPlan as well.
Eduardo Ponce / @edponce:
What are the benefits/differences between using synchronous vs asynchronous scans (besides the obvious synchronization behavior)? For example, in the context of reproducibility, testing, and benchmarking.
Weston Pace / @westonpace:
The asynchronous scanner can (and does) read synchronously when it is warranted (e.g. IPC). So at the moment the asynchronous scanner is as fast or faster in (I think) all cases but only noticeably faster when you're actually reading from I/O. If the data is all in memory there isn't much difference.
The synchronous scanner is less complex and was kept around in case there was a bug detected in the asynchronous scanner it would allow a fallback to the synchronous scanner to avoid regressions.
I agree with David though that we can, at some point, just get rid of the synchronous scanner. I think Ben encountered several bugs (which were addressed) in his use of the async scanner for ARROW-13238 so it's probably not bug free. On the other hand, we've been using it for a while now and I wouldn't say we've run into anything major.
David Li / @lidavidm:
Maybe we should start thinking of a deprecation timeline for the sync scanner, then, and whether we want the async scanner to be default in 5.0.
Ben Kietzman / @bkietz:
Deprecating the synchronous Scanner is definitely preferable and if we're going to do this sooner than later then we can leave FilterAndProjectScanTask be for a while longer.
On the other hand, we've been using it for a while now and I wouldn't say we've run into anything major.
I think in the bindings (at least Python, where there is a use_async=False), we are still using the sync scanner by default, though. So while we are running our tests with both the async / sync scanner, I suppose the async one hasn't seen much "real world" usage by users?
Activity
asfimport commentedon Jul 13, 2021
Ben Kietzman / @bkietz:
@lidavidm @westonpace
asfimport commentedon Jul 13, 2021
David Li / @lidavidm:
Is this worth doing over just dropping synchronous scans?
asfimport commentedon Jul 13, 2021
Eduardo Ponce / @edponce:
What are the benefits/differences between using synchronous vs asynchronous scans (besides the obvious synchronization behavior)? For example, in the context of reproducibility, testing, and benchmarking.
asfimport commentedon Jul 13, 2021
Weston Pace / @westonpace:
The asynchronous scanner can (and does) read synchronously when it is warranted (e.g. IPC). So at the moment the asynchronous scanner is as fast or faster in (I think) all cases but only noticeably faster when you're actually reading from I/O. If the data is all in memory there isn't much difference.
The synchronous scanner is less complex and was kept around in case there was a bug detected in the asynchronous scanner it would allow a fallback to the synchronous scanner to avoid regressions.
I agree with David though that we can, at some point, just get rid of the synchronous scanner. I think Ben encountered several bugs (which were addressed) in his use of the async scanner for ARROW-13238 so it's probably not bug free. On the other hand, we've been using it for a while now and I wouldn't say we've run into anything major.
asfimport commentedon Jul 14, 2021
David Li / @lidavidm:
Maybe we should start thinking of a deprecation timeline for the sync scanner, then, and whether we want the async scanner to be default in 5.0.
asfimport commentedon Jul 14, 2021
Ben Kietzman / @bkietz:
Deprecating the synchronous Scanner is definitely preferable and if we're going to do this sooner than later then we can leave
FilterAndProjectScanTaskbe for a while longer.asfimport commentedon Jul 14, 2021
Ben Kietzman / @bkietz:
https://issues.apache.org/jira/browse/ARROW-13338
asfimport commentedon Jul 16, 2021
Joris Van den Bossche / @jorisvandenbossche:
I think in the bindings (at least Python, where there is a
use_async=False), we are still using the sync scanner by default, though. So while we are running our tests with both the async / sync scanner, I suppose the async one hasn't seen much "real world" usage by users?asfimport commentedon Jul 16, 2021
Joris Van den Bossche / @jorisvandenbossche:
Which raises the question of course: should we maybe switch the default for pyarrow 5.0.0? (EDIT, ah I see that's ARROW-13338 linked by Ben above)
asfimport commentedon Jan 14, 2022
Weston Pace / @westonpace:
ARROW-13554 removed synchronous scans.