Create base container image with MSMQ-Server
The MSMQ-Server role is a prerequisite for Particular NServiceBus installation. As NServiceBus handlers are potentially a good fit for containerization, it was disappointing to find that it is not possible to install MSMQ-Server in a container. Please create a base image with this support!
Scott Taketani commented
Hi, I hope this is a good place to post my situation with MSMQ and containers
I've tried to get MSMQ working for our use case but can't seem to do so. Basically,we are trying to use private queues in a server core container which are accessed through WCF (need the net msmq binding and msmq integration binding to work) from another container sharing the same NAT network.
Has anyone gotten this use case to work? If so, how?
I've tried setting the bind ip for MSMQ to the network adapter used by the container, exposing all the MSMQ ports through the Docker Build file, added the Everyone and Anoynmous Logon permissions to the queues, set the MSMQ security registry values inside the containers, and tried direct=os and direct=tcp using the container hostname and IP.
When trying to open the queue, I am always getting "The queue does not exist or you do not have sufficient permissions to perform the operation. (-1072824317, 0xc00e0003). The message cannot be sent or received from the queue. Ensure that MSMQ is installed and running. Also ensure that the queue is available to open with the required access mode and authorization. "
Accessing the queue from the same container that is hosting the queue works with WCF, but not from a different container (both running the same windows core image).
Ken Schlobohm commented
New location for the blog related to this fix:
its a shame that msmq-multicasting is not available - showstopper for me to containerise my apps.
This have been generally available on Windows Server, version 1803 since May.
Any word on when this will be generally available?
Weijuan Shi Davis commented
Thanks Shahid. Yes indeed, in the latest Server Insider build, MSMQ now can install on a Server Core container build. Please go ahead and give it try. Let us know if this works for your use case. Thanks.
Here is the Server Core container insider build:
Here is a blog related to this fix and other ones:
Shahid Iqbal commented
As this user voice hasnt been updated people might be interested to know the latest insiders build now supports msmq!
Shahid Iqbal commented
Even if you're not trying to run local queues it would seem you need to have the feature installed to access remote queues so this would be a significant barrier to a lot of enterprise apps which use MSMQ they are basically completely blocked from containers without some kind of re-write
I hate to be the bearer of bad news, but an MSMQ-Server container image is not an easy thing to do.
It's quite unlikely we or the MSMQ team will be able to take on this work.
I know this is discouraging and frustrating, but I do want you to know we seriously do care and listen to your ideas. A great deal of our product development is solutions for problems or ideas you bring to us.
However, we can't build everything you ask for and this is one of those cases.
We're bummed too.
See the forum for a more full answer
Yuriy Zaletskyy commented
Any plans on when msmq will become available in docker?
We use transactions, but everything is local (no cross-container support from us)
We use MSMQ in an old-school but massive asp.Net app. We are using MSMQ for simple queuing services, and we chose MSMQ because it is reliable and robust. We require no cross-queue operations, distributed queues, or SQL Server support.
Without MSMQ we must re-implement our queuing model using SQL Server, and unattractive prospect.
We also use NServiceBus on a fairly large on-prem app. This is also currently stopping us from using containers.
Not only nservicebus. Wcf uses them too.
For my team ~700 people this is a big stopper
That is a show stopper for us. Without this we cannot use docker container as our website requires MSMQ
wauk hill commented
most of our services rely on msmq and there is no way forward without a container that can run msmq.So I cant use docker for now.
Having the MSMQ feature available in windows containers will also make automated testing significantly easier. At present you have to spin a virtual machine to test anything MSMQ/DTC related.
Ross Beehler commented
Note that NServiceBus also relies on MSDTC by default, so that would also make sense to include alongside MSMQ. Also, I'm sure there are other missing features, such as a manageable way to map endpoints across container boundaries, as I'm under the impression the networking abstractions are quite limited and clunky with Windows Containers at this point.