Netconf stack by default locks the data store before issuing
[netconf.git] / netconf / sal-netconf-connector / src / main / java / org / opendaylight / netconf / sal / connect / netconf / sal / tx / AbstractWriteTx.java
index fa94ad0b45bbbdc30809b08f0ffe4101f00bbdfb..51c73147020b508d8582be8569aaf09bd078bf05 100644 (file)
@@ -52,11 +52,14 @@ public abstract class AbstractWriteTx implements DOMDataTreeWriteTransaction {
     private final List<TxListener> listeners = new CopyOnWriteArrayList<>();
     // Allow commit to be called only once
     protected volatile boolean finished = false;
+    protected final boolean isLockAllowed;
 
-    public AbstractWriteTx(final NetconfBaseOps netOps, final RemoteDeviceId id, final boolean rollbackSupport) {
-        this.netOps = netOps;
+    public AbstractWriteTx(final RemoteDeviceId id, final NetconfBaseOps netconfOps, final boolean rollbackSupport,
+            final boolean isLockAllowed) {
+        this.netOps = netconfOps;
         this.id = id;
         this.rollbackSupport = rollbackSupport;
+        this.isLockAllowed = isLockAllowed;
         init();
     }