Senior .Net Developer Question:

Explain me why do we use MSMQ?

Tweet Share WhatsApp

Answer:

Microsoft Message Queuing, or MSMQ, is technology for asynchronous messaging. Whenever there's need for two or more applications (processes) to send messages to each other without having to immediately know results, MSMQ can be used. MSMQ can communicate between remote machines, even over Internet. It's free and comes with Windows, but is not installed by default.

This mainly addresses the common use case of asynchronous message processing: you have a service Service1 that communicates (send messages) with another part of your software architecture, say Service2.

Main problem: what if Service2 becomes suddenly unavailable? Will messages be lost? If you use MSMQ it won't: Service1 will send messages into a queue, and Service2 will dequeue when it is available.

Download Senior .Net Developer PDF Read All 60 Senior .Net Developer Questions
Previous QuestionNext Question
Explain me what is an anonymous method and how is it different from a lambda expression?Tell us the difference between the while and for loop. Provide a .NET syntax for both loops?