WorkflowServiceHost (.NET Framework 3.5) を WAS へホストする書き方

環境:
Visual Studio 2008 Beta 2 

こんにちは。

こちら でご紹介している .NET Framework 3.5 からの WCF / WF 連携の新機能 (WorkflowServiceHost) ですが、これを WAS に展開し起動を自動化するには、.svc と .config を以下のように記述します。

[Service.svc]
<%@ ServiceHost Language=”C#” Debug=”true” Service=”OrderApplicationService.OrderWorkflow” Factory=”System.ServiceModel.Activation.WorkflowServiceHostFactory” %>

[web.config]
… 前半省略 (以下、ServiceModel の設定のみ) ….
  <system.serviceModel>
    <services>
      <service name=”OrderApplicationService.OrderWorkflow” behaviorConfiguration=”OrderWorkflowBehavior”>
        <endpoint address=””
                  binding=”wsHttpContextBinding”
                  contract=”OrderApplicationService.IOrderWorkflow” />
        <endpoint address=”mex”
                  binding=”mexHttpBinding”
                  contract=”IMetadataExchange” />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name=”OrderWorkflowBehavior”>
          <serviceMetadata httpGetEnabled=”true” />
          <serviceDebug includeExceptionDetailInFaults=”true” />
          <serviceCredentials>
            <windowsAuthentication
                allowAnonymousLogons=”false”
                includeWindowsGroups=”true” />
          </serviceCredentials>
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>

 

Advertisements

One thought on “WorkflowServiceHost (.NET Framework 3.5) を WAS へホストする書き方

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s