Axon 3 / MongoEventStorageEngine + tracking event processor + spring-boot-devtools = ignored messages

first, sorry to spam with (so) many threads, but it seems more manageable to split problems per specific topic. Hey, bounded contexts right?

I’m playing with a MongoEventStorageEngine configuration and a tracking event processor in a spring bootified playground.
Here’s my config:

public MongoEventStorageEngine eventStorageEngine() {
    return new MongoEventStorageEngine(new DBObjectXStreamSerializer(), null, mongoTemplate(), new DocumentPerEventStorageStrategy());

public MongoTemplate mongoTemplate() {
    return new DefaultMongoTemplate(mongo(), "axondb");

public MongoClient mongo() {
    MongoClientURI clientURI = new MongoClientURI("mongodb://xxx:yyy@localhost");
    return new MongoClient(clientURI);

TokenStore tokenStore() {
    return new MongoTokenStore(mongoTemplate(), new DBObjectXStreamSerializer());

public void configureProcessors(EventHandlingConfiguration configuration) { // Let's not go parallel just yet
            c -> c.getComponent(TrackingEventProcessorConfiguration.class,
                () -> TrackingEventProcessorConfiguration.forSingleThreadedProcessing()),
            c -> new SequentialPerAggregatePolicy());

I have a specific @EventHandler:

public void on(MyDomainEvent event) {

This setup actually works, until we add dependency:

runtime "org.springframework.boot:spring-boot-devtools"

Somehow all my MyDomainEvent messages get ignored (message-monitor reportIgnored() is hit). Looks like the payload of the message (MyDomainEvent) does not match with the payloadType in the AnnotatedMessageHandlingMember (which is actually the same - but different classloaders?). With subscribing event processors it works just fine.

Any ideas?


Hi developer-x,

We have heard this issue numerous times and have it on our backlog in several formats. Our assumption is that there are issue with what Axon does with ClassLoaders and what the spring-boot devtools do with regards to the ClassLoader.

The simplest recommendation I can give you is to not use the spring-boot-devtools dependency until the aforementioned issue has been resolved, although I assume you have already figured that out.

Hence, I am sorry not to give your a more thorough solution at this point.


Thanks Steven for the confirmation. I found several other threads referring to the same problem indeed. So for the time being we’ll apply the suggested workaround of not adding the spring-boot-devtools dependency :-).