package cn.reghao.tnb.file.app.config;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.DisposableBean;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

/**
 * @author reghao
 * @date 2022-03-23 09:22:01
 */
@Slf4j
@Component
public class SpringLifecycle implements ApplicationRunner, DisposableBean {
    public SpringLifecycle() {
    }

    @Override
    public void run(ApplicationArguments args) throws Exception {
        log.info("FileService 启动...");
    }

    @Override
    public void destroy() {
        log.info("FileService 停止...");
    }
}
