upgrade springboot-aop to spring boot 2

This commit is contained in:
Xiong Neng
2018-09-02 16:33:02 +08:00
parent 69a6a73663
commit c2192a14aa
7 changed files with 152 additions and 27 deletions

View File

@ -1,4 +1,4 @@
package com.xncoding.aop;
package com.xncoding;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

View File

@ -0,0 +1,26 @@
package com.xncoding.aop;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.CommandLineRunner;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;
/**
* MonitorBossAfterStart
*
* @author XiongNeng
* @version 1.0
* @since 2018/7/18
*/
@Component
@Order(1)
public class AfterStartRunner implements CommandLineRunner {
private Logger logger = LoggerFactory.getLogger(this.getClass());
public void run(String... args) {
logger.debug("after start debug...");
logger.info("after start info...");
}
}