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
Add ability to reuse DictionaryTracker when creating new IPC Stream #9195
Is your feature request related to a problem or challenge? Please describe what you are trying to do.
We're working on a protocol that sends/receives a stream of record batches as an encapsulated Arrow IPC stream. The stream of record batches has a dynamic schema, so each time the schema changes we begin a new IPC Stream.
Rather than throwing away and recreating an arrow_ipc::writer::StreamWriter each time this happens, which is wasteful/expensive, we created our own type for producing the IPC stream that tries to reuse as much as it can. However, for each stream it's still creating a new DictionaryTracker.
Describe the solution you'd like
I'd like for there to be a reset method on the DictionaryTracker that clears any internal state so I can reuse it without the allocation cost of creating a new one.
Describe alternatives you've considered
I had considered adding a reset method to StreamWriter. I might do that anyway in a followup PR if we're OK with it. But this method on StreamWriter would need to reset the DictionaryTracker anyway, so the solution described in this issue seemed like a good first step.
Activity
arrow-ipc: add reset method to DictionaryTracker (apache#9196)