Contents tagged with WCF

  • WCF RabbitMQ binding

    Hello everybody,

    recently I've spent plenty of time with the following task: Create Publisher/Subscriber application that via WCF send/receive messages from RabbitMQ. As foundation for my code I've used code from Dieg web site, just modified binding.

    Bindings were modified in App.config files. 

    Below goes bindings declarations:

    <system.serviceModel>

    <extensions>

    <bindingExtensions>

    <add name="rabbitMQBinding"

    type="RabbitMQ.ServiceModel.RabbitMQBindingSection, RabbitMQ.ServiceModel, Version=3.5.7.0, Culture=neutral,PublicKeyToken=null"/>

    </bindingExtensions>

    </extensions>

    <client>

    <endpoint address="soap.amq:///myqueue" … more

  • How to configure WCF for MSMQ

    Hello everybody,

    today I want to document how to configure WCF for usage with MSMQ.

    Of course I suppose you know how to add in windows features MSMQ at each instance where WCF service will work.

    So, first of all, let's see how to configure basic interface:

    [ServiceContract(SessionMode = SessionMode.Required)]

    public interface IService1

    {

    [OperationContract(IsOneWay = true)]

    void GetData(int value);

    [OperationContract(IsOneWay = true)]

    void GetDataUsingDataContract(CompositeType composite);

    // TODO: Add your service operations here

    }

    Take not on two features of each method: 

    Each method has IsOneWay set to true in … more