Reduced warn log entry without stacktrace for startup exceptions

Issue: SPR-13663
This commit is contained in:
Juergen Hoeller 2015-11-10 23:45:45 +01:00
parent 5d9d88c44d
commit cdf6eb95ab
1 changed files with 4 additions and 1 deletions

View File

@ -541,7 +541,10 @@ public abstract class AbstractApplicationContext extends DefaultResourceLoader
} }
catch (BeansException ex) { catch (BeansException ex) {
logger.warn("Exception encountered during context initialization - cancelling refresh attempt", ex); if (logger.isWarnEnabled()) {
logger.warn("Exception encountered during context initialization - " +
"cancelling refresh attempt: " + ex);
}
// Destroy already created singletons to avoid dangling resources. // Destroy already created singletons to avoid dangling resources.
destroyBeans(); destroyBeans();