Schema change on Axon tables

Good morning,

I have a question related to the table creations in Axon. Is any way that the schema can be changed? Right now every time it will create the objects in the public schema (postgres) but I need to use another schema.

Richard

For some reason I was trying to force Axon to do this, but I just fixed with point the schema using jpa properties like so:

spring.jpa.properties.hibernate.default_schema=myschema

You could put only axon tables in another schema with a file in src/main/resources/META-INF/orm.xml

<?xml version="1.0" encoding="UTF-8"?>
<entity-mappings
        xmlns="http://java.sun.com/xml/ns/persistence/orm"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
        http://java.sun.com/xml/ns/persistence/orm_2_0.xsd"
        version="2.0">

    <!-- Axon needs these tables -->

    <schema>axon</schema>
    <entity class="org.axonframework.eventsourcing.eventstore.jpa.DomainEventEntry"/>
    <entity class="org.axonframework.eventsourcing.eventstore.jpa.SnapshotEventEntry"/>
    <entity class="org.axonframework.modelling.saga.repository.jpa.AssociationValueEntry"/>
    <entity class="org.axonframework.eventhandling.tokenstore.jpa.TokenEntry"/>
    <entity class="org.axonframework.modelling.saga.repository.jpa.SagaEntry"/>

</entity-mappings>