Skip to content

Axon Framework logo

Build modern event-driven systems with AxonIQ technology
Learn more at our website »

Axon Framework · Axon Server · AxonIQ Console


Axon Framework logo

The Axon Framework is an open source framework that's 100% Java and enables developers to build scalable and maintainable applications using a message-driven approach. It simplifies the complexities of developing distributed systems by providing a structured way to handle commands, events, and queries within your application. If you're not familiar with the Event Sourcing pattern, you can learn more about it on our website.

At its core, the Axon Framework encourages an architecture where components communicate through messages, which promotes loose coupling and increases flexibility. This messaging system allows different parts of your application to interact without needing to know the internal workings of each other, making your system more modular and easier to manage. If you already use tools and technologies that enable your applications to utilize a pub/sub pattern, then you already understand the basics of message driven and event driven architectures.

The Axon Framework further enhances your applications and services by enabling you to support Event Sourcing, a powerful architectural pattern where state changes are recorded as a sequence of events. Why is this important? Well, instead of just storing the current state in a traditional database, every change is logged, providing a complete history of how the data arrived at its current form. This can be incredibly useful for auditing, debugging, and even recreating past states of your application when necessary.

For JVM-based developers working with microservices, the Axon Framework offers tools to manage the complexities inherent in distributed systems. By leveraging its messaging and event-handling capabilities, you can build applications that are not only scalable and robust but also easier to extend and maintain over time.

How Can I Get Started with the Axon Framework?

We highly recommend all developers to get started by going to the AxonIQ Documentation Portal, which provides links to our tutorials, guides, and reference documentation.

Furthermore, below are several other helpful resources:



Axon Server logo

The AxonIQ Console is a management tool designed to maximize the effectiveness of applications developed with Axon Framework and supported through Axon Server. It facilitates near-zero configuration and provides a single platform for insight, management, control, and reporting of your application infrastructure.

Axon Framework logo

How to Get Started with AxonIQ Console

Numerous resources can help you on your journey in using Axon Framework. A good starting point is AxonIQ Documentation Portal, which provides links to our tutorials, guides, and reference documentation.

Furthermore, below are several other helpful resources:



Axon Server logo

For developers who are serious about Event Sourcing, we offer the Axon Server. The Axon Server is designed to simplify the development of event-driven applications by acting as both an Event Store and a message router. Therefore, it is as a central hub for managing and distributing events, commands, and queries within your application ecosystem. By handling these critical aspects, Axon Server allows developers to focus more on business logic rather than the complexities of communication and data storage in distributed systems.

When developing microservices, coordinating interactions between multiple services can become quite challenging. This is especially the case as the system scales to handle more users or additional features requested by customers and stakeholders. Axon Server addresses this by providing seamless and scalable message routing between services. It ensures that messages reach their intended targets and that events are efficiently broadcasted to all interested parties.

In addition to functioning as a message router, Axon Server enables apps and microservices to be Event Sourced. This means that all changes in the application state are stored as a sequence of events. This allows the application to reconstruct its state at any point in time by replaying these events. For developers unfamiliar with event sourcing, this means you have a complete history of what happened in your system, which is invaluable for debugging, auditing, and understanding complex behaviors. This is a revolutionary approach to traditional application development, however the architectural pattern is proven to create better and more resilient software systems.

By incorporating Axon Server into your applications, especially those built with microservices, you gain a robust platform for managing the flow of data and commands across your system. It abstracts the complexities of message handling and event storage, enabling you to build scalable, maintainable, and high-performing applications. This allows you to deliver features faster and adapt more readily to changing business requirements.

How Can I Get Started with Axon Server?

If you're getting started with the Axon Server, then we recommend that you go to the AxonIQ Documentation Portal, which provides links to our tutorials, guides, and reference documentation.

Furthermore, below are several other helpful resources:

Extensions

Where Axon Framework contains the core functionality for event-driven application construction, the extensions add valuable integrations with other tools and languages to enhance Axon's capabilities. The extensions are intentionally split off from the main framework to not over encumber the user with unused functionality and obstruct the release cycles of the separate repositories.

