code: public Object required(TransactionCallback callback) throws Throwable {
          final boolean began = begin();
          try {
              return callback.execute(this);
          } finally {
              if (began) {
                  end();
              }
          }
      }
docs: ==============