嗨,我一直在試圖解決我的問題,但無能爲力。服務不可用503 +位於http://localhost/ProductsService/Service.svc的HTTP服務太忙
問題是
http://localhost/productservice/service.svc
型這個地址在我的瀏覽器時,它給了我503服務不可用錯誤
當我從2010 VS我的代碼運行它給我
HTTP服務位於http://localhost/ProductsService/Service.svc太忙了。 異常。
ProductService使用ApplicationPoolIdentity在ASP.NET v4.0集成應用程序池中運行。
我只是不知道我需要做什麼!
(Windows 7家庭& IIS7)
basicHttpBinding的使用
服務器端的配置是
<?xml version="1.0"?>
<configuration>
<connectionStrings>
<add name="AdventureWorksEntities" connectionString="metadata=res://*/ProductsModel.csdl|res://*/ProductsModel.ssdl|res://*/ProductsModel.msl;provider=System.Data.SqlClient;provider connection string="Data Source=PINCHY\SQLEXPRESS;Initial Catalog=AdventureWorks;Integrated Security=True;MultipleActiveResultSets=True"" providerName="System.Data.EntityClient"/>
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
</assemblies>
</compilation>
</system.web>
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior>
<!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
<serviceMetadata httpGetEnabled="true"/>
<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information -->
<serviceDebug includeExceptionDetailInFaults="false"/>
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true"/>
</system.serviceModel>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
</configuration>
客戶端的app.config是
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="BasicHttpBinding_IProductsService" closeTimeout="00:01:00"
openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
useDefaultWebProxy="true">
<readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<security mode="None">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="" />
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://localhost:80/ProductsService/Service.svc"
binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IProductsService"
contract="ProductsService.IProductsService" name="BasicHttpBinding_IProductsService" />
</client>
</system.serviceModel>
</configuration>
任何幫助將非常感謝 Tha nks
你需要給我們更多的去!你的配置是什麼?你使用什麼綁定?向我們展示服務器端配置! (標記內的任何內容) –
2011-01-25 12:03:57
我已添加配置感謝 – Pinchy 2011-01-25 12:47:03
您的配置看起來正確。您是否嘗試調試您的服務?順便說一句。 Windows 7家庭有IIS7? – 2011-01-26 21:40:15