Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 570033
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T13:21:30+00:00 2026-05-13T13:21:30+00:00

My endpoints specify which interface is used to govern the WCF service. Because it’s

  • 0

My endpoints specify which interface is used to govern the WCF service. Because it’s an interface, I can have multiple different concrete classes implement the interface’s functionality. How do I specify which concrete class should be used for a given WCF service’s endpoint?

How do you say for this endpoint, use this concrete class and for that endpoint, use that concrete class when both endpoints use the same interface?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T13:21:30+00:00Added an answer on May 13, 2026 at 1:21 pm

    The contract implementation type to use is defined when the ServiceHost instance is created. If you have multiple endpoints served by the same ServiceHost, it will create an instance of the same type to respond to requests to these endpoints.

    If you want two endpoints for the same contract to use different implementations, you have two choices:

    • expose the two endpoints on two separate service hosts. (Either through creating two ServiceHost instances or specifying two <service> configuration elements);
    • have a composite implementation for the class that has two separate implementations of the same interface (through any OOP approach you can think of) and dispatches the calls to these based on the endpoint address.

    I personally would stick with the first approach. If you go for the second approach, you would be essentially reimplementing ServiceHost yourself.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Jersey REST service which has endpoints that can return either application/xml
Is it possible to create a WCF REST 4.0 service which has two endpoints
Currently I have several endpoints within a single service which invoke the same action
I have a WCF web service which allows both Basic HTTP and WS-HTTP clients,
I have defined two endpoints in my App.Config file as <system.serviceModel> <services> <service name=HostDirectAddress.ITestService
I am trying to include two endpoints in my WCF web based service -
i have noticed certain sites which allows limited hit per IP so can i
I have a WCF Windows service with an endpoint specified in the config file
I need to test WCF service, but have only one computer, so my service
We have a WCF (Windows Communication Foundation) client and service application. We're using Windows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.