-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Tunnel Configuration Check Feature #48
Conversation
return | ||
} | ||
Logger.main.debug("Connection configuration: \(cfg)") | ||
Task { | ||
do { | ||
mgr.isEnabled = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the point to do check before connect if we have separate methods to check before it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In case the tunnel had gotten disabled, re-enable and save it, then connect.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But it should as the pseudo code on application side:
if !checkTunnelConfiguration() {
setupTunnel()
}
connect()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes correct, but if checkTunnelConfiguration returns true that means tunnel manager exists, but the tunnel can be disabled from system in some cases so it needs to be re-enabled before connecting.
@@ -82,7 +96,6 @@ void CALLBACK ConnectionStatusObserver::ServiceNotifyCallback(void* ptr) { | |||
std::unique_ptr<flutter::StreamHandlerError<flutter::EncodableValue>> ConnectionStatusObserver::OnListenInternal( | |||
const flutter::EncodableValue* arguments, std::unique_ptr<flutter::EventSink<flutter::EncodableValue>>&& events) { | |||
sink_ = std::move(events); | |||
// sink_->Success(flutter::EncodableValue(ConnectionStatusToString(ConnectionStatus::disconnected))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leftover?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes
No description provided.