thrift/contrib/Rebus
2021-02-11 23:17:45 +01:00
..
Properties Version number aligned to 0.15.0 2021-02-11 23:17:45 +01:00
ServiceImpl THRIFT-2383 contrib: sample for connecting Thrift with Rebus 2014-03-07 19:42:28 +01:00
App.config THRIFT-2383 contrib: sample for connecting Thrift with Rebus 2014-03-07 19:42:28 +01:00
Program.cs THRIFT-2383 contrib: sample for connecting Thrift with Rebus 2014-03-07 19:42:28 +01:00
README.md THRIFT-4982 Remove deprecated C# bindings from the code base 2020-02-28 19:18:34 +01:00
RebusSample.csproj THRIFT-2383 contrib: sample for connecting Thrift with Rebus 2014-03-07 19:42:28 +01:00
RebusSample.sln THRIFT-2383 contrib: sample for connecting Thrift with Rebus 2014-03-07 19:42:28 +01:00
sample.thrift THRIFT-2768: Whitespace Fixup 2014-10-03 20:30:38 +02:00

Sample code for the combination of Thrift with Rebus.

Rebus is a .NET service bus, similar to NServiceBus, but more lightweight. It ihas been mainly written by Mogens Heller Grabe and is currently hosted on GitHub (https://github.com/rebus-org/Rebus)

As with all ServiceBus or MQ scenarios, due to the highly asynchronous operations it is recommended to do all calls as "oneway void" calls.

The configuration can be done via App.Config, via code or even mixed from both locations. Refer to the Rebus documentation for further details. For this example, since we are effectively implementing two queue listeners in only one single process, we do configuration of incoming and error queues in the code.

If you want to communicate with non-NET languages, you may need a customized serializer as well, in order to override Rebus' default wire format. Please refer to the Rebus docs on how to do that (it's not that hard, really).

Additional requirements:

  • RabbitMQ .NET client (see nuget)

Deprecation notice: Csharp is not a supported Apache Thrift target anymore. Instead netstd is the recommended replacement. This code is left "as is" for educational purposes unless someone converts it to netstd