joechenrh opened a new pull request, #302: URL: https://github.com/apache/arrow-go/pull/302
### Rationale for this change When we create a reader with `BufferedStreamEnabled = false`, we have to first create a `data` slice. https://github.com/apache/arrow-go/blob/efecae3596e6734ce8244a5ed1befdcff09884df/parquet/reader_properties.go#L76-L91 And we will create another slice with same size in the `NewBufferedReader` again, which is redundant. https://github.com/apache/arrow-go/blob/efecae3596e6734ce8244a5ed1befdcff09884df/internal/utils/buf_reader.go#L45-L51 ### What changes are included in this PR? - Add a new struct `byteReader`, which is a wrapper of `bytes.NewReader` - Remove `BufferSize()` method from `BufferedReader` interface ### Are these changes tested? `BufferedReader` created from `bytes.NewReader` in tests are all replaced by new function `NewByteReader`. ### Are there any user-facing changes? No. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
