.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

NetMsmqBinding in WCF

Posted By:      Posted Date: September 15, 2010    Points: 0   Category :WCF
Below mentioned link is very useful as a beginner to me, but my confusion where should we keep the class HostApp in the service. And this example will run as console application. http://msdn.microsoft.com/en-us/library/system.servicemodel.netmsmqbinding.aspx Actually I would like to write one WCF service for MSMQ and the functionality is service contains one method and it accepts parameter as a string, when the user pass message from client that string should be passed to MSMQ. Here the service should be independent, when user wants to execute MSQM functionality he needs to reference from the MSMQ service as like webservice reference. Please suggest me. Advance Thanks.

View Complete Post

More Related Resource Links

WCF service with netMsmqbinding

Can anybody please give one example for WCF service with netMsmqbinding. Already I developed using console application it is working but I need to do same functionality in WCF service application and that shoud be deployed in IIS. Otherwise just suggest me how to do this. Advance Thanks

NetMsmqBinding sees my contract as TwoWay when it is not


I getting an exception:Service cannot be started. System.InvalidOperationException: Contract requires TwoWay (either request-reply or duplex), but Binding 'NetMsmqBinding' doesn't support it or isn't configured properly to support it. My OperationContract states IsOneWay = true.  Below are my contracts and configuration.

[WCF::ServiceContract(SessionMode = WCF::SessionMode.NotAllowed)]
    public partial interface IJobSaleOrderQueue
        [WCF::OperationContract(IsOneWay = true)]
        void SubmitJobSaleOrderQueue(ProductionPlanSvc.WCF.MessageContracts.SubmitJobSaleOrderQueueRequest request);


<service name="ProductionPlanSvc.WCF.ServiceImplementation.JobSaleOrderQueueService" behaviorConfiguration="Default">
            <add baseAddress="net.msmq://localhost/private/JobSaleOrderTransQueue"/>


WCF and NetMsmqBinding (in order delivery)



We use WCF and MSMQ (NetMsmqBinding) for communication between two sub-systems that need to be disconnected and asynchronous in nature. The problem is related to the delivery of messages "in order".

According to the documentation, "messages sent to a transactional queue are transferred exactly once in order". This is quoted from a Microsoft source "Queuing in WCF". However, in reality, our tests have shown that this is not the case. This is true even for messages that are processed without any faults (and therefore not poison).

The WCF demo application Msmq3 and Msmq4 have been tested, with some different modifications to include and check for a consecutive message id. The attributes in ServiceContrant and OperationContract, and different NetMsmqBindings settings has been tested. Our tests show that the WCF target is invoked in parallel. That is, message id 10 can be received before message id 9, for example.

Is this a known problem? Is our "in order" requirement not common scenario? How to solve it without exotic instance management settings that could effect the scalability and transaction robustness?


Transactional queue with netMsmqBinding only pulling a single message from the queue


I have a xamlx workflow hosted in a windows service using WorkflowServiceHost. I want to read messages from a transactional MSMQ queue that is populated from another service.

I cannot get my workflow to read more than a single message from the queue, then it never processes any more messages. I get the same behaviour when hosting th workflow from a console as well.

Here is my xamlx:

<WorkflowService mc:Ignorable="sap" ConfigurationName="Service1" sap:VirtualizedContainerService.HintSize="307,345" Name="Service1" mva:V
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend