public class NonAlignedChunkGroupWriterImpl extends Object implements IChunkGroupWriter
| Constructor and Description |
|---|
NonAlignedChunkGroupWriterImpl(String deviceId) |
| Modifier and Type | Method and Description |
|---|---|
long |
flushToFileWriter(TsFileIOWriter fileWriter)
flushing method for serializing to local file system or HDFS.
|
long |
getCurrentChunkGroupSize()
get the serialized size of current chunkGroup header + all chunks.
|
Map<String,Long> |
getLastTimeMap() |
void |
setLastTimeMap(Map<String,Long> lastTimeMap) |
void |
tryToAddSeriesWriter(List<MeasurementSchema> schemas)
given a measurement descriptor list, create corresponding writers and put into this
ChunkGroupWriter.
|
void |
tryToAddSeriesWriter(MeasurementSchema schema)
given a measurement descriptor, create a corresponding writer and put into this
ChunkGroupWriter.
|
long |
updateMaxGroupMemSize()
get the max memory occupied at this time.
|
int |
write(long time,
List<DataPoint> data)
receive a timestamp and a list of data points, write them to their series writers.
|
int |
write(Tablet tablet)
receive a tablet, write it to chunk writers
|
public NonAlignedChunkGroupWriterImpl(String deviceId)
public void tryToAddSeriesWriter(MeasurementSchema schema)
IChunkGroupWritertryToAddSeriesWriter in interface IChunkGroupWriterschema - a measurement descriptor containing the message of the seriespublic void tryToAddSeriesWriter(List<MeasurementSchema> schemas)
IChunkGroupWritertryToAddSeriesWriter in interface IChunkGroupWriterpublic int write(long time,
List<DataPoint> data)
throws IOException,
WriteProcessException
IChunkGroupWriterwrite in interface IChunkGroupWritertime - - all data points have unify time stamp.data - - data point list to inputIOException - exception in IOWriteProcessException - exception in write processpublic int write(Tablet tablet) throws WriteProcessException
IChunkGroupWriterwrite in interface IChunkGroupWriterWriteProcessException - exception in write processpublic long flushToFileWriter(TsFileIOWriter fileWriter) throws IOException
IChunkGroupWriterflushToFileWriter in interface IChunkGroupWriterfileWriter - - TSFileIOWriterIOException - exception in IOpublic long updateMaxGroupMemSize()
IChunkGroupWriterlong calcAllocatedSize()updateMaxGroupMemSize in interface IChunkGroupWriterpublic long getCurrentChunkGroupSize()
IChunkGroupWritergetCurrentChunkGroupSize in interface IChunkGroupWriterCopyright © 2022 The Apache Software Foundation. All rights reserved.