connect method
Connect to sync service
Implementation
@override
Future<void> connect() async {
try {
// Production: _channel = WebSocketChannel.connect(Uri.parse(url));
// _channel!.stream.listen(_handleMessage);
_isConnected = true;
if (kDebugMode) {
debugPrint('WebSocket connected to $url');
}
} catch (e) {
if (kDebugMode) {
debugPrint('WebSocket connection error: $e');
}
rethrow;
}
}