public interface DataBrokerFailures
Modifier and Type | Method and Description |
---|---|
void |
failButCommitAnyway()
To simulate scenarios where even though the transaction throws a
TransactionCommitFailedException (caused by
akka.pattern.AskTimeoutException) it eventually succeeds.
|
void |
failCommits(int howManyTimes,
TransactionCommitFailedException exception)
Fails N future Transaction commits.
|
void |
failCommits(TransactionCommitFailedException exception)
Fails all future Transaction commits.
|
void |
failReads(int howManyTimes,
ReadFailedException exception)
Fails N future reads.
|
void |
failReads(ReadFailedException exception)
Fails all future reads.
|
void |
unfailCommits()
Resets any earlier
failCommits(TransactionCommitFailedException) or
failCommits(int, TransactionCommitFailedException) . |
void |
unfailReads()
Resets any earlier
failReads(ReadFailedException) or failReads(int, ReadFailedException) . |
void failReads(ReadFailedException exception)
exception
- a ReadFailedException
to throw from a
ReadOperations.read(LogicalDatastoreType, InstanceIdentifier)
call.void failReads(int howManyTimes, ReadFailedException exception)
howManyTimes
- how many times to throw the passed exception, until it resets.exception
- a ReadFailedException
to throw from a
ReadOperations.read(LogicalDatastoreType, InstanceIdentifier)
call.void failCommits(TransactionCommitFailedException exception)
exception
- an Exception to throw from a WriteTransaction.commit()
method.void failCommits(int howManyTimes, TransactionCommitFailedException exception)
howManyTimes
- how many times to throw the passed exception, until it resetsexception
- an Exception to throw from a WriteTransaction.commit()
method.void failButCommitAnyway()
void unfailReads()
failReads(ReadFailedException)
or failReads(int, ReadFailedException)
.void unfailCommits()
failCommits(TransactionCommitFailedException)
or
failCommits(int, TransactionCommitFailedException)
.Copyright © 2019 OpenDaylight. All rights reserved.