Skip to content

Allow passing a different tokio runtime into DeltaOps to execute CPU-bound tasks #3800

@abhiaagarwal

Description

@abhiaagarwal

Description

Use Case

Per datafusion's recommendations, spawning a separate tokio runtime for CPU-bound tasks can lead to better tail latencies. Therefore, I propose that DeltaOps/Merge/Write/etcBuilder take an optional with_runtime parameter that allows passing an optional handle to another runtime. Then, delta-rs can spawn the task on a separate joinset, await it in there, and pass the result back to the io-bound handle via an oneshot channel.

This requires a bit more plumbing due to object_store calls inside of various executors, but that can be worked across with SpawnedReqwestConnector.

This could also potentially be benchmarked for the python impl to see if it substantially improves performance.

Related Issue(s)

Related to #3640.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions