을 사용하고 있습니다 비록 오류 메시지가은 BasicHttpBinding와 관련된 그것은 나에게 다음과 같은 오류 메시지가 제공하기 :는 내가있는 wsHttpBinding
인터페이스입니다 당신이 당신의 서비스 인터페이스 I를 게시 한 경우계약이 세션이 필요합니다,하지만 바인딩 'BasicHttpBinding'이 지원하지 않습니다. 을 지원하도록 올바르게 구성되지 않았습니다.
다음[ServiceContract(Namespace="http://server.com/orderservices/",SessionMode=SessionMode.Required)] public interface IOrderService { [OperationContract(IsInitiating=true,IsTerminating=false)] string GetOrderNumber(); [OperationContract(IsInitiating = false, IsTerminating = true)] void CreateOrder(string orderXML); }
내 web.config 파일 (서비스가 IIS 7에서 호스팅되는)입니다 : 여기
<system.serviceModel>
<bindings>
<wsHttpBinding>
<binding name="longTimeoutBinding"
receiveTimeout="00:10:00" sendTimeout="00:10:00">
</binding>
</wsHttpBinding>
</bindings>
<services>
<service name="eMidWare.OrderService">
<host>
<baseAddresses>
<add baseAddress = "http://localhost/" />
</baseAddresses>
</host>
<!-- Service Endpoints -->
<endpoint
address=""
binding="wsHttpBinding" bindingConfiguration="longTimeoutBinding"
contract="eMidWare.IPricingDataService">
</endpoint>
<endpoint
address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior>
<serviceDebug includeExceptionDetailInFaults="True" />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
.NET 4? ? –
@marc_s, yes .NET 4에 있습니다. – Attilah
@marc_s .svc 파일을 가리키는 브라우저를 사용하여 로컬로 서비스에 액세스 할 수도 없습니다. – Attilah