2 * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.controller.md.sal.dom.broker.impl;
10 import java.util.EventListener;
12 import org.opendaylight.controller.md.sal.common.api.data.TransactionChainListener;
13 import org.opendaylight.controller.md.sal.dom.api.DOMDataWriteTransaction;
17 * Listener on transaction failure which may be passed to
18 * {@link DOMDataCommitExecutor}. This listener is notified during transaction
19 * processing, before result is delivered to other client code outside MD-SAL.
20 * This allows implementors to update their internal state before transaction
21 * failure is visible to client code.
23 * This is internal API for MD-SAL implementations, for consumer facing error
24 * listeners see {@link TransactionChainListener}.
27 interface DOMDataCommitErrorListener extends EventListener {
31 * Callback which is invoked on transaction failure during three phase
32 * commit in {@link DOMDataCommitExecutor}.
35 * Implementation of this callback MUST NOT do any blocking calls or any
36 * calls to MD-SAL, since this callback is invoked synchronously on MD-SAL
37 * Broker coordination thread.
40 * Transaction which failed
44 void onCommitFailed(DOMDataWriteTransaction tx, Throwable cause);