Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Persistent Work Queue in C#

Imagine I want to have a small network of worker drones possibly on separate threads and possibly on separate processes or even on different PCs. The work items are created by a central program.

I'm looking for an existing product or service that will do this all for me. I know that there is MSMQ and also MQSeries. MQSeries is too expensive. MSMQ is notoriously unreliable. A database backed system would be fine, but I don't want to own/manage/write it. I want to use someone else's work queue system.

Related Articles:

  • Here is a similar question, but it's advocating building a custom queue mechanism.
  • The queue that I like a lot is this one from Google App Engine.
  • http://www.codeproject.com/KB/library/DotNetMQ.aspx
like image 739
101010 Avatar asked Aug 23 '11 15:08

101010


People also ask

What is a persistent queue?

persistent queue noun. A feature that you configure to take data that is in an input queue and store it to files on disk. Using a persistent queue can prevent data loss if the forwarder or indexer has too much data to process at one time.

Is queue a persistent data structure?

Queues. Representing a queue is a more significant challenge than a stack or a tree. With a queue, it's important to maintain linear structure but still maintain the ability to modify both ends of the queue. We cannot do this through a straightforward translation of the non-persistent structure.

What is Logstash persistent queue?

In Logstash 5.1, Persistent Queue was introduced as a beta feature, adding disk-based resiliency to Logstash pipelines. In Logstash 5.4 it was officially promoted to General Availability as a production-ready alternative to the in-memory queue.


1 Answers

If you follow some guidelines you can use a database as a queue store with good success, see Using tables as Queues.

SQL Server comes with its own built-in message queuing, namely Service Broker. It allows you to avoid many of the MSMQ pitfalls when it comes to scalability, reliability and high availability and disaster recovery scenarios.

Servcie Broker is fully integrated in the database (no external store, one consistent backup/restore, one unit of failover, no need for expensive two-phase-commit DTC between message store and database, one single T-SQL API to access and program both the messages and your data) and also has some nice unique features such as transactional messaging with guaranteed Exactly-Once-In-Order delivery, correlated message locking, internal activation etc.

like image 113
Remus Rusanu Avatar answered Sep 22 '22 11:09

Remus Rusanu