138 lines
4.9 KiB
XML
138 lines
4.9 KiB
XML
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
<groupId>org.jooq</groupId>
|
|
<artifactId>jooq-flyway-example</artifactId>
|
|
<version>1.0</version>
|
|
<name>jOOQ Flyway Example</name>
|
|
|
|
<licenses>
|
|
<license>
|
|
<name>Apache License, Version 2.0</name>
|
|
<url>http://www.jooq.org/inc/LICENSE.txt</url>
|
|
<distribution>repo</distribution>
|
|
</license>
|
|
</licenses>
|
|
|
|
<properties>
|
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
<org.springframework.version>3.2.6.RELEASE</org.springframework.version>
|
|
<org.jooq.version>3.8.0-SNAPSHOT</org.jooq.version>
|
|
<org.h2.version>1.4.181</org.h2.version>
|
|
|
|
<db.url>jdbc:h2:~/flyway-test</db.url>
|
|
<db.username>sa</db.username>
|
|
</properties>
|
|
|
|
<dependencies>
|
|
|
|
<!-- Database access -->
|
|
<dependency>
|
|
<groupId>org.jooq</groupId>
|
|
<artifactId>jooq</artifactId>
|
|
<version>${org.jooq.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.h2database</groupId>
|
|
<artifactId>h2</artifactId>
|
|
<version>${org.h2.version}</version>
|
|
</dependency>
|
|
|
|
<!-- Logging -->
|
|
<dependency>
|
|
<groupId>log4j</groupId>
|
|
<artifactId>log4j</artifactId>
|
|
<version>1.2.16</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.slf4j</groupId>
|
|
<artifactId>slf4j-log4j12</artifactId>
|
|
<version>1.7.5</version>
|
|
</dependency>
|
|
|
|
<!-- Testing -->
|
|
<dependency>
|
|
<groupId>junit</groupId>
|
|
<artifactId>junit</artifactId>
|
|
<version>4.11</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-compiler-plugin</artifactId>
|
|
<version>3.1</version>
|
|
<configuration>
|
|
<fork>true</fork>
|
|
<maxmem>1024m</maxmem>
|
|
<meminitial>256m</meminitial>
|
|
<encoding>UTF-8</encoding>
|
|
<source>1.7</source>
|
|
<target>1.7</target>
|
|
<debug>true</debug>
|
|
<debuglevel>lines,vars,source</debuglevel>
|
|
</configuration>
|
|
</plugin>
|
|
|
|
<plugin>
|
|
<groupId>org.flywaydb</groupId>
|
|
<artifactId>flyway-maven-plugin</artifactId>
|
|
<version>3.0</version>
|
|
<executions>
|
|
<execution>
|
|
<phase>generate-sources</phase>
|
|
<goals>
|
|
<goal>migrate</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
<configuration>
|
|
<url>${db.url}</url>
|
|
<user>${db.username}</user>
|
|
<locations>
|
|
<location>filesystem:src/main/resources/db/migration</location>
|
|
</locations>
|
|
</configuration>
|
|
</plugin>
|
|
|
|
<plugin>
|
|
<groupId>org.jooq</groupId>
|
|
<artifactId>jooq-codegen-maven</artifactId>
|
|
<version>${org.jooq.version}</version>
|
|
|
|
<executions>
|
|
<execution>
|
|
<phase>generate-sources</phase>
|
|
<goals>
|
|
<goal>generate</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
|
|
<configuration>
|
|
<jdbc>
|
|
<url>${db.url}</url>
|
|
<user>${db.username}</user>
|
|
</jdbc>
|
|
<generator>
|
|
<database>
|
|
<includes>.*</includes>
|
|
<inputSchema>FLYWAY_TEST</inputSchema>
|
|
<catalogVersionProvider>SELECT 'DEFAULT_CATALOG_' || TO_CHAR(current_timestamp, 'YYYYMMDDHHMISS')</catalogVersionProvider>
|
|
<schemaVersionProvider>SELECT :schema_name || '_' || MAX("version") FROM "schema_version"</schemaVersionProvider>
|
|
</database>
|
|
<target>
|
|
<packageName>org.jooq.example.flyway.db.h2</packageName>
|
|
<directory>target/generated-sources/jooq-h2</directory>
|
|
</target>
|
|
</generator>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</project> |