stop method
Implementation
Future<void> stop() async {
logger.fine('stopping service host');
await _stopServer();
logger.fine('stopping hosted ports');
final currentHosts = _hosts;
if (currentHosts != null) {
await Future.wait(currentHosts.map((h) => h.stop()));
}
_hosts = null;
logger.fine('service host stopped');
}