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. WCF client access layer best practice

WCF client access layer best practice

Scheduled Pinned Locked Moved WCF and WF
questioncsharpwcfdiscussionworkspace
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.
  • L Offline
    L Offline
    laserbaronen
    wrote on last edited by
    #1

    I have created an access layer for my application. I created a subclass of the generic ChannelFactory class to be able to separate the WCF configuration from the main application. Just wondering, is this the usual way to go about it, or is it pherhaps considered a best practice? If not, what is?


    betonglasermur.FeedDwarf(pur_is, 17);
    ProcessStartupInfo.AintNotCreateNoWindow = (false && !true) != (true || false) ? false == true ? true : false : (true != false && false);

    Morgonen är tröttmans mecka

    J 1 Reply Last reply
    0
    • L laserbaronen

      I have created an access layer for my application. I created a subclass of the generic ChannelFactory class to be able to separate the WCF configuration from the main application. Just wondering, is this the usual way to go about it, or is it pherhaps considered a best practice? If not, what is?


      betonglasermur.FeedDwarf(pur_is, 17);
      ProcessStartupInfo.AintNotCreateNoWindow = (false && !true) != (true || false) ? false == true ? true : false : (true != false && false);

      Morgonen är tröttmans mecka

      J Offline
      J Offline
      Jon Rista
      wrote on last edited by
      #2

      Usually, when I need to access WCF services from client applications, I derive from System.ComponentModel.ClientBase<T> for the appropriate service contract interface. This creates a client proxy for your service with the same contractual interface. I would say that deriving from ChannelFactory directly sounds like a bit of a round about way of accessing a WCF service...perhapse not 'round about', but definitely more work. If you want to abstract the service more, so your clients have a bit more independance from whatever your services are wrapping, just add another layer of classes around your proxies, and expose whatever interface meets the needs of your application (facade/adapter patterns). Then your free to change your services without screwing with your clients.

      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