The functionality of the extensions ranges from event streaming integrations with AMQP and Kafka, database tooling like Mongo, and language-specific integrations as with the Kotlin extension. For more details about each extension, we refer to the subsections below.

Contents

AMQP

The AMQP Extension repository provides support for the Advanced Message Queuing Protocol (AMQP).

Users can add this extension to, for example, include a RabbitMQ integration with their Axon Framework application. Setting up this integration allows you to publish Axon events to an AMQP exchange. Events can also be read from exchanges and handled by event processors, providing means of integrating with other services.

In doing so, you would enable (micro)service communication through event streaming. Or, you can attach a (third-party) application with your Axon Framework application, communicating through AMQP.

You should regard this extension as a partial replacement of Axon Server as, compared to Axon Server, it only covers event streaming.

Please read the AMQP section of the documentation for more information about this extension.

JGroups

The JGroups Extension repository enables integration with JGroups.

You can use this extension to enable command routing in a distributed environment. As command routing differs from, for example, load balancing REST operation, it is highly recommended to use a distributed command routing solution whenever you have several applications and/or application instances that need to communicate with one another.

The extension achieves this by implementing the CommandRouter and CommandBusConnector, consolidated in the JGroupsConnector. This connector provides the service discovery and message routing required to pass CommandMessages from one application (instance) to another.

You should regard this extension as a partial replacement of Axon Server as, compared to Axon Server, it only covers command routing.

Please read the JGroups section of the documentation for more information about this extension.

JobRunr Pro

The JobRunr Pro Extension repository provides support for the "pro" edition of JobRunr.

Users can benefit from this extension whenever they have:

  1. Acquired JobRunr Pro, and
  2. want to use Axon's deadline management functionality.

We constructed this extension as some feature on the DeadlineManager API cannot be supported with the free edition of JobRunr.

Please read the Jobrunr Pro section of the documentation for more information about this extension.

Kafka

The Kafka Extension repository enables integration with Kafka.

Setting up a Kafka integration with your Axon Framework applications allows you to:

  1. Publish Axon Event Messages onto one or more Kafka topics, and
  2. to read Kafka Consumer Records converted to Axon Event Messages into your @EventHandler annotated methods.

In doing so, you would enable (micro)service communication through event streaming. Or, you can attach a (third-party) application with your Axon Framework application, communicating through Kafka.

Note that the Axon Framework team does not intend to support Event Sourcing through the Kafka Extension. Although there are Kafka-focused articles explaining how to achieve this, we find this a suboptimal solution leading to predicaments in the future. We thus suggest you choose Axon Server, an RDBMS solution or the MongoDB Extension to store your events and subsequently support event sourcing.

You should regard this extension as a partial replacement of Axon Server as, compared to Axon Server, it only covers event streaming.

Please read the Kafka section of the documentation for more information about this extension.

Kotlin

The Kotlin Extension repository eases Axon Framework development for Kotlin-based applications.

You can use this extension to relieve some of the "awkwardness" of the Axon Framework API when using Kotlin to build your application(s). It does so by providing reified methods of several of Axon's infrastructure components, like the command and query gateway, upcasters, and the test fixtures.

Please read the Kotlin section of the documentation for more information about this extension.

MongoDB

The MongoDB Extension repository enables MongoDB as a storage solution throughout the framework.

Users can set this extension whenever they want to use MongoDB to store:

Especially when you store Query Models or inside a MongoDB collection, we recommend you keep the tracking tokens of the streaming processor inside MongoDB as well. By doing so, you ascertain that the framework uses a single transaction to update the model and token.

The same logic applies to Sagas that are backed by streaming processors and stored in MongoDB; storing the tokens next to the saga instances makes the application more robust.

