How to set Axon tables into a specific db schema?

Hi all,

i’m using Axon Framework 4.3 with a JpaEventStorageEngine, connected with DB2.
In this db there’s multiple schema, and i’d like to insert Axon tables into a specific one (for example SCHEMA2), but by default Axon point in SCHEMA1 (for example) … and so, how can i specify a schema?

I’v found this documentation https://legacy-docs.axoniq.io/reference-guide/v/2.4/single.html#d5e1087 where i read:

If you only want to change the table name or want to add some extra fields to the table, you can also create a class that extends from DefaultEventEntryStore, and override the createDomainEventEntry and/or createSnapshotEventEntryMethod. This method must return a DomainEventEntry and SnapshotEventEntry instance, respectively. By returning your own subclass of these, you can store different events in different tables, or add extra information in separate columns.

But i don’t find that two methods to override.

Can someone help me?

Thanks :slight_smile:

Hi,

it’s been a while since i’d used JPA with axon, but i had the same thoughts as you back then.
I uploaded my persistence.xml and the orm.xml 's to GitHub:
https://github.com/JohT/snippets/tree/master/axon-customized-jpa

I’m not sure if it still works that way, but maybe its helpful to you…

Best Regards, Johnny.