Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. WCF and WF
  4. How to determine what Endpoint of WCF service client is connected to

How to determine what Endpoint of WCF service client is connected to

Scheduled Pinned Locked Moved WCF and WF
questionwcfcsharpwpftutorial
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    BenPage
    wrote on last edited by
    #1

    Hi I have a WCF service with multiple endpoints. The endpoints each uses its own binding configuration. One endpoint uses a TCP binding and the other a HTTP binding. My question is: In the service code, how do I determine on which of the bindings did the client connect? I know how to simply list all the service's endpoints OperationContext.Current.Host.Description.Endpoints and how to obtain an endpoint's binding: OperationContext.Current.Host.Description.Endpoints[0].Binding But how do I determine which binding was used by the client, instead of just indexing the first Endpoint? Thanks

    S 1 Reply Last reply
    0
    • B BenPage

      Hi I have a WCF service with multiple endpoints. The endpoints each uses its own binding configuration. One endpoint uses a TCP binding and the other a HTTP binding. My question is: In the service code, how do I determine on which of the bindings did the client connect? I know how to simply list all the service's endpoints OperationContext.Current.Host.Description.Endpoints and how to obtain an endpoint's binding: OperationContext.Current.Host.Description.Endpoints[0].Binding But how do I determine which binding was used by the client, instead of just indexing the first Endpoint? Thanks

      S Offline
      S Offline
      Snowdog
      wrote on last edited by
      #2

      I found the answer to this question here: http://www.danrigsby.com/blog/index.php/2008/05/25/get-the-service-endpoint-address-a-client-is-accessing-in-wcf/

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups