public final class AutoFlushWriter extends Writer
Writer.PushMode, Writer.TableColumn
columns, pointsSinceFlush
Modifier | Constructor and Description |
---|---|
protected |
AutoFlushWriter(Session session,
Table[] tables)
Initialize a new auto-flushing timeseries table with a default threshold of 50000 rows.
|
protected |
AutoFlushWriter(Session session,
Table[] tables,
long threshold)
Initialize a new auto-flushing timeseries table.
|
protected |
AutoFlushWriter(Session session,
Table[] tables,
long threshold,
Writer.PushMode pushMode)
Initialize a new auto-flushing timeseries table.
|
protected |
AutoFlushWriter(Session session,
Table[] tables,
Writer.PushMode pushMode)
Initialize a new auto-flushing timeseries table with a default threshold of 50000 rows.
|
Modifier and Type | Method and Description |
---|---|
void |
append(Integer offset,
Timespec timestamp,
Value[] values)
Append a new row to the local table cache.
|
protected AutoFlushWriter(Session session, Table[] tables)
session
- Active connection with the QdbClustertables
- Timeseries tables we're writing to.protected AutoFlushWriter(Session session, Table[] tables, Writer.PushMode pushMode)
session
- Active connection with the QdbClustertables
- Timeseries tables we're writing to.pushMode
- Determines which method of operation to use for flushingprotected AutoFlushWriter(Session session, Table[] tables, long threshold)
session
- Active connection with the QdbClustertables
- Timeseries tables we're writing to.threshold
- The amount of rows to keep in local buffer before automatic flushing occurs.protected AutoFlushWriter(Session session, Table[] tables, long threshold, Writer.PushMode pushMode)
session
- Active connection with the QdbClustertables
- Timeseries tables we're writing to.threshold
- The amount of rows to keep in local buffer before automatic flushing occurs.pushMode
- Determines which method of operation to use for flushingpublic void append(Integer offset, Timespec timestamp, Value[] values) throws IOException
Writer
AutoFlushWriter
is used.append
in class Writer
offset
- Relative offset of the table inside the batch. Use #tableIndexByName
to determine the appropriate value.timestamp
- Timestamp of the rowvalues
- Values being inserted, mapped to columns by their relative offset.IOException
Writer.tableIndexByName(java.lang.String)
,
Writer.flush()
,
Table.autoFlushWriter(net.quasardb.qdb.Session, java.lang.String)
Copyright © 2021. All rights reserved.