【发布时间】:2019-07-05 08:44:55
【问题描述】:
我正在使用http(dart包)连接到本地部署的springboot api, 但是,应用程序抛出 Connection denied 错误 111 并显示错误的端口
尝试打开端口看看是否有帮助,将本地主机替换为计算机 ipm 更改了 springboots 端口,但问题仍然存在。
连接服务器的线路
final response = await http.get('http://localhost:8080/api/v1/alltables');
控制台日志错误:
ERROR:flutter/shell/common/shell.cc(184)] Dart Error: Unhandled exception:
E/flutter (27342): SocketException: OS Error: Connection refused, errno = 111, address = localhost, port = 49588
【问题讨论】:
标签: android spring-boot http dart flutter