@Override protected void revertUpdateToRuntime(final OperationContext context, final ModelNode operation, final String attributeName, final ModelNode valueToRestore, final ModelNode valueToRevert, final Void handback) throws OperationFailedException { TxControl.setDefaultTimeout(valueToRestore.asInt()); ContextTransactionManager.setGlobalDefaultTransactionTimeout(valueToRestore.asInt()); } }
switch (stat) { case NUMBER_OF_TRANSACTIONS: result.set(txStats.getNumberOfTransactions()); break; case NUMBER_OF_NESTED_TRANSACTIONS: result.set(txStats.getNumberOfNestedTransactions()); break; case NUMBER_OF_HEURISTICS: result.set(txStats.getNumberOfHeuristics()); break; case NUMBER_OF_COMMITTED_TRANSACTIONS: result.set(txStats.getNumberOfCommittedTransactions()); break; case NUMBER_OF_ABORTED_TRANSACTIONS: result.set(txStats.getNumberOfAbortedTransactions()); break; case NUMBER_OF_INFLIGHT_TRANSACTIONS: result.set(txStats.getNumberOfInflightTransactions()); break; case NUMBER_OF_TIMED_OUT_TRANSACTIONS: result.set(txStats.getNumberOfTimedOutTransactions()); break; case NUMBER_OF_APPLICATION_ROLLBACKS: result.set(txStats.getNumberOfApplicationRollbacks()); break; case NUMBER_OF_RESOURCE_ROLLBACKS: result.set(txStats.getNumberOfResourceRollbacks()); break; case NUMBER_OF_SYSTEM_ROLLBACKS:
@Override protected boolean applyUpdateToRuntime(final OperationContext context, final ModelNode operation, final String attributeName, final ModelNode resolvedValue, final ModelNode currentValue, final HandbackHolder<Void> handbackHolder) throws OperationFailedException { int maximum_timeout = resolvedValue.asInt(); if (TxControl.getDefaultTimeout() == 0) { TransactionLogger.ROOT_LOGGER.timeoutValueIsSetToMaximum(maximum_timeout); ContextTransactionManager.setGlobalDefaultTransactionTimeout(maximum_timeout); } return false; }
public int cancel () { if (TxStats.enabled()) TxStats.getInstance().incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }
public int cancel () { int outcome = super.cancel(); /* * Now remove this thread from the reaper. Leave * the thread-to-tx association though. */ TransactionReaper.transactionReaper().remove(this); return outcome; }
public int cancel () { if (TxControl.enableStatistics) TxStats.incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }
public int end (boolean report_heuristics) { int outcome = super.end(report_heuristics); /* * Now remove this thread from the reaper. Leave * the thread-to-tx association though. */ TransactionReaper.transactionReaper().remove(this); return outcome; }
private void addDeferredThrowables(AbstractRecord record, List<Throwable> throwables) { if (record instanceof ExceptionDeferrer) ((ExceptionDeferrer) record).getDeferredThrowables(throwables); else if (record.value() instanceof ExceptionDeferrer) ((ExceptionDeferrer) record.value()).getDeferredThrowables(throwables); }
public ActionResult DoSomething(string parameter) { //do something with parameter bool result = true; return Json(new ActionInfo() { Success =result, }); }
public int cancel () { if (TxStats.enabled()) TxStats.getInstance().incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }
public int cancel () { int outcome = super.cancel(); /* * Now remove this thread from the reaper. Leave * the thread-to-tx association though. */ TransactionReaper.transactionReaper().remove(this); return outcome; }
@Override protected boolean applyUpdateToRuntime(final OperationContext context, final ModelNode operation, final String attributeName, final ModelNode resolvedValue, final ModelNode currentValue, final HandbackHolder<Void> handbackHolder) throws OperationFailedException { int timeout = resolvedValue.asInt(); TxControl.setDefaultTimeout(timeout); if (timeout == 0) { ModelNode model = context.readResource(PathAddress.EMPTY_ADDRESS).getModel(); timeout = MAXIMUM_TIMEOUT.resolveModelAttribute(context, model).asInt(); TransactionLogger.ROOT_LOGGER.timeoutValueIsSetToMaximum(timeout); } ContextTransactionManager.setGlobalDefaultTransactionTimeout(timeout); return false; }
public int cancel () { if (TxStats.enabled()) TxStats.getInstance().incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }
public int cancel () { int outcome = super.cancel(); /* * Now remove this thread from the reaper. Leave * the thread-to-tx association though. */ TransactionReaper.transactionReaper().remove(this); return outcome; }
public int cancel () { if (TxStats.enabled()) TxStats.getInstance().incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }
public int cancel () { if (TxStats.enabled()) TxStats.getInstance().incrementApplicationRollbacks(); if (parent() != null) parent().removeChildAction(this); // beforeCompletion(); int outcome = super.Abort(); afterCompletion(outcome); return outcome; }