ActiveMQ vs Apollo vs Kafka [closed]
Asked Answered
D

4

71

I don't have any previous experience with *MQs and I'm looking to build knowledge on JMS and message queues in general. That way, I wonder whether I should start with ActiveMQ or just "ignore" it altogether and start by teaching myself Apollo. Is Apollo as feature-complete as ActiveMQ? Does it implement JMS 2.0 (I see that ActiveMQ got stuck with 1.1)? Will I be missing something really important?

Also, how does Kafka compare to these two solutions?

Duodiode answered 27/12, 2014 at 11:51 Comment(1)
Also check out the new ActiveMQ Artemis: activemq.apache.org/artemisXavier
D
106

Apache ActiveMQ is a great workhorse full of features and nice stuff. It's not the fastest MQ software around but fast enough for most use cases. Among features are flexible clustring, fail-over, integrations with different application servers, security etc.

Apache Apollo is an attempt to write a new core for ActiveMQ to cope with a large amount of clients and messages. It does not have all nice and convenient feature of ActiveMQ but scales a lot better. Apache Apollo is a really fast MQ implementation when you give it a large multi-core server and thousands of concurrent connections. It has a nice, simple UI, but is not a "one-size-fits-all" solution.

It seems that there is an attempt ongoing to merge a number of ActiveMQ features with HornetQ under the name ActiveMQ Artemis. HornetQ has JMS2.0 support, so my humble guess is that it's likely to appear in ActiveMQ 6.x.

JIRA, Github

Kafka is a different beast. It's a very simple message broker intended to scale persistent publish subscribe (topics) as fast as possible over multiple servers. For small-medium sized deployments, Kafka is probably not the best option. It also has it's way to do things to achieve the high throughput, so you have to trade a lot in terms of flexibility to get high distributed throughput. If you are new to the area of MQ and brokers, I guess Kafka is overkill. On the other hand - if you have a decent sized server cluster and wonder how to push as many messages as possible through it - give Kafka a spin!

Dock answered 27/12, 2014 at 18:4 Comment(3)
Thanks! I guess that Apache Apollo is the way to go then in my case.Duodiode
If I (partially) understand relation ActiveMQ to Apollo (newer implementation based on previous experience etc), what is general vision (goal, motivation) of Artemis?Ethylethylate
Apollo failed, in a way, to become the new non-blocking core of AMQ as there was a lack of Scala programmers dedicated to that effort. The vision with Artemis, as I see it - and I am not an official of ActiveMQ - is to do what Apollo failed to do. The chances are probably greater with a battle tested product (HornetQ), written in a main stream language (Java) than writing from scratch. Both aim(ed) for the same target - non blocking ActiveMQ to support new demands from IoT and mobility applications, among other thingsDock
B
29

This is an older question but I'll provide a more modern answer here.

  • The Apollo project is unofficially dead and they suggest Artemis is the new hotness. (link) The (seemingly) stalled development of Apollo does not give me confidence in Artemis's future.
  • My experience is similar to Petter's answer in that ActiveMQ is feature rich and capable. However, it seems as if every release fixes random crashes and memory leaks and this does not inspire confidence. It's stable for my project (which uses clustering) but we have seen weird behavior and crashes in the broker over the last dozen or so releases (currently using 5.14.3)
  • I have not used RabbitMQ (my current project is committed to ActiveMQ) but I will be trying it out on the next project that needs a messaging bus. Not having the kitchen sink of features to support will hopefully mean it is more stable.

EDIT: The 2.3.0 Apache Artemis release happened ~Sept 5 2017. So it does seem to be progressing as of now. But (link) changelog still seems too scary.

Blythe answered 23/8, 2016 at 16:34 Comment(1)
FWIW, development on ActiveMQ Artemis is much more active now than Apollo's ever was. In fact, the number of contributors to Artemis is already greater than that of ActiveMQ proper, at least according to GitHub. Artemis has also already been commercialized as part of Red Hat JBoss AMQ 7.Macrospore
P
6

Apache Kafka can be characterized as a "Distributed Streaming Platform" where as ActiveMQ, a MOM, (messaging oriented middleware) is a "General Purpose message broker".

Kafka does one thing, and one thing really well: in a publish/subscribe (pub/sub) architecture, messages are written to topics (logs distributed by partition), which consumers then consume from by offset. Kafka, which is built for the cloud, with very high throughput in mind, focuses on this, and these days is the go-to for asynchronous messaging.

ActiveMQ supports both pub/sub and point-to-point semantics. In the latter, a queue handles single messages between a single producer and a specific consumer. This, like pub/sub, is asynchronous, but works slightly differently: if a consumer gets a message on the queue but fails to acknowledge it, the message is then sent to another consumer. ActiveMQ also supports supports several messaging protocols, including AMQP, STOMP, JMS, CAMEL and MQTT.

While Apache Kafka may be the go-to for simple async communication; ActiveMQ seems to be preferred by some for more complicated routing patterns, like enterprise patterns, however, many argue that Kafka is an improvement over ActiveMQ, for reasons such as higher throughput, more efficient management of partitions for logs/topics, and finer-grained ACLs for consumers consuming a topic.

Phlegmy answered 17/4, 2019 at 21:21 Comment(0)
C
3

I amde a performance benchmark of ActiveMQ, Apollo, HornetQ under non persistent scenario and persistent scenario, I think it will helpful for you to choose which one should be used, the link as shown below: http://hiramchirino.com/jms-benchmark/ubuntu-2600k/index.html

Chivalrous answered 21/3, 2017 at 10:3 Comment(1)
Here's a more recent benchmark conducted with a wider variety of messaging solutions: softwaremill.com/mqperf. Apollo was not included since it is no longer under active development, but ActiveMQ 5.x and ActiveMQ Artemis are included.Macrospore

© 2022 - 2024 — McMap. All rights reserved.