From: Moiz Raja Date: Thu, 21 May 2015 18:20:55 +0000 (-0700) Subject: Use TransactionCommitOperationTimeout when commiting a Local transaction X-Git-Tag: release/lithium~132 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=commitdiff_plain;h=3ca4e8353a32a68ebf71e98fed1954af5c419ca3;hp=cd0eea4a97a6279b801074061dd64f6663e8b837 Use TransactionCommitOperationTimeout when commiting a Local transaction This is to make this similar to how we do a remote transaction. The transaction commit timeout is much larger than the operation timeout and is more appropriate for committing because the latencies involved in committing are much larger as committing involves replication which could sometimes be pretty slow. Change-Id: Ie76e05bf875b4ea5eee9618519d7167f50671c8f Signed-off-by: Moiz Raja --- diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalThreePhaseCommitCohort.java b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalThreePhaseCommitCohort.java index 0ea1029a9d..267513fc2f 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalThreePhaseCommitCohort.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalThreePhaseCommitCohort.java @@ -48,7 +48,7 @@ abstract class LocalThreePhaseCommitCohort implements DOMStoreThreePhaseCommitCo private Future initiateCommit(final boolean immediate) { final ReadyLocalTransaction message = new ReadyLocalTransaction(transaction.getIdentifier().toString(), modification, immediate); - return actorContext.executeOperationAsync(leader, message); + return actorContext.executeOperationAsync(leader, message, actorContext.getTransactionCommitOperationTimeout()); } Future initiateCoordinatedCommit() {