I am migrating from MongoDB to Mysql to persist events.
So I simply change the used storage engine :
`
@Resource(lookup = “jdbc/mysqlpool”)
DataSource sqlSource;
…
JdbcEventStorageEngine eventStorage = new JdbcEventStorageEngine(
new DBObjectXStreamSerializer()
null,
null,
connectionProvider,
NoTransactionManager.instance()
);
axonConfiguration = DefaultConfigurer.defaultConfiguration()
.configureEmbeddedEventStore(c -> eventStorage)
…
`
And that’s all (the rest was working well with mongo).
But now I have a error caused by event that can not be persisted :
Command 'xx.xx.XxxxXxxxCommand' resulted in org.axonframework.eventsourcing.eventstore.EventStoreException(An event for aggregate [99999999-b00c-4187-9726-dd3c6db15f9a] at sequence [0] could not be persisted)
This is because the mysql database contains no tables : the schema is not created.
I browsed forums, and it appears that it should be automatically done.
So what is the reason ?
Thanks