Azure应用服务应POST请求返回404

问题描述

我有一个WCF服务,该服务已通过VS 2017发布到Azure。我可以使用浏览器中的URL来访问该服务,并且它按预期方式工作。该服务侦听来自Salesforce的出站消息。如果我发送消息,它将返回404错误。该相同服务可以很好地发布到服务器上的IIS。 App Service中是否存在允许处理POST的设置?

更新:我认为问题可能出在web.config上,这是我拥有的:

  <system.serviceModel>
    <bindings />
    <client />
    <services>
      <service name="WorkflowNotificationServices.CaseNotificationService" behaviorConfiguration="debug">
        <endpoint binding="basicHttpBinding" contract="CaseNotificationService" />
      </service>
      <service name="WorkflowNotificationServices.CommentNotificationService" behaviorConfiguration="CommentNotificationServiceBehavior">
        <endpoint binding="basicHttpBinding" contract="CommentNotificationService" />
      </service>
      <service name="WorkflowNotificationServices.TaskNotificationService" behaviorConfiguration="TaskNotificationServiceBehavior">
        <endpoint binding="basicHttpBinding" contract="TaskNotificationService" />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="CaseNotificationServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
        </behavior>
        <behavior name="CommentNotificationServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
        </behavior>
        <behavior name="TaskNotificationServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
        </behavior>
        <behavior name="debug">
          <serviceDebug includeExceptionDetailInFaults="true" />
        </behavior>
        <behavior name="">
          <serviceMetadata httpGetEnabled="true" httpsGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="false" />
        </behavior>
      </serviceBehaviors>
    </behaviors>
    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
  </system.serviceModel>

这在带有IIS的VM上正常工作。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

依赖报错 idea导入项目后依赖报错,解决方案:https://blog....
错误1:代码生成器依赖和mybatis依赖冲突 启动项目时报错如下...
错误1:gradle项目控制台输出为乱码 # 解决方案:https://bl...
错误还原:在查询的过程中,传入的workType为0时,该条件不起...
报错如下,gcc版本太低 ^ server.c:5346:31: 错误:‘struct...