// exceptions (versioning, locking, ...)
Behavior behavior = getJcrSession().getBehavior();
if (behavior != null) {
behavior.handleException(e);
} else {
if (e instanceof RepositoryException) {
throw new JcrException((RepositoryException) e);
} else {
throw new RuntimeException(e);