diff --git a/dspace-api/src/main/java/org/dspace/core/Context.java b/dspace-api/src/main/java/org/dspace/core/Context.java index 9ba80ead6a4a..5437b0fbc0b2 100644 --- a/dspace-api/src/main/java/org/dspace/core/Context.java +++ b/dspace-api/src/main/java/org/dspace/core/Context.java @@ -181,6 +181,11 @@ protected void init() { if (dbConnection == null) { log.fatal("Cannot obtain the bean which provides a database connection. " + "Check previous entries in the dspace.log to find why the db failed to initialize."); + } else { + if (isTransactionAlive()) { + log.debug("Initializing a context while an active transaction exists. Context with hash: {}.", + getHash()); + } } }