J'utilise IIS 7.0 pour héberger un service WCF simple. Je l'écris en utilisant VSTS 2008 + .Net 3.5 + C#. Le problème est lorsque j'accède http://localhost:9999/service.svc (je suppose que dans le navigateur Web, nous pouvons parcourir le contenu de WSDL, et je crée un nouveau site web qui utilise le port 9999 et exécuter le pool d'applications sous compte administrateur), je rencontre l'erreur suivante, idées ce qui ne va pas?IIS hébergeant l'erreur de service WCF
http://i27.tinypic.com/a9r8cz.jpg
Voici mon service.svc:
<%@ ServiceHost Language="C#" Service="Gu.WCF.StudentManagement" %>
Voici mon web.config:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<services>
<service behaviorConfiguration="Gu.WCF.ServiceBehavior"
name="Gu.WCF.StudentManagement">
<endpoint address="" binding="basicHttpBinding" contract="Gu.WCF.IStudentManagement">
<identity>
<dns value="localhost" />
</identity>
</endpoint>
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="Gu.WCF.ServiceBehavior">
<!-- 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>
</system.serviceModel>
</configuration>
Fonctionne, cool! :-) – George2