-
I’m enjoying using duckdb-wasm in the browser, and have a use case to transfer query results into a worker for post-processing. The result set is around around 9MB in size. I serialise to Arrow IPC with tableToIPC(queryResult) for transfer .. which takes around 500ms. Is this the correct approach to move the result to the worker? The 500ms serialisation noticeably locks the main thread and I can’t see that is avoidable? Cheers, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Huh, since DuckDB wasm already uses arrow ipc to send data from the db worker to the main thread, I think it should be easy to redirect the stream to another worker. I'd need to check whether have api for that already but if not, we should add that. Another approach could be to initiate the query from the worker. Have you tried that? |
Beta Was this translation helpful? Give feedback.
Huh, since DuckDB wasm already uses arrow ipc to send data from the db worker to the main thread, I think it should be easy to redirect the stream to another worker. I'd need to check whether have api for that already but if not, we should add that.
Another approach could be to initiate the query from the worker. Have you tried that?