public static class SharedGrpcDataReader.Factory extends Object implements DataReader.Factory
SharedGrpcDataReader
s.Constructor and Description |
---|
Factory(FileSystemContext context,
WorkerNetAddress address,
ReadRequest readRequestPartial,
long blockSize)
Creates an instance of
SharedGrpcDataReader.Factory for block reads. |
Modifier and Type | Method and Description |
---|---|
void |
close() |
DataReader |
create(long offset,
long len)
Creates an instance of
DataReader . |
boolean |
isShortCircuit() |
public Factory(FileSystemContext context, WorkerNetAddress address, ReadRequest readRequestPartial, long blockSize)
SharedGrpcDataReader.Factory
for block reads.context
- the file system contextaddress
- the worker addressreadRequestPartial
- the partial read requestblockSize
- the block sizepublic DataReader create(long offset, long len) throws IOException
DataReader.Factory
DataReader
.create
in interface DataReader.Factory
offset
- the stream offsetlen
- the length of the streamIOException
public boolean isShortCircuit()
isShortCircuit
in interface DataReader.Factory
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2023. All Rights Reserved.