Session migration (#72)
* impl * retry logic * simulate * pass checks * adjust log level * retry condition * fix simulate scenario params * format * use `RTCPeerConnectionState` instead of `RTCIceConnectionState` * adjust retry * additional check for completer * more logging * fix id * pub * change package * doc update * retry tests * format * apply suggestions
This commit is contained in:
@@ -149,6 +149,18 @@ class _ControlsWidgetState extends State<ControlsWidget> {
|
||||
}
|
||||
}
|
||||
|
||||
void _onTapSimulateScenario() async {
|
||||
final result = await context.showSimulateScenarioDialog();
|
||||
if (result != null) {
|
||||
print('${result}');
|
||||
await widget.room.simulateScenario(
|
||||
nodeFailure: result == SimulateScenarioResult.nodeFailure ? true : null,
|
||||
migration: result == SimulateScenarioResult.migration ? true : null,
|
||||
serverLeave: result == SimulateScenarioResult.serverLeave ? true : null,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
void _onTapSendData() async {
|
||||
final result = await context.showSendDataDialog();
|
||||
if (result == true) {
|
||||
@@ -238,6 +250,11 @@ class _ControlsWidgetState extends State<ControlsWidget> {
|
||||
icon: const Icon(EvaIcons.settings2),
|
||||
tooltip: 'Subscribe permission',
|
||||
),
|
||||
IconButton(
|
||||
onPressed: _onTapSimulateScenario,
|
||||
icon: const Icon(EvaIcons.alertTriangle),
|
||||
tooltip: 'Simulate scenario',
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user