Example usage for org.springframework.boot.devtools.restart SilentExitExceptionHandler exitCurrentThread

List of usage examples for org.springframework.boot.devtools.restart SilentExitExceptionHandler exitCurrentThread

Introduction

In this page you can find the example usage for org.springframework.boot.devtools.restart SilentExitExceptionHandler exitCurrentThread.

Prototype

static void exitCurrentThread() 

Source Link

Usage

From source file:org.springframework.boot.devtools.restart.Restarter.java

private void immediateRestart() {
    try {//from w  w  w.ja v  a 2 s  .c  o  m
        getLeakSafeThread().callAndWait(new Callable<Void>() {

            @Override
            public Void call() throws Exception {
                start(FailureHandler.NONE);
                cleanupCaches();
                return null;
            }

        });
    } catch (Exception ex) {
        this.logger.warn("Unable to initialize restarter", ex);
    }
    SilentExitExceptionHandler.exitCurrentThread();
}