What is NServiceBus and what are its top alternatives?
NServiceBus is an Enterprise Service Bus (ESB) for .NET that provides a messaging framework to build distributed systems. Its key features include message routing, pub-sub messaging, message serialization, and support for various messaging transports. However, NServiceBus can be complex to set up and expensive for small projects.
MassTransit: MassTransit is an open-source distributed application framework for .NET that provides a message-based architecture. Key features include support for various messaging transports, fault tolerance, and flexible configuration. Pros include its open-source nature and extensive community support, while cons may include a steeper learning curve compared to NServiceBus.
Rebus: Rebus is a lean service bus implementation for .NET that simplifies communication between applications. Key features include a lightweight design, support for various messaging transports, and extensibility through plugins. Pros include its simplicity and flexibility, while cons may include less comprehensive features compared to NServiceBus.
Brighter: Brighter is a command dispatcher and processor for .NET applications that provides a simple way to implement command-based architectures. Key features include in-process message handling, support for command patterns, and extensibility through decorators. Pros include its lightweight design and ease of use, while cons may include limited support for more complex messaging scenarios compared to NServiceBus.
RawRabbit: RawRabbit is a modern RabbitMQ client library for .NET that simplifies working with RabbitMQ messaging. Key features include support for RabbitMQ messaging, easy-to-use API, and asynchronous message processing. Pros include its focus on RabbitMQ integration and simplicity, while cons may include a narrower focus compared to NServiceBus.
EasyNetQ: EasyNetQ is a simple API for RabbitMQ messaging for .NET applications. Key features include easy-to-use API, support for RabbitMQ messaging, and lightweight design. Pros include its simplicity and ease of use, while cons may include limited features compared to NServiceBus.
Top Alternatives to NServiceBus
- Azure Service Bus
It is a cloud messaging system for connecting apps and devices across public and private clouds. You can depend on it when you need highly-reliable cloud messaging service between applications and services, even when one or more is offline. ...
- RabbitMQ
RabbitMQ gives your applications a common platform to send and receive messages, and your messages a safe place to live until received. ...
- Kafka
Kafka is a distributed, partitioned, replicated commit log service. It provides the functionality of a messaging system, but with a unique design. ...
- Akka
Akka is a toolkit and runtime for building highly concurrent, distributed, and resilient message-driven applications on the JVM. ...
- MassTransit
It is free software/open-source .NET-based Enterprise Service Bus software that helps Microsoft developers route messages over MSMQ, RabbitMQ, TIBCO and ActiveMQ service busses, with native support for MSMQ and RabbitMQ. ...
- MSMQ
This technology enables applications running at different times to communicate across heterogeneous networks and systems that may be temporarily offline. Applications send messages to queues and read messages from queues. ...
- Hangfire
It is an open-source framework that helps you to create, process and manage your background jobs, i.e. operations you don't want to put in your request processing pipeline. It supports all kind of background tasks – short-running and long-running, CPU intensive and I/O intensive, one shot and recurrent. ...
- Apache Camel
An open source Java framework that focuses on making integration easier and more accessible to developers. ...
NServiceBus alternatives & related posts
- Easy Integration with .Net4
- Cloud Native2
- Use while high messaging need1
- Limited features in Basic tier1
- Skills can only be used in Azure - vendor lock-in1
- Lacking in JMS support1
- Observability of messages in the queue is lacking1
related Azure Service Bus posts
Want to get the differences in features and enhancement, pros and cons, and also how to Migrate from IBM MQ to Azure Service Bus.
- It's fast and it works with good metrics/monitoring235
- Ease of configuration80
- I like the admin interface60
- Easy to set-up and start with52
- Durable22
- Standard protocols19
- Intuitive work through python19
- Written primarily in Erlang11
- Simply superb9
- Completeness of messaging patterns7
- Reliable4
- Scales to 1 million messages per second4
- Better than most traditional queue based message broker3
- Distributed3
- Supports MQTT3
- Supports AMQP3
- Clear documentation with different scripting language2
- Better routing system2
- Inubit Integration2
- Great ui2
- High performance2
- Reliability2
- Open-source2
- Runs on Open Telecom Platform2
- Clusterable2
- Delayed messages2
- Supports Streams1
- Supports STOMP1
- Supports JMS1
- Too complicated cluster/HA config and management9
- Needs Erlang runtime. Need ops good with Erlang runtime6
- Configuration must be done first, not by your code5
- Slow4
related RabbitMQ posts
As Sentry runs throughout the day, there are about 50 different offline tasks that we execute—anything from “process this event, pretty please” to “send all of these cool people some emails.” There are some that we execute once a day and some that execute thousands per second.
Managing this variety requires a reliably high-throughput message-passing technology. We use Celery's RabbitMQ implementation, and we stumbled upon a great feature called Federation that allows us to partition our task queue across any number of RabbitMQ servers and gives us the confidence that, if any single server gets backlogged, others will pitch in and distribute some of the backlogged tasks to their consumers.
#MessageQueue
Around the time of their Series A, Pinterest’s stack included Python and Django, with Tornado and Node.js as web servers. Memcached / Membase and Redis handled caching, with RabbitMQ handling queueing. Nginx, HAproxy and Varnish managed static-delivery and load-balancing, with persistent data storage handled by MySQL.
- High-throughput126
- Distributed119
- Scalable92
- High-Performance86
- Durable66
- Publish-Subscribe38
- Simple-to-use19
- Open source18
- Written in Scala and java. Runs on JVM12
- Message broker + Streaming system9
- KSQL4
- Avro schema integration4
- Robust4
- Suport Multiple clients3
- Extremely good parallelism constructs2
- Partioned, replayable log2
- Simple publisher / multi-subscriber model1
- Fun1
- Flexible1
- Non-Java clients are second-class citizens32
- Needs Zookeeper29
- Operational difficulties9
- Terrible Packaging5
related Kafka posts
When I joined NYT there was already broad dissatisfaction with the LAMP (Linux Apache HTTP Server MySQL PHP) Stack and the front end framework, in particular. So, I wasn't passing judgment on it. I mean, LAMP's fine, you can do good work in LAMP. It's a little dated at this point, but it's not ... I didn't want to rip it out for its own sake, but everyone else was like, "We don't like this, it's really inflexible." And I remember from being outside the company when that was called MIT FIVE when it had launched. And been observing it from the outside, and I was like, you guys took so long to do that and you did it so carefully, and yet you're not happy with your decisions. Why is that? That was more the impetus. If we're going to do this again, how are we going to do it in a way that we're gonna get a better result?
So we're moving quickly away from LAMP, I would say. So, right now, the new front end is React based and using Apollo. And we've been in a long, protracted, gradual rollout of the core experiences.
React is now talking to GraphQL as a primary API. There's a Node.js back end, to the front end, which is mainly for server-side rendering, as well.
Behind there, the main repository for the GraphQL server is a big table repository, that we call Bodega because it's a convenience store. And that reads off of a Kafka pipeline.
To provide employees with the critical need of interactive querying, we’ve worked with Presto, an open-source distributed SQL query engine, over the years. Operating Presto at Pinterest’s scale has involved resolving quite a few challenges like, supporting deeply nested and huge thrift schemas, slow/ bad worker detection and remediation, auto-scaling cluster, graceful cluster shutdown and impersonation support for ldap authenticator.
Our infrastructure is built on top of Amazon EC2 and we leverage Amazon S3 for storing our data. This separates compute and storage layers, and allows multiple compute clusters to share the S3 data.
We have hundreds of petabytes of data and tens of thousands of Apache Hive tables. Our Presto clusters are comprised of a fleet of 450 r4.8xl EC2 instances. Presto clusters together have over 100 TBs of memory and 14K vcpu cores. Within Pinterest, we have close to more than 1,000 monthly active users (out of total 1,600+ Pinterest employees) using Presto, who run about 400K queries on these clusters per month.
Each query submitted to Presto cluster is logged to a Kafka topic via Singer. Singer is a logging agent built at Pinterest and we talked about it in a previous post. Each query is logged when it is submitted and when it finishes. When a Presto cluster crashes, we will have query submitted events without corresponding query finished events. These events enable us to capture the effect of cluster crashes over time.
Each Presto cluster at Pinterest has workers on a mix of dedicated AWS EC2 instances and Kubernetes pods. Kubernetes platform provides us with the capability to add and remove workers from a Presto cluster very quickly. The best-case latency on bringing up a new worker on Kubernetes is less than a minute. However, when the Kubernetes cluster itself is out of resources and needs to scale up, it can take up to ten minutes. Some other advantages of deploying on Kubernetes platform is that our Presto deployment becomes agnostic of cloud vendor, instance types, OS, etc.
#BigData #AWS #DataScience #DataEngineering
- Great concurrency model32
- Fast17
- Actor Library12
- Open source10
- Resilient7
- Message driven5
- Scalable5
- Mixing futures with Akka tell is difficult3
- Closing of futures2
- No type safety2
- Very difficult to refactor1
- Typed actors still not stable1
related Akka posts
To solve the problem of scheduling and executing arbitrary tasks in its distributed infrastructure, PagerDuty created an open-source tool called Scheduler. Scheduler is written in Scala and uses Cassandra for task persistence. It also adds Apache Kafka to handle task queuing and partitioning, with Akka to structure the library’s concurrency.
The service’s logic schedules a task by passing it to the Scheduler’s Scala API, which serializes the task metadata and enqueues it into Kafka. Scheduler then consumes the tasks, and posts them to Cassandra to prevent data loss.
I decided to use Akka instead of Kafka streams because I have personal relationships at @Lightbend.
related MassTransit posts
- Easy to learn2
- Cloud not needed1
- Windows dependency1
related MSMQ posts
- Integrated UI dashboard7
- Simple5
- Robust3
- In Memory2
- Simole0
related Hangfire posts
We are a small bank and we have 5 VMware ESXi servers with mainly Windows Server VMs with numerous windows services installed and most of these servers have Microsoft SQL Server and Microsoft IIS installed. Also we have some applications that have application logs (mainly in a db table) and we have a few Hangfire instances and one MQ Series server.
Now the management gave me the task of site reliability (I'm fairly new to this) which means all Windows Services must run 24/7 so I have to know if a service fails to start. All databases must run properly so I have to know locks, Query performance, and any SQL Agent job failures. The same goes for IIS websites/services must be up and running all the time.
In addition to these, I must collect all the Hangfire job failures(which are a lot) as well as general server metrics like CPU, RAM, I/O Disk, Disk sizes, etc.
On top of all these, I must setup alerts via Slack/sms or mail. Now the question which tool or a stack of tools can achieve all that?
- Based on Enterprise Integration Patterns5
- Has over 250 components4
- Free (open source)4
- Highly configurable4
- Open Source3
- Has great community2