Package io.sbk.api
Interface DataRecordsWriter<T>
- All Superinterfaces:
DataWriter<T>
- All Known Subinterfaces:
Writer<T>
Interface for Data Records Writers.
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
RecordsWriter
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time) Default implementation for writer benchmarking by writing given number of records.default void
RecordsWriter
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, WriteRequestsLogger logger) Default implementation for writer benchmarking by writing given number of records.default void
RecordsWriterRO
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writing given number of records.default void
RecordsWriterRO
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writing given number of records.default void
RecordsWriterRW
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writing given number of records.default void
RecordsWriterRW
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writing given number of records.default void
RecordsWriterSync
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writer benchmarking by writing given number of records.default void
RecordsWriterSync
(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writer benchmarking by writing given number of records.default void
RecordsWriterTime
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time) Default implementation for writer benchmarking by continuously writing data records for specific time duration.default void
RecordsWriterTime
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, WriteRequestsLogger logger) Default implementation for writer benchmarking by continuously writing data records for specific time duration.default void
RecordsWriterTimeRO
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writing data records for specific time duration.default void
RecordsWriterTimeRO
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writing data records for specific time duration.default void
RecordsWriterTimeRW
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writing data records for specific time duration.default void
RecordsWriterTimeRW
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writing data records for specific time duration.default void
RecordsWriterTimeSync
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) Default implementation for writer benchmarking by continuously writing data records for specific time duration.default void
RecordsWriterTimeSync
(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) Default implementation for writer benchmarking by continuously writing data records for specific time duration.void
recordWrite
(DataType<T> dType, T data, int size, io.time.Time time, Status status, io.perl.api.PerlChannel perlChannel) Write the data and record the benchmark statistics.void
recordWrite
(DataType<T> dType, T data, int size, io.time.Time time, Status status, io.perl.api.PerlChannel perlChannel, int id, WriteRequestsLogger logger) Write the data and record the benchmark statistics.void
sync()
Flush / Sync the data.Write the Data and attach the start time to data.write
(DataType<T> dType, T data, int size, io.time.Time time, Status status, int id, WriteRequestsLogger logger) Write the Data and attach the start time to data.void
writeSetTime
(DataType<T> dType, T data, int size, io.time.Time time, Status status) Write the Data and attach the start time to data.void
writeSetTime
(DataType<T> dType, T data, int size, io.time.Time time, Status status, int id, WriteRequestsLogger logger) Write the Data and attach the start time to data.Methods inherited from interface io.sbk.api.DataWriter
close
-
Method Details
-
write
CompletableFuture<?> write(DataType<T> dType, T data, int size, io.time.Time time, Status status) throws IOException Write the Data and attach the start time to data.- Parameters:
dType
- Data Type interfacedata
- data to writersize
- size of the datatime
- time interfacestatus
- write status to return;Status
- Returns:
- CompletableFuture completable future. null if write completed synchronously .
- Throws:
IOException
- If an exception occurred.
-
write
CompletableFuture<?> write(DataType<T> dType, T data, int size, io.time.Time time, Status status, int id, WriteRequestsLogger logger) throws IOException Write the Data and attach the start time to data.- Parameters:
dType
- Data Type interfacedata
- data to writersize
- size of the datatime
- time interfacestatus
- write status to return;Status
id
- Writer idlogger
- Writer requests logger- Returns:
- CompletableFuture completable future. null if write completed synchronously .
- Throws:
IOException
- If an exception occurred.
-
writeSetTime
void writeSetTime(DataType<T> dType, T data, int size, io.time.Time time, Status status) throws IOException Write the Data and attach the start time to data.- Parameters:
dType
- Data Type interfacedata
- data to writersize
- size of the datatime
- time interfacestatus
- write status to return;Status
- Throws:
IOException
- If an exception occurred.
-
writeSetTime
void writeSetTime(DataType<T> dType, T data, int size, io.time.Time time, Status status, int id, WriteRequestsLogger logger) throws IOException Write the Data and attach the start time to data.- Parameters:
dType
- Data Type interfacedata
- data to writersize
- size of the datatime
- time interfacestatus
- write status to return;Status
id
- Writer idlogger
- Write requests logger- Throws:
IOException
- If an exception occurred.
-
sync
Flush / Sync the data.- Throws:
IOException
- If an exception occurred.
-
recordWrite
void recordWrite(DataType<T> dType, T data, int size, io.time.Time time, Status status, io.perl.api.PerlChannel perlChannel) throws IOException Write the data and record the benchmark statistics.- Parameters:
dType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacestatus
- Write status to return;Status
perlChannel
- to call for benchmarking- Throws:
IOException
- If an exception occurred.
-
recordWrite
void recordWrite(DataType<T> dType, T data, int size, io.time.Time time, Status status, io.perl.api.PerlChannel perlChannel, int id, WriteRequestsLogger logger) throws IOException Write the data and record the benchmark statistics.- Parameters:
dType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacestatus
- Write status to return;Status
perlChannel
- to call for benchmarkinglogger
- log write requestsid
- Writer id- Throws:
IOException
- If an exception occurred.
-
RecordsWriter
default void RecordsWriter(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time) throws IOException Default implementation for writer benchmarking by writing given number of records. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing all the records.- Specified by:
RecordsWriter
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interface- Throws:
IOException
- If an exception occurred.
-
RecordsWriter
default void RecordsWriter(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, WriteRequestsLogger logger) throws IOException Default implementation for writer benchmarking by writing given number of records. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing all the records.- Specified by:
RecordsWriter
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacelogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterSync
default void RecordsWriterSync(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writer benchmarking by writing given number of records. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing given set of records.- Specified by:
RecordsWriterSync
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterSync
default void RecordsWriterSync(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writer benchmarking by writing given number of records. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing given set of records.- Specified by:
RecordsWriterSync
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTime
default void RecordsWriterTime(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time) throws IOException Default implementation for writer benchmarking by continuously writing data records for specific time duration. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing records for given time.- Specified by:
RecordsWriterTime
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interface- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTime
default void RecordsWriterTime(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, WriteRequestsLogger logger) throws IOException Default implementation for writer benchmarking by continuously writing data records for specific time duration. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing records for given time.- Specified by:
RecordsWriterTime
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacelogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeSync
default void RecordsWriterTimeSync(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writer benchmarking by continuously writing data records for specific time duration. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeSync
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeSync
default void RecordsWriterTimeSync(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writer benchmarking by continuously writing data records for specific time duration. Write is performed usingrecordWrite(DataType, Object, int, Time, Status, PerlChannel)
sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeSync
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterRW
default void RecordsWriterRW(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writing given number of records. No Writer Benchmarking is performed. Write is performed usingwriteSetTime(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterRW
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterRW
default void RecordsWriterRW(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writing given number of records. No Writer Benchmarking is performed. Write is performed usingwriteSetTime(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterRW
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeRW
default void RecordsWriterTimeRW(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writing data records for specific time duration. No Writer Benchmarking is performed. Write is performed usingwriteSetTime(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeRW
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeRW
default void RecordsWriterTimeRW(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writing data records for specific time duration. No Writer Benchmarking is performed. Write is performed usingwriteSetTime(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeRW
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterRO
default void RecordsWriterRO(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writing given number of records. No Writer Benchmarking is performed. Write is performed usingwrite(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterRO
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterRO
default void RecordsWriterRO(Worker writer, long recordsCount, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writing given number of records. No Writer Benchmarking is performed. Write is performed usingwrite(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterRO
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorrecordsCount
- Records CountdType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeRO
default void RecordsWriterTimeRO(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController) throws IOException Default implementation for writing data records for specific time duration. No Writer Benchmarking is performed. Write is performed usingwrite(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeRO
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controller- Throws:
IOException
- If an exception occurred.
-
RecordsWriterTimeRO
default void RecordsWriterTimeRO(Worker writer, long secondsToRun, DataType<T> dType, T data, int size, io.time.Time time, RateController rController, WriteRequestsLogger logger) throws IOException Default implementation for writing data records for specific time duration. No Writer Benchmarking is performed. Write is performed usingwrite(DataType, Object, int, Time, Status)
. sync is invoked after writing given set of records.- Specified by:
RecordsWriterTimeRO
in interfaceDataWriter<T>
- Parameters:
writer
- Writer DescriptorsecondsToRun
- Number of seconds to RundType
- Data Type interfacedata
- data to writesize
- size of the datatime
- time interfacerController
- Rate Controllerlogger
- log write requests- Throws:
IOException
- If an exception occurred.
-