I'm trying to connect my axon application to https://console.axoniq.io/ I do not use Spring because I have a quarkus-application. So in my pom.xml I have the following dependency:
<dependency>
<groupId>io.axoniq.console</groupId>
<artifactId>console-framework-client</artifactId>
<version>1.4.0</version>
</dependency>
In my Axon-Configuration class I pasted the code what I found in the instruction of my axoniq-space:
Configurer configurer = DefaultConfigurer.defaultConfiguration() //
.configureAggregate(MyAggregate.class)
.configureSerializer(config -> commmandSerializerForAxonServer());
AxoniqConsoleConfigurerModule
.builder(
"95d0cfd4-0",
"f3094e246fd84ae6a9e4cde5d12fe2f7",
"MyAxonProject"
)
.build()
.configureModule(configurer);
Configuration configuration = configurer.start();
But when I run my application as soon as the configuration is loaded I get the following Exception:
Caused by: java.lang.NullPointerException: Parameter specified as non-null is null: method io.axoniq.console.framework.eventprocessor.EventProcessorManager.<init>, parameter transactionManager
at io.axoniq.console.framework.eventprocessor.EventProcessorManager.<init>(EventProcessorManager.kt)
at io.axoniq.console.framework.AxoniqConsoleConfigurerModule.lambda$configureModule$3(AxoniqConsoleConfigurerModule.java:135)
at org.axonframework.config.Component.get(Component.java:85)
at org.axonframework.config.DefaultConfigurer$ConfigurationImpl.getComponent(DefaultConfigurer.java:1134)
at org.axonframework.config.Configuration.getComponent(Configuration.java:278)
at io.axoniq.console.framework.AxoniqConsoleConfigurerModule.lambda$configureModule$6(AxoniqConsoleConfigurerModule.java:146)
at org.axonframework.config.Component.get(Component.java:85)
at org.axonframework.config.DefaultConfigurer$ConfigurationImpl.getComponent(DefaultConfigurer.java:1134)
at org.axonframework.config.Configuration.getComponent(Configuration.java:278)
at io.axoniq.console.framework.AxoniqConsoleConfigurerModule.lambda$configureModule$14(AxoniqConsoleConfigurerModule.java:209)
at org.axonframework.config.DefaultConfigurer.lambda$invokeInitHandlers$57(DefaultConfigurer.java:994)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
at org.axonframework.config.DefaultConfigurer.invokeInitHandlers(DefaultConfigurer.java:994)
at org.axonframework.config.DefaultConfigurer.buildConfiguration(DefaultConfigurer.java:955)
at org.axonframework.config.Configurer.start(Configurer.java:618)
at at.axon.configuration.AxonConfigurer.configure(AxonConfigurer.java:32)
The application do also not appear in Axoniq-Console as well. I didn't find any example on the internet. So what am I doing wrong?
Thanks for marking this, @Veilchen4ever. You have actually uncovered a minor bug here.
Throughout Axon Framework, if a component isn't present, a sensible default is set. The
console-framework-clientwas simply lacking that default logic. There's a PR out, which is already approved, to set this default.Even better, it is already released, under version 1.4.1.