msmq

How to enforce message queue sequence with multiple WCF service instances

爱⌒轻易说出口 提交于 2019-11-30 13:56:14
I want to create a WCF service which uses an MSMQ binding as I have a high volume of notifications the service is to process. It is important that clients are not held up by the service and that the notifications are processed in the order they are raised, hence the queue implementation. Another consideration is resilience. I know I could cluster MSMQ itself to make the queue more robust, but I want to be able to run an instance of my service on different servers, so if a server crashes notifications do not build up in the queue but another server carries on processing. I have experimented

Purge MSMQ queue and reset IIS from a bat file

拥有回忆 提交于 2019-11-30 13:47:58
Is it possible to purge a msmq queue from a bat file? Essentially I want to make a bat file or at least something quick and easy so that an untrained employee can click and fix without knowing any shell or admin tools Could someone please help me in the right direction? Take a look on MSMQAdm Utility Tasks administered through the utility programs include the following: Browsing local queues Purging messages Deleting individual messages Stopping and starting MSMQ service Connecting and disconnecting from the network Don't forget about powershell, take a look on PowerShell Community Extensions

MSMQ v Database Table

五迷三道 提交于 2019-11-30 11:02:46
问题 An existing process changes the status field of a booking record in a table, in response to user input. I have another process to write, that will run asynchronously for records with a particular status. It will read the table record, perform some operations (including calls to third party web services), and update the record's status field to indicate that processing is completed (or In Error, with an error count). This operation sounds very similar to a queue. What are the benefits and

Using Windows Services to process MSMQ messages via WCF

只愿长相守 提交于 2019-11-30 10:34:05
We have a solution where we are picking the messages using Windows Service. The Windows Service fires every after 2 minutes and retrieves the MSMQ message to pass it to a Web Service. Can I create a WCF service which will automatically picks up the messages from MSMQ Queue? Can I avoid Windows Service by using WCF Service if it support auto invocation? Q1: you can automatically pick up messages from MSMQ, you will need to look into the netmsmqbinding, there are some design considerations that you have to think about though, if you are used to the native MSMQ, you know that you have the ability

Getting Message by priority from MSMQ

岁酱吖の 提交于 2019-11-30 09:14:12
i am sending messages in MSMQ by setting its priority. using C# can i get the message from MSMQ having high priority first? just like we get in Priority Queue. and one thing more.. suppose there are three priority level 0 - high 1- medium 2 - low the sequence in queue is 2001122221111100 now if i send message with high priority(0) where it will be placed?? by setting priority in MSMQ. will it behave like actual Priority Queue? MSMQ does support priority queuing of messages, however messages of the same priority are handled in order of arrival when dequeued. For example, if you send 3 messages,

Is decoupling web and database tiers via MSMQ necessary or overkill?

流过昼夜 提交于 2019-11-30 07:29:47
I'm putting together a simple asp.net web control, that as the result of an ajax form post inserts a record into a MSQL database. It's possible that the page containing this control will recieve many thousands of hits in a small space of time and I'm worried about the performance issue of opening a database connection, inserting the record and then closing the connection for each request. A solution that has occured to me is to make the web control place a message into an MSMQ queue and have a Windows Service on the server periodically read the queue and do a batch insert. Does that sound like

MSMQ - message queuing has not been installed on this computer

纵然是瞬间 提交于 2019-11-30 07:03:05
I have written a sample application to write to a public and private queues that are on dev server. I don't have the message queue installed on my local machine. I am getting error: message queuing has not been installed on this computer. Error is on this line: MessageQueue.Exists(queueName) Here is the full test code, all commented and not commented private and public queues are resulting in the same error. What am i doing wrong here? using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text;

Not creating queues automatically in NServiceBus

好久不见. 提交于 2019-11-30 05:02:00
I'm running NServiceBus 3.0.0 rc2 but when I start the application (as local admin) without pre-creating the MSMQ's it errors with : The queue does not exist or you do not have sufficient permissions to perform the operation. This was not happening using NServiceBus 2.6. Below is my config: var bus = Configure.With() .Log4Net() .NinjectBuilder() .XmlSerializer() .DefiningCommandsAs(t => typeof(ICommand).IsAssignableFrom(t)) .DefiningEventsAs(t => typeof(IEvent).IsAssignableFrom(t)) .DefiningMessagesAs(t => typeof(IMessage).IsAssignableFrom(t)) .MsmqTransport() .DefineEndpointName("subscriber

How do I handle message failure in MSMQ bindings for WCF

本小妞迷上赌 提交于 2019-11-30 04:50:49
I have create a WCF service and am utilising netMsmqBinding binding. This is a simple service that passes a Dto to my service method and does not expect a response. The message is placed in an MSMQ, and once picked up inserted into a database. What is the best method to make sure no data is being lost. I have tried the 2 following methods: Throw an exception This places the message in a dead letter queue for manual perusal. I can process this when my strvice starts set the receiveRetryCount="3" on the binding After 3 tries - which happen instantanously, this seems to leave the message in queue

How can I remove messages from a queue?

一笑奈何 提交于 2019-11-30 03:56:59
问题 I have messages that get stuck in queue and I am looking for a way to programmatically remove them. Is there a way to remove messages from a queue if it has been sitting for more than x days? I can connect and delete a queue like this, but not sure how to remove individual messages. MessageQueue queue = new MessageQueue(@".\private$\SomeTestName"); //queue.Purge(); //deletes the entire queue try { // Peek and format the message. Message m = myQueue.Peek(); // Display message information.