I would like to host my 'WCF REST' service without IIS. I have used the following url (http://msdn.microsoft.com/en-us/library/community/add/ms733069(v=vs.90).aspx[^])
and successfully implemented the sample given.
But when I tried to implement my WCF Rest service, I got the following exception....
Service 'xxx' has zero application (non-infrastructure) endpoints. This might be because noContents of my app.config is given below....
configuration file was found for your application, or because no service element matching
the service name could be found in the configuration file, or because no endpoints were
defined in the service element.
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<services>
<service name="Microsoft.ServiceModel.Samples.RestService" behaviorConfiguration="RestServiceBehavior">
<host>
<baseAddresses> <add baseAddress="http://localhost:8000/ServiceModelSamples/service"/> </baseAddresses>
</host>
<endpoint address="" binding="wsHttpBinding" contract="Microsoft.ServiceModel.Samples.IRestService" />
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
</service>
</services>
<behaviors>
<serviceBehaviors> <behavior name="RestServiceBehavior"> <serviceMetadata httpGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="False"/>
</behavior> </serviceBehaviors> </behaviors> </system.serviceModel>
</configuration>
Can someone help me to solve this?
Thanks
Sebastian