I have a Spring boot application(Gradle) with main class as:
@EnableEurekaClient
public class UserServiceApplication extends WebMvcConfigurer{
What this annotation does is enable this application as Discovery Service client(Eureka in this case) but I don't want this to be enabled in local environment as I don't want to set registry for my local environment. So the question is, how can I make sure this annotation is used only in non-local environments?