iis - WCF Service and Concurrency -


i have driver need access via web site not thread-safe. since many people can on site @ given time figured create wcf service handle calls. of calls asynchronous calls add items work queue. synchronous calls list of items still unprocessed or items have been processed.

since driver isn't thread safe, service must take in potentially many requests @ once , either add items work queue, return work queue, or return work-completed queue. single-threaded operation in service needs read work queue, processes job using non-thread-safe driver, and, when complete, update work-completed queue.

while conceptually have clear in mind do, specifics of implementation confuse me little. think should host service in iis since have respond web requests , otherwise act other web site, i'm not sure how guarantee access of driver remain single-threaded without blocking web requests. need second service, perhaps windows service, process access driver , use iis-hosted wcf service next queue item , update queue when processing complete?

i'd consider:

  1. clients call aspx pages,
  2. pages call wcf service (netmsmqbinding)? - avoid blocking , waiting (singke service, can hosted want).
  3. when server done - it's notify clients (websocket? signalr?)

Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -