// the (outermost) write locks to prevent potential deadlocks.
// See https://issues.apache.org/jira/browse/JCR-2746
if (isOutermostWriteOperation) {
WorkspaceManager manager =
context.getRepositoryContext().getWorkspaceManager();
ObservationDispatcher dispatcher =
manager.getObservationDispatcher(context.getWorkspace().getName());
dispatcher.delayIfEventQueueOverloaded();
}
}
}