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 606879
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T17:18:03+00:00 2026-05-13T17:18:03+00:00

I am to design a webservice using WCF that yields methods that don’t require

  • 0

I am to design a webservice using WCF that yields methods that don’t require a session (like static calls, eg: giving back some information about the webservice itsself) and other methods that require a session.

furthermore, the session based methods are using Workflows that are supposed to be able to be changed at runtime.

my current design would look like this:

there is a singleton service that runs in IIS that handles all the per call methods which also works as a host for the session based services. that way the singleton class knows about all the sessions and can halt the running workflows to exchange them.

is this a good/possible design choice?
is this a common scenario that uses a common design?
would be happy about any reading hints as the msdn help wasn’t such a help to me.

thanks for your answers
-redoced

  • 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-13T17:18:03+00:00Added an answer on May 13, 2026 at 5:18 pm

    Using a singleton WCF service class is almost never a good idea – unless you really have just one single (physical) resource which you want to protect from concurrent access, it doesn’t really make sense.

    Because: either it’s not multi-threading capable, but in this case, it becomes a huge bottleneck – requests are handled strictly sequentially – one after another. Not very good for performance.

    Or then you need to make the whole service multi-threading aware – and let me tell you, making this properly, safely, and efficiently isn’t for the faint of heart. It’s really really hard to get this right, and make it perform well.

    I really don’t see any need for this, at all.

    • leave you "static" message calls (as you call them) be per-call services – those are easy to program, work well, perform well, never cause any multithreading issues

    • those few service calls (hopefully!) that do require a session – put them on their own service endpoint(s), make them per-session, use the "SessionId" in your session to identify them. It’s a bit more work than per-call – but still nowhere near as complicated and error-prone as multi-threaded programming

    Resources for WCF sessions:

    • MSDN article on Using Sessions in WCF
    • WCF Sessions blog post

    Resources for WCF durable services (that persist their state between calls):

    • Blog post on "durable services"
    • WCF Durable Services
    • Orcas durable services
    • Screencast by Mike Taulty on durable WCF Services

    Resources for WCF Workflow Services:

    • Foundataions: Workflow Services
    • Channel9 webcast: Intro to Workflow Services
    • Webcast: Intro to workflow services in WCF 4.0
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Was: Design by contract: predict methods needed, discipline yourself and deal with code that
I'm designing a WCF webservice that will potentially get called by 10,000+ plus separate
I just got off a small project using a WCF/REST Web Service that used
I want to build a RESTful WebService that's using JSON for externalizing resources. The
Design an algorithm that, given a list of n elements in an array, finds
My design requires that I kill the get_configuration activity (Activity1) once the second_activity is
I would like input on the design I currently have planned. Basically, I have
I've been studying WCF and been refactoring my ASMX webservice solution (multiple projects) slowly
This is my first attempt to build a json webservice using the Tornado Framework
In android, I'm using model classes with methods to handle the data manipulation. My

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.