Search in sources :

Example 1 with SweepPriorityRow

use of com.palantir.atlasdb.schema.generated.SweepPriorityTable.SweepPriorityRow in project atlasdb by palantir.

the class SweepPriorityStoreImpl method update.

@Override
public void update(Transaction tx, TableReference tableRef, UpdateSweepPriority update) {
    SweepPriorityRow row = SweepPriorityRow.of(tableRef.getQualifiedName());
    SweepPriorityTable table = sweepTableFactory.getSweepPriorityTable(tx);
    update.newStaleValuesDeleted().ifPresent(n -> table.putCellsDeleted(row, n));
    update.newCellTsPairsExamined().ifPresent(n -> table.putCellsExamined(row, n));
    update.newLastSweepTimeMillis().ifPresent(t -> table.putLastSweepTime(row, t));
    update.newMinimumSweptTimestamp().ifPresent(t -> table.putMinimumSweptTimestamp(row, t));
    update.newWriteCount().ifPresent(c -> table.putWriteCount(row, c));
}
Also used : SweepPriorityTable(com.palantir.atlasdb.schema.generated.SweepPriorityTable) SweepPriorityRow(com.palantir.atlasdb.schema.generated.SweepPriorityTable.SweepPriorityRow)

Aggregations

SweepPriorityTable (com.palantir.atlasdb.schema.generated.SweepPriorityTable)1 SweepPriorityRow (com.palantir.atlasdb.schema.generated.SweepPriorityTable.SweepPriorityRow)1