package pl.java.scalatech;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.system.ApplicationPidFileWriter;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;

import de.codecentric.boot.admin.config.EnableAdminServer;

@SpringBootApplication
@EnableDiscoveryClient
@EnableAdminServer
public class AdminDashboardApplication {

	public static void main(String[] args) {
	  springPIDAppRun(args,AdminDashboardApplication.class);
	}
	private static void springPIDAppRun(String[] args,Class<?> clazz) {
        SpringApplication springApplication = new SpringApplication(clazz);
        springApplication.addListeners(new ApplicationPidFileWriter());
        springApplication.run(args);
    }
}

@@ -21,16 +21,55 @@
 atech;%0A%0A
+import java.util.concurrent.TimeUnit;%0A%0A
 import o
@@ -322,537 +322,1673 @@
 nt;%0A
-%0Aimport de.codecentric.boot.admin.config.EnableAdminServer;%0A%0A@SpringBootApplication%0A@EnableDiscoveryClient%0A@EnableAdminServer%0Apublic class AdminDashboardApplication %7B%0A%0A%09public static void main(String%5B%5D args) %7B%0A%09  springPIDAppRun(args,AdminDashboardApplication.class);%0A%09%7D%0A%09private static void springPIDAppRun(String%5B%5D args,Class%3C?%3E clazz) %7B%0A        SpringApplication springApplication = new SpringApplication(clazz);%0A        springApplication.addListeners(new ApplicationPidFileWriter());%0A        springApplication.run(args);%0A    
+import org.springframework.context.annotation.Bean;%0Aimport org.springframework.context.annotation.Configuration;%0Aimport org.springframework.context.annotation.Primary;%0Aimport org.springframework.scheduling.annotation.Scheduled;%0A%0Aimport de.codecentric.boot.admin.config.EnableAdminServer;%0Aimport de.codecentric.boot.admin.notify.LoggingNotifier;%0Aimport de.codecentric.boot.admin.notify.Notifier;%0Aimport de.codecentric.boot.admin.notify.RemindingNotifier;%0Aimport de.codecentric.boot.admin.notify.filter.FilteringNotifier;%0A%0A@SpringBootApplication%0A@EnableDiscoveryClient%0A@EnableAdminServer%0Apublic class AdminDashboardApplication %7B%0A%0A%09public static void main(String%5B%5D args) %7B%0A%09  springPIDAppRun(args,AdminDashboardApplication.class);%0A%09%7D%0A%09private static void springPIDAppRun(String%5B%5D args,Class%3C?%3E clazz) %7B%0A        SpringApplication springApplication = new SpringApplication(clazz);%0A        springApplication.addListeners(new ApplicationPidFileWriter());%0A        springApplication.run(args);%0A    %7D%0A%09@Configuration%0A    public static class NotifierConfig %7B%0A    @Bean%0A    @Primary%0A    public RemindingNotifier remindingNotifier() %7B%0A        RemindingNotifier notifier = new RemindingNotifier(filteringNotifier(loggerNotifier()));%0A        notifier.setReminderPeriod(TimeUnit.SECONDS.toMillis(10));%0A        return notifier;%0A    %7D%0A%0A    @Scheduled(fixedRate = 1_000L)%0A    public void remind() %7B%0A        remindingNotifier().sendReminders();%0A    %7D%0A%0A    @Bean%0A    public FilteringNotifier filteringNotifier(Notifier delegate) %7B%0A        return new FilteringNotifier(delegate);%0A    %7D%0A%0A    @Bean%0A    public LoggingNotifier loggerNotifier() %7B%0A        return new LoggingNotifier();%0A    %7D%0A
 %7D%0A%7D%0A

Update AdminDashboardApplication.java