Ends the transaction if nesting level is 0 (but will abort the transaction instead, even if nesting level is not 0, if an {@link IsisTransaction#getAbortCause() abort cause}has been {@link IsisTransaction#setAbortCause(IsisException) set}.
If in the process of committing the transaction an exception is thrown, then this will be handled and will abort the transaction instead.
If an abort cause has been set (or an exception occurs), then will throw this exception in turn.