Solved

WCF Service has zero application (non-infrastructure) endpoints

Posted on 2010-09-19
2
2,311 Views
Last Modified: 2012-05-10
Hello

I am trying to set up a WCF service but I keep bumping into the same error. Struggling to find any other post relevant given the number of potential combinations of configurations.

I am using IIS 7.5, and I want to set up a wsHttpBinding with a Mtom encoding. My Web.config is as follows:

<system.serviceModel>
    <bindings>
      <wsHttpBinding>
        <binding name="backupBinding" messageEncoding="Mtom">
          <security>
            <transport>
              <extendedProtectionPolicy policyEnforcement="Never" />
            </transport>
          </security>
        </binding>
      </wsHttpBinding>
      <mexHttpBinding>
        <binding name="backupBindingMex" />
      </mexHttpBinding>
    </bindings>
    <services>
      <service behaviorConfiguration="zbearWCFServices.backupServiceBehavior"
        name="zbearWCFServices.backup">
        <endpoint address="backup.svc" binding="wsHttpBinding" bindingConfiguration="backupBinding"
          name="backupWsEndPoint" bindingName="backupBinding" contract="zbearWCFServices.IBackup">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" name="backupMexEndPoint"
          bindingName="backupBindingMex" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://wcfs.MYWEBDOMAIN.net/" />
          </baseAddresses>
        </host>
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="zbearWCFServices.backupServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="false" />
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>

Open in new window


I have a backup.svc file which contains the following:
<%@ ServiceHost Language="VB" Debug="true" Service="zbearWCFServices.Backup" CodeBehind="backup.svc.vb" %>

Open in new window

and an implementation (backup class) of the backup interface. The backup interface (IBackup) is in a file called backup.vb


Looking at other example I am not sure of what I am doing wrong. By trying the following in a browser (local machine)

http://wcfs.MYWEBDOMAIN.net/backup.svc

I get the error below (cf image).
 ErrorWould anyone have any idea of where I got it wrong?

thanks in advance for your help!
Charles

0
Comment
Question by:cm2187
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 18

Accepted Solution

by:
DarrenD earned 500 total points
ID: 33732816
Hi,

This could be something simple like case sensitivity.

In your backup.svc file you have
Service="zbearWCFServices.Backup"

In your Web.Config you have
<service behaviorConfiguration="zbearWCFServices.backupServiceBehavior" name="zbearWCFServices.backup">

Change it to
<service behaviorConfiguration="zbearWCFServices.backupServiceBehavior" name="zbearWCFServices.Backup">

Capital B....

See if this helps,

Darren

0
 

Author Closing Comment

by:cm2187
ID: 33738901
OMG! I could have spent months without spotting that. Indeed it works! Thanks for your help!!!
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial will show you how to add an attribute to an XML (http://en.wikipedia.org/wiki/XML) stream returned from a Windows Communication Foundation (http://en.wikipedia.org/wiki/Windows_Communication_Foundation) (WCF) Web Service.  Some knowled…
In previous Articles, we have discussed how we can upload a file using .asmx web service and isolated storage space. Here, in continuation to the topic, I am going to discuss how we can use WCF for the same purpose. Steps: 1.Create the silverli…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question