Example usage for org.springframework.boot.diagnostics FailureAnalysis getCause

List of usage examples for org.springframework.boot.diagnostics FailureAnalysis getCause

Introduction

In this page you can find the example usage for org.springframework.boot.diagnostics FailureAnalysis getCause.

Prototype

public Throwable getCause() 

Source Link

Document

Returns the cause of the failure.

Usage

From source file:org.springframework.boot.diagnostics.LoggingFailureAnalysisReporter.java

@Override
public void report(FailureAnalysis failureAnalysis) {
    if (logger.isDebugEnabled()) {
        logger.debug("Application failed to start due to an exception", failureAnalysis.getCause());
    }//from w  ww  . j a va  2 s.c  om
    if (logger.isErrorEnabled()) {
        logger.error(buildMessage(failureAnalysis));
    }
}