修改超时时间

This commit is contained in:
孙小云 2026-02-11 10:56:08 +08:00
parent dc671f31ba
commit f3b6873293
2 changed files with 4 additions and 4 deletions

View File

@ -98,7 +98,7 @@ public class TuohengVendorConfig implements VendorConfig {
// 关机命令 // 关机命令
Transaction powerOffTransaction = new Transaction("关机", CommandType.POWER_OFF) Transaction powerOffTransaction = new Transaction("关机", CommandType.POWER_OFF)
.root(new com.ruoyi.device.domain.impl.machine.vendor.tuoheng.instruction.TuohengPowerOffInstruction()) .root(new com.ruoyi.device.domain.impl.machine.vendor.tuoheng.instruction.TuohengPowerOffInstruction())
.setTimeout(240000); .setTimeout(66000);
transactionMap.put(powerOffTransaction.getCommandType(), powerOffTransaction); transactionMap.put(powerOffTransaction.getCommandType(), powerOffTransaction);
log.info("拓恒厂家配置初始化完成,共配置{}个命令", transactionMap.size()); log.info("拓恒厂家配置初始化完成,共配置{}个命令", transactionMap.size());

View File

@ -46,7 +46,7 @@ public class TuohengPowerOffInstruction extends AbstractInstruction {
.topic("/topic/v1/airportNest/" + sn + "/control/confirm") .topic("/topic/v1/airportNest/" + sn + "/control/confirm")
.fieldPath("msg") .fieldPath("msg")
.expectedValue("[综管]无人机关机指令接收成功") .expectedValue("[综管]无人机关机指令接收成功")
.timeoutMs(60000) .timeoutMs(6000)
.build(); .build();
} }
@ -61,12 +61,12 @@ public class TuohengPowerOffInstruction extends AbstractInstruction {
.topic("/topic/v1/airportNest/" + sn + "/realTime/data") .topic("/topic/v1/airportNest/" + sn + "/realTime/data")
.fieldPath("droneBattery.data.bPowerON") .fieldPath("droneBattery.data.bPowerON")
.expectedValue("2") // 2表示已关机 .expectedValue("2") // 2表示已关机
.timeoutMs(180000) .timeoutMs(60000)
.build(); .build();
} }
@Override @Override
public long getTimeoutMs() { public long getTimeoutMs() {
return 240000; // 总超时时间60秒 return 66000; // 总超时时间60秒
} }
} }