You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2014/09/26 18:00:14 UTC
git commit: ISIS-905: remove guard on flush that used to ensure that
the xactn was not in a state of MUST_ABORT... we want to render the
VoidReturnPage if a xactn has been aborted.
Repository: isis
Updated Branches:
refs/heads/master 5bf7917c7 -> 97fec9f45
ISIS-905: remove guard on flush that used to ensure that the xactn was not in a state of MUST_ABORT... we want to render the VoidReturnPage if a xactn has been aborted.
Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/97fec9f4
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/97fec9f4
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/97fec9f4
Branch: refs/heads/master
Commit: 97fec9f4540bcaba6c5117a884d6f9192dd3aa09
Parents: 5bf7917
Author: Jeroen van der Wal <je...@stromboli.it>
Authored: Fri Sep 26 13:21:11 2014 +0200
Committer: Jeroen van der Wal <je...@stromboli.it>
Committed: Fri Sep 26 13:21:11 2014 +0200
----------------------------------------------------------------------
.../runtime/system/transaction/IsisTransaction.java | 15 ++++++++-------
.../system/transaction/IsisTransactionManager.java | 4 ----
2 files changed, 8 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/isis/blob/97fec9f4/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransaction.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransaction.java b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransaction.java
index ecd3dbd..628045e 100644
--- a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransaction.java
+++ b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransaction.java
@@ -426,13 +426,14 @@ public class IsisTransaction implements TransactionScopedComponent {
// ////////////////////////////////////////////////////////////////
public synchronized final void flush() {
- // have removed the guard below because not every objectstore necessarily
- // wraps up every change inside a command.
-
- // for example, the JDO object store just lets DataNucleus do the change tracking
- // itself
-
- ensureThatState(getState().canFlush(), is(true), "state is: " + getState());
+
+ // have removed THIS guard because we hit a situation where a xactn is aborted
+ // from a no-arg action, the Wicket viewer attempts to render a new page that (of course)
+ // contains the service menu items, and some of the 'disableXxx()' methods of those
+ // service actions perform repository queries (while xactn is still in a state of ABORTED)
+ //
+ // ensureThatState(getState().canFlush(), is(true), "state is: " + getState());
+ //
if (LOG.isDebugEnabled()) {
LOG.debug("flush transaction " + this);
}
http://git-wip-us.apache.org/repos/asf/isis/blob/97fec9f4/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransactionManager.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransactionManager.java b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransactionManager.java
index 1722e52..e39337c 100644
--- a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransactionManager.java
+++ b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/transaction/IsisTransactionManager.java
@@ -372,10 +372,6 @@ public class IsisTransactionManager implements SessionScopedComponent {
LOG.debug("flushTransaction");
}
- if(getTransaction().getState().mustAbort()) {
- throw getTransaction().getAbortCause();
- }
-
if (getTransaction() != null) {
persistenceSession.objectChangedAllDirty();
getTransaction().flush();