Event Subscription in OPC-UA till Client Application does not close. #1901
Unanswered
codekundan
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi Plc4x Team, I am writing a JavaFX application in which I want to read Tags values especially BOOL ones to trigger fetching from Database and pass the values to PLC. I am able to get the Events but point is I want it for indefinite time till the user does not close the JavaFX Application. After few hours, there is no response from Event change. Any help regarding to make Event Subscription for long periods of time as much as possible ?
`package com.example.scadademo;
import javafx.concurrent.Task;
import org.apache.plc4x.java.DefaultPlcDriverManager;
import org.apache.plc4x.java.api.PlcConnection;
import org.apache.plc4x.java.api.exceptions.PlcConnectionException;
import org.apache.plc4x.java.api.exceptions.PlcRuntimeException;
import org.apache.plc4x.java.api.messages.PlcSubscriptionResponse;
import java.util.concurrent.CompletableFuture;
public class EventSubscriptionTask extends Task {
@OverRide
protected Void call() throws Exception {
new EventSubscriptionTask().plcFunc();
return null;
}
}
`
Beta Was this translation helpful? Give feedback.
All reactions