Note that although you can use this extension to adjust MongoDB into an event store, we do not necessarily recommend this. During the lifecycle of this extension, we have noticed predicaments with how MongoDB behaves, causing the event store to act suboptimal from a performance perspective. We thus recommend either Axon Server (the highest level of performance for event storage) or an RDBMS of choice instead.

You should regard this extension as a partial replacement of Axon Server as, compared to Axon Server, it only covers event storage.

Please read the MongoDB section of the documentation for more information about this extension.

Multitenancy

The Multitenancy Extension repository provides integrated support for multitenancy to your Axon Framework application.

By adding this extension to your Axon Framework application(s), you receive multi-tenant versions of all the infrastructure components the framework provides. In doing so, you can run a single instance of an application but serve many of your tenants in one go. Interfaces like the CommandBus, EventProcessor, and SequencedDeadLetterQueue are implemented by this extension to delegate tenant-specific tasks to concrete implementations of these components.

If you combine Axon Framework and the Multitenancy Extension with Axon Server, the multitenancy experience of your app(s) is seamless. The extension achieves this by utilizing Axon Server's multi-context behavior to dynamically create new tenants (read: a context per tenant) whenever you register them. It is usable without Axon Server, but you will be inclined to implement factories for the infrastructure components yourself.

Please read the Multitenancy section of the documentation for more information about this extension.

Reactor

The Reactor Extension repository provides Axon Framework infrastructure components using the Project Reactor API.

You can add this extension to your Axon Framework project to use results like Mono and Flux on framework components. It provides Reactor versions of Axon's gateways, allowing you to leverage the reactive API on the edge of your Axon Framework application.

Please read the Reactor section of the documentation for more information about this extension.

Spring AoT

The Spring AoT Extension repository enables integration with the Spring Boot's ahead of time processing.

This extension allows you to compile to a native image whenever you combine Axon Framework with Spring Boot.

Please read the Spring AoT section of the documentation for more information about this extension.

Spring Cloud

The Spring Cloud Extension repository enables integration with Spring Cloud.

You can use this extension to enable command routing in a distributed environment. As command routing differs from, for example, load balancing REST operation, it is highly recommended to use a distributed command routing solution whenever you have several applications and/or application instances that need to communicate with one another.

The extension achieves this by implementing the CommandRouter and CommandBusConnector, consolidated in the SpringCloudeCommandRouter and SpringHttpCommandBusConnector, respectively. This connector provides the service discovery and message routing required to pass CommandMessages from one application (instance) to another.

Since the implementation uses the Spring Cloud discovery interfaces to perform the service discovery, you are able to choose a multitude of implementations to enable distributed command routing. You can, for example, use implementation like Netflix, Consul, Zookeeper, Kubernetes, and many more.

You should regard this extension as a partial replacement of Axon Server as, compared to Axon Server, it only covers command routing.

Please read the Spring Cloud section of the documentation for more information about this extension.

Tracing

The Tracing Extension repository enables integration with Open Tracing.

When using this extension, you will replace the Command- and QueryGateway with implementations that attach span information to your Messages. Furthermore, when handling a Message, a dedicated MessageHandlerInterceptor ensures the span is populated on the overall trace.

Although this is valuable, it is essential to mention that the Open Tracing implementation has been archived in favor of Open Telemetry. Furthermore, as of Axon Framework version 4.6.0, the framework provides native support for Open Telemetry.

We thus recommend that you use the integrated tracing support whenever you are on Axon Framework version 4.6 or above.

Nonetheless, we still maintain and update the Tracing Extension for the time being. As such, you can be certain the extension still works as intended.

Please read the Tracing section of the documentation for more information about this extension.



Bill of Materials

The Bill of Materials repository of Axon Framework is a dedicated dependency providing compatible versions of the framework and extensions. Hence, by adding axon-bom to your dependency management system, you ensure the compatibility of Axon's dependencies. As such, we recommend you use this dependency whenever you combine Axon Framework with any of the extensions.

IntelliJ IDEA Plugin

