Closed asubiotto closed 1 year ago
Another option is to just use math.MaxInt64
and Flush
when we're done.
We're probably not going to use the SortingWriter
given it's a 30% performance hit vs just writing to a buffer, sorting and copying to a writer so happy to close this PR.
Maybe we need to document the SortingWriter is supposed to be used for stuff where the working set does not fit in memory? (This is its intended use case).
Achille also recommends using the RowBuffer (instead of just a buffer) but maybe you are doing that.
Thanks! Actually we are not using the RowBuffer. Will try it out.
The motivation for this is to allow callers that know how many rows they want to write to be able to reuse pooled SortingWriters.
This is a proposal for now, I have yet to integrate this into our (Polar Signals') usage, but I foresee us needing something like this. Happy to discuss.