src/server/pkg/storage/chunk/storage.go
func (s *Storage) NewReader(ctx context.Context, dataRefs []*DataRef) io.ReadCloser {
	if len(dataRefs) == 0 {
		return ioutil.NopCloser(&bytes.Buffer{})
	}
	return newReader(ctx, s.objC, s.prefix, dataRefs)
}
func (s *Storage) NewReader(ctx context.Context, dataRefs []*DataRef) io.ReadCloser {
	if len(dataRefs) == 0 {
		return ioutil.NopCloser(&bytes.Buffer{})
	}
	return newReader(ctx, s.objC, s.prefix, dataRefs)
}
func ( s * Storage ) NewReader ( ctx context . Context , dataRefs [ ] * DataRef ) io . ReadCloser { if len ( dataRefs ) == 0 { return ioutil . NopCloser ( & bytes . Buffer { } ) } return newReader ( ctx , s . objC , s . prefix , dataRefs ) }
// NewReader creates an io.ReadCloser for a chunk.
// (bryce) The whole chunk is in-memory right now. Could be a problem with
// concurrency, particularly the merge process.
// May want to handle concurrency here (pass in multiple data refs)
NewReader creates an io . ReadCloser for a chunk . ( bryce ) The whole chunk is in - memory right now . Could be a problem with concurrency particularly the merge process . May want to handle concurrency here ( pass in multiple data refs )