Class AbstractReadResponse
- java.lang.Object
-
- com.linkedin.venice.listener.response.AbstractReadResponse
-
- All Implemented Interfaces:
ReadResponse
- Direct Known Subclasses:
MultiKeyResponseWrapper
,ParallelMultiKeyResponseWrapper
,SingleGetResponseWrapper
public abstract class AbstractReadResponse extends java.lang.Object implements ReadResponse
This class is used to store common fields shared by various read responses.
-
-
Constructor Summary
Constructors Constructor Description AbstractReadResponse()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description CompressionStrategy
getCompressionStrategy()
int
getRCU()
Get the read compute unit (RCU) for this response's requestabstract io.netty.buffer.ByteBuf
getResponseBody()
abstract int
getResponseSchemaIdHeader()
abstract ReadResponseStatsRecorder
getStatsRecorder()
boolean
isFound()
boolean
isStreamingResponse()
void
setCompressionStrategy(CompressionStrategy compressionStrategy)
void
setRCU(int rcu)
Set the read compute unit (RCU) cost for this response's requestvoid
setStreamingResponse()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.linkedin.davinci.listener.response.ReadResponse
getStats
-
-
-
-
Method Detail
-
setCompressionStrategy
public void setCompressionStrategy(CompressionStrategy compressionStrategy)
- Specified by:
setCompressionStrategy
in interfaceReadResponse
-
setStreamingResponse
public void setStreamingResponse()
- Specified by:
setStreamingResponse
in interfaceReadResponse
-
isStreamingResponse
public boolean isStreamingResponse()
- Specified by:
isStreamingResponse
in interfaceReadResponse
-
getCompressionStrategy
public CompressionStrategy getCompressionStrategy()
- Specified by:
getCompressionStrategy
in interfaceReadResponse
-
setRCU
public void setRCU(int rcu)
Set the read compute unit (RCU) cost for this response's request- Specified by:
setRCU
in interfaceReadResponse
- Parameters:
rcu
-
-
getRCU
public int getRCU()
Get the read compute unit (RCU) for this response's request- Specified by:
getRCU
in interfaceReadResponse
- Returns:
-
isFound
public boolean isFound()
- Specified by:
isFound
in interfaceReadResponse
-
getResponseBody
public abstract io.netty.buffer.ByteBuf getResponseBody()
- Specified by:
getResponseBody
in interfaceReadResponse
-
getResponseSchemaIdHeader
public abstract int getResponseSchemaIdHeader()
- Specified by:
getResponseSchemaIdHeader
in interfaceReadResponse
-
getStatsRecorder
public abstract ReadResponseStatsRecorder getStatsRecorder()
-
-