package com.mortals.xhx.daemon.applicationservice;

import com.mortals.framework.springcloud.service.IApplicationService;
import com.mortals.xhx.common.utils.SendTaskThreadPool;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;


@Component
@Slf4j
public class DemoStartService implements IApplicationService {
    @Autowired
    private SendTaskThreadPool sendTaskThreadPool;

    @Override
    public void start() {
//        int coreThreadNum = Runtime.getRuntime().availableProcessors();
//        sendTaskThreadPool.init(coreThreadNum*2);
        log.info("开始服务..[配置已加载完成，但部分框架还未初始化，比如：Kafka]");
    }

    @Override
    public void stop() {
        log.info("停止服务..");
    }

}
