rev 测试值不健康问题

This commit is contained in:
USER-20220102CG\noblelift
2023-09-18 14:30:53 +08:00
parent 8dfe47bdfc
commit cb482ae626

View File

@@ -185,7 +185,7 @@ public class DeviceOpcProtocolRunable implements Runnable, DataCallback, ServerC
Object his = accessor_value.getValue(itemId);
if (itemState.getQuality()==QualityTypeValue.OPC_QUALITY_GOOD && his != null) {
log.warn("opc 值不健康 item: {}, 状态: {}", itemId, itemState.getQuality());
valueAllNotNull = true;
valueAllNotNull = false;
}
if (!UnifiedDataAppService.isEquals(value, his)) {
@@ -218,8 +218,8 @@ public class DeviceOpcProtocolRunable implements Runnable, DataCallback, ServerC
if (log.isWarnEnabled()) {
log.warn("{} 所有内容都为空, all_null:{} ,暂定{}s", tag, all_null,5000 + random);
}
ThreadUtl.sleep((long) (5000 + random));
ThreadUtl.sleep((long) ((new Random()).nextInt(3) +1) * 1000);
break start;
} else if (this.all_null < 6) {
if (log.isWarnEnabled()) {
log.warn(tag + "重新创建server");