For reasons that we're not going to elaborate further, I've been trying to host a WCF service with msmq binding in IIS. This didn't work all that well as my service refused to fetch any messages unless I hit the MEX-page first.
I tried a lot of things, such as making sure everything needed was properly installed, but the one thing I missed was that the WAS is running on the Network Service Account, and this account must have access to the MSMQ queue. The service itself is running in an app-pool under a dedicated account, and it has all the necessary rights (and as soon as it is triggered by the MEX page, it works just fine), but it's the network service account that's going to watch the queue for me, and it needs the rights to do so.
Another thing was that the queue name needs to reflect the service name (ie. the svc-file), apparently because WAS needs to know what to actually activate when a message arrives.
However, the main thing to take away from all this is that IIS hosting probably shouldn't be your first choice for hosting WCF services using MSMQ. I'm not really aware of any specific pro's for doing this, and I'm not really going to do it again without very specific reasons.
När jag måste skriva, så skriver jag.
21 okt. 2013
Prenumerera på:
Inlägg (Atom)