| | |
| | | @Configuration |
| | | @Profile("dev-simulator") |
| | | public class DevelopmentSimulatorConfig { |
| | | /** 按配置的监听端口装配开发模拟器;仅 dev-simulator 生效,容器关闭时释放其端口。 */ |
| | | @Bean(destroyMethod = "close") |
| | | @Profile("dev-simulator") |
| | | public BtsDevelopmentSimulator btsDevelopmentSimulator(BtsSimulatorStateStore stateStore, |
| | |
| | | return new BtsDevelopmentSimulator(simulatorPort, stateStore); |
| | | } |
| | | |
| | | /** |
| | | * 将固定开发适配器按代码装配注册进运行时实例表,不写 t_device_adapter。 |
| | | * |
| | | * <p>其运行时能力只有发现与实时观测,控制能力为不支持,不向设备发送控制命令。</p> |
| | | */ |
| | | @Bean |
| | | @Profile("dev-simulator") |
| | | public ApplicationRunner registerDevelopmentSimulatorAdapter(DeviceAdapterRegistry registry, |