DDL scripts

66 views
Skip to first unread message

Rene Svetina

unread,
Dec 5, 2017, 7:43:28 AM12/5/17
to Axon Framework Users
Hello,

I just started using Axon and I am curious where can I find DDL scripts for ALL the tables that Axon needs? I found DDL statements in code but it is a pain to extract those statements and I really do not know which tables are needed.

I found:
 - Event table
 - Token table
 - Saga table

Are there more?

Steven van Beelen

unread,
Dec 6, 2017, 4:40:54 AM12/6/17
to axonfr...@googlegroups.com
Hi Rene,

You probably missed the SnapshotEntry (to snapshot your aggregates) and the AssociationValueEntry (associates a Saga instance to event keys) tables.
So that makes 5 Axon Framework tables in total.

By the way, I typically let those tables be created by the Framework itself.
Not sure why we're not providing direct DDL scripts, hope Allard could give some feedback on that.

Hope this helps!

Cheers,

Steven

--
You received this message because you are subscribed to the Google Groups "Axon Framework Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to axonframewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Rene Svetina

unread,
Dec 6, 2017, 2:17:05 PM12/6/17
to Axon Framework Users
Yes I found other tables after I posted the question. But thanks.

For now I used Framework to generate tables and thed generate DDL from database. 

Allard Buijze

unread,
Dec 11, 2017, 5:44:02 AM12/11/17
to axonfr...@googlegroups.com
Hi Rene,

the reason we don't have the DDL script yet, is because when we do provide them, we want them to be optimized correctly for that type of database. We just didn't find the time (priority) yet. Until then, having your ORM framework (like Hibernate) generate the tables for you is the easiest way forward. You can then generate the DDL scripts from the tables. I would recommend optimizing some of the tables first and giving indices proper names, for easier debugging.

Cheers,

Allard

Op wo 6 dec. 2017 om 20:17 schreef Rene Svetina <rene.s...@gmail.com>:
--

Prem C

unread,
Dec 16, 2017, 5:58:55 AM12/16/17
to Axon Framework Users
I know I'm a bit late joining this conversation. We use liquibase to programmatically create the schema. Here is a project where we've done this: https://github.com/project-tungsten/tungsten-reference-apps/tree/master/reference-domain-service/src/main/resources/db

Hope you find it useful.
Reply all
Reply to author
Forward
0 new messages