开发者

Workflow Service host not publishing Metadata

Still hacking away with extreme persistence at WF services hosted outside of IIS. I'm now having issues with my WF service publishing metadata. Can someone take a look at my code and see what step I'm missing? The few tutorials that I've stumbled across for my scenario make it look so easy, and I know it is. I'm just missing something ridiculously simple. Here's my current trial code:

const string serviceUri = "http://localhost:9009/Subscribe";
WorkflowServiceHost host = new WorkflowServiceHost( new Subscribe(), new  Uri(serviceUri) );

host.AddDefaultEndpoints( );
host.Open();

Subscribe() is an activity that is coded in an xaml file and contains simple receive and sendreply activities to test out my hosted workflow service. It is NOT a xamlx (WF service) file. Seems like this should be simple enough to work but when I start the application and the service fires I get this message in my browser when navigating to the URI:

"Metadata publishing for this service is currently disabled."

Shouldn开发者_C百科't adding the default endpoints provide enough metadata and description to satisfy the service init and then go into its wait for message state?


For any future newbies, this also can be caused by not having your app.config setup correctly. Add the below to your app.config and then open your service location in your browser:

  <system.serviceModel>
    <bindings />
    <client />
    <behaviors>
      <serviceBehaviors>
        <behavior>
          <serviceDebug includeExceptionDetailInFaults="True"
                        httpHelpPageEnabled="True"/>
          <serviceMetadata httpGetEnabled="True"/>
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>


Well it appears that the debug instance process hung on my machine. I just used task manager to locate the executable and terminate the zombie process.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