Quarkus - Liquibase - Deployment

Liquibase extension for Quarkus

Лицензия

Лицензия

Категории

Категории

Quarkus Контейнер Микросервисы Liquibase Данные Базы данных
Группа

Группа

com.konnectkode
Идентификатор

Идентификатор

quarkus-liquibase-deployment
Последняя версия

Последняя версия

1.0.0.CR2
Дата

Дата

Тип

Тип

jar
Описание

Описание

Quarkus - Liquibase - Deployment
Liquibase extension for Quarkus

Скачать quarkus-liquibase-deployment

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/com.konnectkode/quarkus-liquibase-deployment/ -->
<dependency>
    <groupId>com.konnectkode</groupId>
    <artifactId>quarkus-liquibase-deployment</artifactId>
    <version>1.0.0.CR2</version>
</dependency>
// https://jarcasting.com/artifacts/com.konnectkode/quarkus-liquibase-deployment/
implementation 'com.konnectkode:quarkus-liquibase-deployment:1.0.0.CR2'
// https://jarcasting.com/artifacts/com.konnectkode/quarkus-liquibase-deployment/
implementation ("com.konnectkode:quarkus-liquibase-deployment:1.0.0.CR2")
'com.konnectkode:quarkus-liquibase-deployment:jar:1.0.0.CR2'
<dependency org="com.konnectkode" name="quarkus-liquibase-deployment" rev="1.0.0.CR2">
  <artifact name="quarkus-liquibase-deployment" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.konnectkode', module='quarkus-liquibase-deployment', version='1.0.0.CR2')
)
libraryDependencies += "com.konnectkode" % "quarkus-liquibase-deployment" % "1.0.0.CR2"
[com.konnectkode/quarkus-liquibase-deployment "1.0.0.CR2"]

Зависимости

compile (4)

Идентификатор библиотеки Тип Версия
io.quarkus : quarkus-core-deployment jar
io.quarkus : quarkus-arc-deployment jar
io.quarkus : quarkus-agroal-deployment jar
com.konnectkode : quarkus-liquibase jar 1.0.0.CR2

test (2)

Идентификатор библиотеки Тип Версия
io.quarkus : quarkus-junit5-internal jar
io.quarkus : quarkus-test-h2 jar

Модули Проекта

Данный проект не имеет модулей.

Quarkus-Liquibase - A extension Liquibase extension for quarkus framework

CircleCI Codecov Maven Central GitHub

Using Quarkus Liquibase

OBS: THIS LIBRARY DOES NOT SUPPORT NATIVE IMAGE

Setting up support for Liquibase

To start using Liquibase with your project, you just need to:

  • add your migrations to the src/main/resources/db/migration
  • activate the migrate-at-start option to migrate the schema automatically or inject the Liquibase object and run your migration

In your pom.xml, add the following dependencies:

  • the Liquibase extension
  • your JDBC driver extension
<dependencies>
    <!-- Liquibase specific dependencies -->
    <dependency>
        <groupId>com.konnectkode</groupId>
        <artifactId>quarkus-liquibase</artifactId>
    </dependency>

    <!-- JDBC driver dependencies -->
    <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-jdbc-postgresql</artifactId>
    </dependency>
</dependencies>

Liquibase support relies on the Quarkus default datasource config, you must add the default datasource properties to the application.properties file in order to allow Liquibase to manage the schema. Also, you can customize the Liquibase behaviour by using the following properties:

quarkus.liquibase.migrate-at-start

true to execute Liquibase automatically when the application starts, false otherwise. default: false

quarkus.liquibase.changelog

Changelog file path that contains the liquibase migrations
default: classpath:db/migration

quarkus.liquibase.default-schema

The name of the default schema. By default the liquibase tables are placed in the default schema for the connection provided by the datasource. When the quarkus.liquibase.default-schema property is set, the tables are placed in the provided schema.
default: <none>

quarkus.liquibase.contexts

Liquibase supports contexts a comma-separated list of contexts that works like profiles (Liquibase Contexts).
Default: <none>

The following is an example for the application.properties file:

quarkus.datasource.url=jdbc:postgresql://localhost:5432/database
quarkus.datasource.driver=org.postgresql.Driver
quarkus.datasource.username=liquibase
quarkus.datasource.password=liquibase

# Liquibase minimal config properties
#quarkus.liquibase.changelog=db/changelog.xml
#quarkus.liquibase.default-schema=production
#quarkus.liquibase.contexts=production,migration

Версии библиотеки

Версия
1.0.0.CR2