package com.fzzy.protocol; import com.fzzy.protocol.fzzy.server.FzzyServerEngine; import com.fzzy.protocol.weightyh.YhScaleServerEngine; import lombok.extern.slf4j.Slf4j; import org.springframework.boot.CommandLineRunner; import org.springframework.core.annotation.Order; import org.springframework.stereotype.Service; /** * 配置随系统启动默认配置 */ @Service @Slf4j @Order(value = 3) public class ProtocolRunner implements CommandLineRunner { @Override public void run(String... args) throws Exception { //耀华地磅TCP协议 YhScaleServerEngine.start(); //风正致远控制柜协议启动 FzzyServerEngine.start(null); } }