You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
975 B
21 lines
975 B
package com.iflytop.gd;
|
|
|
|
import org.springframework.boot.SpringApplication;
|
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
|
import org.springframework.context.ConfigurableApplicationContext;
|
|
import org.springframework.core.env.ConfigurableEnvironment;
|
|
import org.springframework.scheduling.annotation.EnableScheduling;
|
|
|
|
@EnableScheduling
|
|
@SpringBootApplication
|
|
public class GraphiteDigesterServiceApplication {
|
|
|
|
public static void main(String[] args) {
|
|
ConfigurableApplicationContext ctx = SpringApplication.run(GraphiteDigesterServiceApplication.class, args);
|
|
ConfigurableEnvironment env = ctx.getEnvironment();
|
|
String port = env.getProperty("local.server.port", env.getProperty("server.port", "8080"));
|
|
System.out.println("应用已启动");
|
|
System.out.println("访问地址 → http://localhost:" + port + "/");
|
|
System.out.println("文档地址 → http://localhost:" + port + "/doc.html");
|
|
}
|
|
}
|