Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 51 lines (30 sloc) 1.779 kb
3119c55 @videlalvaro new README.md
authored
1 # rmq_msmq #
2
3 This project implements a bridge between Microsoft MQ and RabbitMQ.
4
5 The bridge is implemented using *FSharp* and the [RabbitMQ Client for .Net](http://www.rabbitmq.com/dotnet.html). It has been tested with version 2.4.0
6
7 ## Implementation ##
8
e998acf @videlalvaro improved formatting
authored
9 If you have a MSMQ public queue called `@".\private$\MyTestingQueues"` then you can subscribe to it, receive messages from it and then send them to RabbitMQ to a queue that you decide.
3119c55 @videlalvaro new README.md
authored
10
11 ## Usage ##
12
98d732c @videlalvaro improved usage instructions
authored
13 In your project you will have to add a reference to the System.Messaging dll and to the RabbitMQ client dll. Then you can have a program like this:
14
3119c55 @videlalvaro new README.md
authored
15 module Program
16
17 open System.Messaging
18 open RabbitMQ.Client
19
20 open MSMQ.Util
21 open RabbitMQ.Helper
22 open RabbitMQ.Bridge
23
24 Bridge.msmq2rmq ("guest", "guest", "/", "localhost",
25 AmqpTcpEndpoint.UseDefaultPort,
26 Protocols.SafeLookup("AMQP_0_9"))
27 ("", "ms-test", null)
28 @".\private$\MyTestingQueues"
29
30
31 Here we pass three arguments to Bridge.msmq2rmq:
32
33 - A tuple with (user, password, vhost, host, port, protocol) to use while connecting to RabbitMQ.
34 - A tuple with (exchange, routing_key, basicProperties) used while publishing the message.
35 - The name of the MSMQ Queue.
36
e998acf @videlalvaro improved formatting
authored
37 In this case we are sending the messages to the *unnamed exchange* using the *queue name* as the *routing key*.
3119c55 @videlalvaro new README.md
authored
38
39 If a message with body "quit" is sent to the MSMQ queue, then the Receiver will quit. The messages are expected to be formatted using `BinaryMessageFormatter`.
40
41 ## Disclaimer ##
42
43 Consider this project as alpha. Just an excercise to learn Fsharp and MSMQ. You could use this as a reference for your implementations or simply contribute to this project to make it more robust.
44
45 ## TODO ##
46
47 - Allow importing messages from RabbitMQ to MSMQ
48
49 # LICENSE #
50
51 See LICENSE
Something went wrong with that request. Please try again.