splatch commented on a change in pull request #227:
URL: https://github.com/apache/plc4x/pull/227#discussion_r588187766



##########
File path: 
plc4j/drivers/opcua/src/main/java/org/apache/plc4x/java/opcua/connection/OpcuaTcpPlcConnection.java
##########
@@ -384,8 +385,8 @@ public void close() throws Exception {
         CompletableFuture<PlcSubscriptionResponse> future = 
CompletableFuture.supplyAsync(() -> {
             Map<String, ResponseItem<PlcSubscriptionHandle>> responseItems = 
new HashMap<>();
             for (String fieldName : subscriptionRequest.getFieldNames()) {
-                final PlcSubscriptionField subscriptionField = 
subscriptionRequest.getField(fieldName);
-                final OpcuaField field = (OpcuaField) 
Objects.requireNonNull(subscriptionField);
+                final DefaultPlcSubscriptionField subscriptionField = 
(DefaultPlcSubscriptionField) subscriptionRequest.getField(fieldName);

Review comment:
       Shouldn't we be fine with just `PlcSubscriptionFiled` alone?




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to