user3291361
user3291361

Reputation: 111

Process finished with exit code 1 Spring Boot Intellij no other logs

I see no logs in my console /Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home/bin/java...

Process finished with exit code 1

Upvotes: 2

Views: 5354

Answers (2)

If you have an application.yml with bad syntax, you can obtain the error. Review your application.yml or put the code above to have more information about the exception.

Upvotes: 0

user3291361
user3291361

Reputation: 111

public static void main(String[] args) {
        try {
            SpringApplication app = new SpringApplication(YourClass.class);
            app.run(args);
        } catch(Throwable ex) {
            ex.printStackTrace();
        }
}

With this, I was able to see the full error in the logs. Hope this helps.

Upvotes: 9

Related Questions