【发布时间】:2017-09-10 03:18:06
【问题描述】:
我已经使用 Visual Studio 2015 创建了本地无状态 WebAPI 和 Statefull 数据服务。它通过实现http://localhost:344/api/abc/getEmployee 在本地系统和网站访问 WebAPI 服务中完美运行。然后我在 Azure 上部署了服务结构应用程序并收到了客户端 URL
http://xyz.southeastasia.cloudapp.azure.com:1900/Explorer/index.html#/abc.apptype/app/abc.app/service/abc.app%252webservices
我的问题是如何从这个 Azure 客户端 URL 调用我的 WebAPI 控制器和操作?
http://xyz.southeastasia.cloudapp.azure.com:1900/api/abc/getEmployee 不工作。
注意:此网址不安全,将被手机和网站使用。
【问题讨论】:
-
“不工作”是什么意思?你得到了什么 HttpStatus 代码? 404?
-
将外部端口转发到负载均衡器上的内部端口 334,然后通过 http://{lbip}:extport/api/abc... 访问...
-
@MegaTron- 我在检查xyz.southeastasia.cloudapp.azure.com:19000 Url 时收到“无法得到任何响应。确保后端正常工作”.....
标签: asp.net-web-api azure-service-fabric