flywithrain commented on issue #1168: URL: https://github.com/apache/plc4x/issues/1168#issuecomment-1774112498
I`m sorry. Due to some reasons, I didn`t describe it clearly before. My concerns are as follows Thread A: ```java // step 1 PlcConnection con = cachedPlcConnectionManager.getConnection(); // step 2 PlcWriteRequest writeRequest = con.writeRequestBuilder().build(); // step 5 PlcWriteResponse writeResponse = writeRequest.execute().get(); ``` Thread B: ```java // step 3 PlcConnection con = cachedPlcConnectionManager.getConnection(); // step 4 con.close(); ``` When executing step 5 the "writer" in method `execute()` actually is the old 'con' which closed by thread B in step 4, that will cause the write fail. Maybe the method close() can wait other thread write finish or use the new connection to do write? -- 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]
