public class SettlerTask extends RetryTask implements TransactionConstants
SettlerTask
is scheduled task, which
causes an unsettled transaction to settle.Modifier and Type | Field and Description |
---|---|
private int |
attempt |
private int |
maxtries |
private static Logger |
operationsLogger
Logger for operations related messages
|
private long |
tid |
private static Logger |
transactionsLogger
Logger for transactions related messages
|
private TransactionManager |
txnmgr |
ABORTED, ACTIVE, COMMITTED, NOTCHANGED, PREPARED, VOTING
DAYS, HOURS, MINUTES, SECONDS
Constructor and Description |
---|
SettlerTask(TaskManager manager,
WakeupManager wm,
TransactionManager txnmgr,
long tid)
Constructs a
SettlerTask . |
Modifier and Type | Method and Description |
---|---|
boolean |
runAfter(List list,
int max)
Inherit doc comment from supertype.
|
boolean |
tryOnce()
Make a single attempt.
|
private long tid
private int attempt
private int maxtries
private TransactionManager txnmgr
private static final Logger operationsLogger
private static final Logger transactionsLogger
public SettlerTask(TaskManager manager, WakeupManager wm, TransactionManager txnmgr, long tid)
SettlerTask
.manager
- TaskManager
providing the threads
of execution.txnmgr
- TransactionManager
which owns the
the transaction.tid
- transaction IDpublic boolean runAfter(List list, int max)
runAfter
in interface TaskManager.Task
list
- the tasks to consider. A read-only List, with all
elements instanceof Task.max
- elements with index less than size should be consideredRetryTask
Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.