assertNotNull(txChain);
/**
- * We alocate new read-write transaction and write /test.
+ * We allocate new read-write transaction and write /test.
*/
final DOMDataTreeWriteTransaction firstTx = allocateAndWrite(txChain);
final ListenableFuture<? extends CommitInfo> firstWriteTxFuture = firstTx.commit();
/**
- * We alocate chained transaction - read transaction.
+ * We allocate chained transaction - read transaction.
*/
final DOMDataTreeReadTransaction secondReadTx = txChain.newReadOnlyTransaction();
assertTestContainerExists(secondReadTx);
/**
- * We alocate next transaction, which is still based on first one, but
+ * We allocate next transaction, which is still based on first one, but
* is read-write.
*
*/
final DOMDataTreeReadTransaction storeReadTx = domBroker.newReadOnlyTransaction();
/**
- * We verify transaction is commited to store, container should exists
+ * We verify transaction is committed to store, container should exist
* in datastore.
*/
assertTestContainerExists(storeReadTx);
/**
- * third transaction is sealed and commited.
+ * third transaction is sealed and committed.
*/
assertCommitSuccessful(thirdDeleteTx.commit());
assertNotNull(txChain);
/**
- * We alocate new read-write transaction and write /test
+ * We allocate new read-write transaction and write /test
*/
allocateAndWrite(txChain);
/**
- * We alocate chained transaction - read transaction, note first one is
- * still not commited to datastore, so this allocation should fail with
+ * We allocate chained transaction - read transaction, note first one is
+ * still not committed to datastore, so this allocation should fail with
* IllegalStateException.
*/
try {
- txChain.newReadOnlyTransaction();
+ allocateAndWrite(txChain); // actual backing tx allocation happens on put
fail("Allocation of secondReadTx should fail with IllegalStateException");
} catch (final Exception e) {
assertTrue(e instanceof IllegalStateException);