JordanFromChina opened a new issue, #2394:
URL: https://github.com/apache/plc4x/issues/2394
### What happened?
// connected a S1500 PLC and cache it
// create PlcReadRequest instance and cache it
//get PlcReadRequest from cache
//a loop call program below
```
PlcReadRequest readRequest = cachedRequest.get(...);
PlcReadResponse response = readRequest.execute()
.get(OpcConfig.synchronized_millisecond * 30, TimeUnit.MILLISECONDS);
Thread.sleep(100);
PlcResponseCode code;
Object value;
for (String fieldName : response.getTagNames()) {
try {
code = response.getResponseCode(fieldName);
if (code == PlcResponseCode.OK) {
....
} else {
log.error("field: {} responseCode: {}", fieldName, code);
}
}
catch (InterruptedException e) {
throw e;
}
catch (Exception e) {
String msg = e.getMessage();
log.error(fieldName , e);
}
```
the logback file logged errors below sometimes
[plc4x-tm-thread-1] i.n.c.e.EmbeddedChannel - More than one exception was
raised. Will report only the first one and log others.
java.lang.NullPointerException: Cannot invoke
"io.netty.channel.ChannelPromise.setUncancellable()" because "entry.promise" is
null
at
io.netty.channel.ChannelOutboundBuffer.addFlush(ChannelOutboundBuffer.java:150)
at
io.netty.channel.AbstractChannel$AbstractUnsafe.flush(AbstractChannel.java:894)
at
io.netty.channel.embedded.EmbeddedChannel$EmbeddedUnsafe$1.flush(EmbeddedChannel.java:894)
at
io.netty.channel.DefaultChannelPipeline$HeadContext.flush(DefaultChannelPipeline.java:1372)
at
io.netty.channel.AbstractChannelHandlerContext.invokeFlush0(AbstractChannelHandlerContext.java:921)
at
io.netty.channel.AbstractChannelHandlerContext.invokeFlush(AbstractChannelHandlerContext.java:907)
at
io.netty.channel.AbstractChannelHandlerContext.flush(AbstractChannelHandlerContext.java:893)
at
io.netty.channel.ChannelDuplexHandler.flush(ChannelDuplexHandler.java:127)
at
io.netty.channel.AbstractChannelHandlerContext.invokeFlush0(AbstractChannelHandlerContext.java:923)
at
io.netty.channel.AbstractChannelHandlerContext.invokeWriteAndFlush(AbstractChannelHandlerContext.java:941)
at
io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:966)
at
io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:934)
at
io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:984)
at
io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:1025)
at
org.apache.plc4x.java.spi.Plc4xNettyWrapper$1.sendToWire(Plc4xNettyWrapper.java:100)
at
org.apache.plc4x.java.spi.internal.DefaultSendRequestContext.handle(DefaultSendRequestContext.java:108)
at
org.apache.plc4x.java.spi.internal.DefaultSendRequestContext.handle(DefaultSendRequestContext.java:1)
at
org.apache.plc4x.java.s7.readwrite.protocol.S7ProtocolLogic.lambda$42(S7ProtocolLogic.java:1535)
at
org.apache.plc4x.java.spi.transaction.RequestTransactionManager$TransactionOperation.run(RequestTransactionManager.java:225)
at
java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:840)
### Version
v0.13.1
### Programming Languages
- [ ] plc4c
- [ ] plc4go
- [x] plc4j
- [ ] plc4net
- [ ] plc4py
### Protocols
- [ ] AB-Ethernet
- [ ] ADS /AMS
- [ ] BACnet/IP
- [ ] C-Bus
- [ ] CANopen
- [ ] EtherNet/IP
- [ ] Firmata
- [ ] IEC-69870
- [ ] KNXnet/IP
- [ ] Modbus
- [ ] OPC-UA
- [ ] Profinet
- [x] S7
- [ ] S7-light
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]