zoukankan      html  css  js  c++  java
  • How to publish metadata for WF serviceWeird problem.

    recently ,when i was coding a simple enought wf service program.

    i found a weird problem by using the Wcf test client tool.

    my wcf endpoint is  http://localhost:8000/WFServices

    but if i acess this address in my chrome.

    i got a message like this.



    The service page has some helpful tips to enable metadata for a WCF service.  Unfortunately the same tips do not apply to a WCF Workflow Service.  In previous releases of WCF you had to apply a service behavior using a named behavior configuration that applied to your service.  In .NET 4.0 or later you do not have to use a named behavior configuration and you don’t have to declare a <service> in your configuration file for more information on this see Simplified Configuration for WCF

    Most of the time when creating Workflow Services you will use the default service configuration without declaring a <service> tag in your config file.  Enabling service metadata then is a simple matter of adding the following configuration.

    <configuration>
      <system.serviceModel>
        <behaviors>
          <serviceBehaviors>
            <behavior name="">
              <serviceMetadata httpGetEnabled="True"/>
            </behavior>
          </serviceBehaviors>
        </behaviors>
      </system.serviceModel>
    </configuration>

    but there is a trap here . after you finish configuration you service .you must delete the all the files under the Debug folder . and press Ctrl + f5 to make the service work. otherwise you will got the same error too.  囧

  • 相关阅读:
    带CheckBox的dojo Tree简单实现,并实现级联选取
    dojox.grid.EnhancedGrid
    Java内存模型及GC原理
    团队任务(第三次)
    团队任务二
    团队任务(一)
    词频统计及其效能分析
    贪吃蛇
    第一课
    软工七组团队2-1作业
  • 原文地址:https://www.cnblogs.com/malaikuangren/p/2552568.html
Copyright © 2011-2022 走看看