How can I set hibernate-orm.database.generation and create-schemas in application.yaml

1.7k views Asked by At

I'm new in Quarkus. I am writing config file in yaml, but got stuck because of this config.

In Quarkus doc, I am seeing these config and I need to configure them.

quarkus.hibernate-orm.database.generation=drop-and-create
quarkus.hibernate-orm.database.generation.create-schemas=true

I'm not sure how can I make yaml same ?

quarkus:
  hibernate-orm:
    database:
      generation: drop-and-create # < this one is string and object at the same time...
        create-schemas: true
1

There are 1 answers

0
Davide D'Alto On BEST ANSWER

You can use ~:

quarkus:
  hibernate-orm:
    database:
      generation:
        ~: drop-and-create
        create-schemas: true

You can find more details in the documentation: Configuration key conflicts