Qualified name of message

Hi!

We are migrating to AxonFramework 5. We implemented a interceptor to wrap exceptions in a CommandExecutionException.

In this interceptor I wanted to add the qualified name of the command to the error message.

My first try was to message.getPayloadType(), but the result was “class [B…”.

Then I tried payload().getClass(), but the result was the same.

Next I tried message.type().qualifiedName().name() and fullName(). The result was at.meks.quarkiverse.axon.shared.model.RedeemCardCommand.

But the class name of my command is at.meks.quarkiverse.axon.shared.model.Api$RedeemCardCommand.

As you can see, the Command Class is an inner class of API. I am wondering if this is a bug in the framework.

You can find the sources here: GitHub - meks77/quarkus-axonframework-extension at axon-51-upgrade · GitHub

The interceptor Implementation can be found in at.meks.quarkiverse.axon.runtime.defaults.InterceptorConfigurer#handleExceptionInCommandHandling.

The inner class missing from the QualifiedName/MessageType is indeed a bug. It will be addressed in Align `QualifiedName#(Class)` outcome with annotated approach for nested classes by MateuszNaKodach · Pull Request #4630 · AxonIQ/AxonFramework · GitHub, which will be part of 5.1.2 of Axon Framework!

many thanks for the quick response