I have a Gradle project where I try to start a Eureka Server. Here is my Setup:
dependencies {
implementation 'org.springframework.cloud:spring-cloud-starter-eureka-server:+'
// compileOnly('org.springframework.cloud:spring-cloud-starter-netflix-eureka-server:+')
}
In this way I try to start the Application :
@SpringBootApplication
@EnableEurekaServer
public class EurekaServer {
public static void main(String[] args) {
SpringApplication.run(EurekaServer.class, args);
}
}
But unfortunately some errors occurred:
***************************
APPLICATION FAILED TO START
***************************
Description:
An attempt was made to call a method that does not exist. The attempt was made from the following location:
org.springframework.cloud.bootstrap.BootstrapApplicationListener.bootstrapServiceContext(BootstrapApplicationListener.java:161)
The following method did not exist:
'void org.springframework.boot.builder.SpringApplicationBuilder.<init>(java.lang.Object[])'
Action:
Correct the classpath of your application so that it contains compatible versions of the classes org.springframework.cloud.bootstrap.BootstrapApplicationListener and org.springframework.boot.builder.SpringApplicationBuilder
Thanks