Search Tutorials

Top ActiveMQ frequently asked interview questions | JavaInUse

ActiveMQ Interview Questions

In this post we will look at ActiveMQ Interview questions. Examples are provided with explanation.

Q: What is Activemq?
Apache ActiveMQ is an open source message broker written in Java together with a full Java Message Service (JMS) client. It provides "Enterprise Features" which in this case means fostering the communication from more than one client or server.

Q: What is use of Activemq instead of other options like database?
Activemq is used to reliably communicate between two distributed processes. It can store messages in a database to communicate between to processes, but as soon as the message is received you'd have to delete the message. That means a row insert and delete for each message. When you try to scale that up communicating thousands of messages per second, databases tend to fall over.
Message oriented middleware like ActiveMQ on the other hand are build to handle those use cases. They asume that messages in a healthy system will be deleted very quickly and can do optimizations to avoid the overhead. It can also push messages to consumers instead of a consumer having to poll for new message by doing a SQL query. This further reduces the latency involved in processing new messages being sent into the system.

Q: What is JMS??
Java Message Service (JMS) is an application program interface (API) from Sun Microsystems that supports the formal communication known as messaging between computers in a network. Sun's JMS provides a common interface to standard messaging protocols and also to special messaging services in support of Java programs. ActiveMQ is based on JMS.

Q: How to get started with JMS?
Getting Started with JMS Messaging- ActiveMQ Hello World Tutorial

Q: How to integrate ActiveMQ with Apache Camel?
Integrate Apache Camel and ActiveMQ

Q: How to integrate ActiveMQ with Spring Boot?
Spring Boot + ActiveMQ Hello world Example

Q: What is KahaDB?
KahaDB is a file based persistence database that is local to the message broker that is using it. It has been optimized for fast persistence. It is the the default storage mechanism since ActiveMQ 5.4. KahaDB uses less file descriptors and provides faster recovery than its predecessor, the AMQ Message Store.

Q: What is LevelDB?
LevelDB is a slightly faster index than KahaDB and can provide somewhat better performance numbers. In later releases of ActiveMQ the LevelDB store also supports replication.

Q: What is Message-oriented middleware?
Message-oriented middleware (MOM) is software or hardware infrastructure supporting sending and receiving messages between distributed systems. MOM allows application modules to be distributed over heterogeneous platforms and reduces the complexity of developing applications that span multiple operating systems and network protocols. The middleware creates a distributed communications layer that insulates the application developer from the details of the various operating systems and network interfaces.

See Also

Spring Batch Interview Questions Apache Camel Interview Questions JBoss Fuse Interview Questions Drools Interview Questions Java 8 Interview Questions