diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/opc/DeviceOpcProtocolRunable.java b/acs/nladmin-system/src/main/java/org/nl/acs/opc/DeviceOpcProtocolRunable.java index fa52be5..576f32b 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/opc/DeviceOpcProtocolRunable.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/opc/DeviceOpcProtocolRunable.java @@ -185,8 +185,11 @@ public class DeviceOpcProtocolRunable implements Runnable { } } while (ObjectUtil.equal(value, his));//如果两次的值相等,不走下面的代码 + log.info("如果两次的值相等,不走下面的代码"); + OpcItemDto itemDto = this.getItem(item.getId()); - if (itemDto.getNeed_log() != null && itemDto.getNeed_log()) { +// if (itemDto.getNeed_log() != null && itemDto.getNeed_log()) { + if (true) { StringBuilder sb = new StringBuilder(); //设备的ITEM项 List relate_items = itemDto.getRelate_items(); @@ -203,14 +206,13 @@ public class DeviceOpcProtocolRunable implements Runnable { } //设置值 accessor_value.setValue(item.getId(), value); - } } - System.out.println("opc线程停止。。。"); + log.info("opc线程停止。。。"); return; } catch (Exception var30) { if (!DeviceOpcSynchronizeAutoRun.isRun) { - System.out.println("opc线程停止2。。。"); + log.info("opc线程停止2。。。"); if (server != null) { try { server.disconnect(); diff --git a/acs/nladmin-system/src/main/resources/logback-spring.xml b/acs/nladmin-system/src/main/resources/logback-spring.xml index 1781d46..920db85 100644 --- a/acs/nladmin-system/src/main/resources/logback-spring.xml +++ b/acs/nladmin-system/src/main/resources/logback-spring.xml @@ -183,6 +183,10 @@ https://juejin.cn/post/6844903775631572999 + + + +