The Axon Framework IntelliJ Plugin is a plugin you can add when using IntelliJ IDEA. Including this plugin eases your developer experience of Axon Framework 4.x-based applications.

Some of the features this plugin adds to IntelliJ are:

  • Line markers to visualize messages
  • Axon Framework-specific code structure inspections
  • Easy access to the documentation

Please read the README of the IdeaPlugin project to learn more about this plugin.

Data Protection Module

As you may know, Event Sourcing dictates that you never remove or update events. With the introduction of Data Protection Laws like GDPR, developers using Event Sourcing in their applications are thus faced with a predicament. A predicament you are required to resolve by law.

As one of Axon Framework's pillars is to enable Event Sourcing, we are inclined to provide a solution. As such, AxonIQ constructed the Data Protection Module in response to these new requirements.

The Data Protection Module is a Java library providing the tooling to mark specific data inside events as "personally identifiable information" (PII for short). Then when you store the event or send it over a network, you can encrypt the PII within the event to protect it. From there, you can choose a preferred key management system, with options like relation databases, hardware security modules, and HashiCorp Vault.

In combination with Axon Framework, you can implement the described behavior seamlessly by using dedicated annotations and a custom Serializer as provided by the Data Protection Module. If you require more information about the Data Protection Module, be sure to reach out.

Pinned Loading

  1. AxonFramework AxonFramework Public

    Framework for Evolutionary Message-Driven Microservices on the JVM

    Java 3.3k 796

Repositories

Showing 10 of 27 repositories
  • extension-multitenancy Public

    Axon Framework extension providing handles to support multi tenancy with distinct buses and stores per tenant.

    AxonFramework/extension-multitenancy’s past year of commit activity
    Java 11 Apache-2.0 2 4 0 Updated Dec 10, 2024
  • extension-mongo Public

    Axon Framework extension for Mongo integration as a Dead Letter, Event, Saga and Tracking Token storage solution.

    AxonFramework/extension-mongo’s past year of commit activity
    Java 25 Apache-2.0 16 3 0 Updated Dec 10, 2024
  • extension-tracing Public

    Axon Framework extension to provide tracing support for messages using the OpenTracing API.

    AxonFramework/extension-tracing’s past year of commit activity
    Java 13 Apache-2.0 16 4 1 Updated Dec 10, 2024
  • extension-reactor Public

    Axon Framework extension for integration with Project Reactor, allowing an extended reactive API.

    AxonFramework/extension-reactor’s past year of commit activity
    Java 28 Apache-2.0 6 6 1 Updated Dec 10, 2024
  • extension-springcloud-sample Public

    Sample project showcasing Axon's Spring Cloud extension

    AxonFramework/extension-springcloud-sample’s past year of commit activity
    Kotlin 11 Apache-2.0 4 0 0 Updated Dec 10, 2024
  • axon-bom Public

    Axon Bill of Materials (BOM) - provides managed dependencies for all Axon artifacts

    AxonFramework/axon-bom’s past year of commit activity
    15 Apache-2.0 6 1 1 Updated Dec 10, 2024
  • AxonFramework Public

    Framework for Evolutionary Message-Driven Microservices on the JVM

    AxonFramework/AxonFramework’s past year of commit activity
    Java 3,347 Apache-2.0 796 141 10 Updated Dec 10, 2024
  • IdeaPlugin Public

    An IntelliJ IDEA plugin for Axon Framework

    AxonFramework/IdeaPlugin’s past year of commit activity
    Kotlin 34 Apache-2.0 21 13 11 Updated Dec 9, 2024
  • extension-amqp Public

    Axon Framework extension for AMQP integration to publish and handle Event messages.

    AxonFramework/extension-amqp’s past year of commit activity
    Java 8 Apache-2.0 8 0 0 Updated Dec 8, 2024
  • extension-cosmosdb Public

    Axon Framework extension for Azure Cosmos DB integration.

    AxonFramework/extension-cosmosdb’s past year of commit activity
    Java 0 Apache-2.0 0 1 1 Updated Dec 8, 2024