All maven flyway plugins are executed with the last user - oracle

I have two oracle users and I am creating different schema for them. I mean each schema has different tables, types etc.
I wanted to create both schemas by flyway maven plugin, first I had two maven plugins, but then I tried also to have two separate profiles:
<profiles>
<profile>
<id>database</id>
<build>
<plugins>
<plugin>
<groupId>com.googlecode.flyway</groupId>
<artifactId>flyway-maven-plugin</artifactId>
<configuration>
<url>jdbc:oracle:thin:#devdb2:1521:ZOOMUTF</url>
<table>SCHEMA_UPDATES</table>
<outOfOrder>true</outOfOrder>
<locations>
<location>db/callrec</location>
</locations>
<user>cr_5199_mensik_mvn</user>
<password>callrec</password>
<serverId>callrec</serverId>
</configuration>
<executions>
<execution>
<id>compile</id>
<phase>compile</phase>
<goals>
<goal>migrate</goal>
</goals>
</execution>
<execution>
<id>clean</id>
<phase>clean</phase>
<goals>
<goal>clean</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>database_wbsc</id>
<build>
<plugins>
<plugin>
<groupId>com.googlecode.flyway</groupId>
<artifactId>flyway-maven-plugin</artifactId>
<configuration>
<url>jdbc:oracle:thin:#devdb2:1521:ZOOMUTF</url>
<table>SCHEMA_UPDATES</table>
<outOfOrder>true</outOfOrder>
<locations>
<location>db/wbsc</location>
</locations>
<user>sc_5199_mensik_mvn</user>
<password>wbsc</password>
<serverId>wbsc</serverId>
</configuration>
<executions>
<execution>
<id>wbsc_compile</id>
<phase>compile</phase>
<goals>
<goal>migrate</goal>
</goals>
</execution>
<execution>
<id>wbsc_clean</id>
<phase>clean</phase>
<goals>
<goal>clean</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
Then I execute:
mvn clean -Pdatabase,database_wbsc
But result is that only second profile is executed twice:
[INFO] [clean:clean {execution: default-clean}]
[INFO] [flyway:clean {execution: clean}]
[INFO] Cleaned schema "sc_5199_mensik_mvn" (execution time 00:00.023s)
[INFO] [flyway:clean {execution: wbsc_clean}]
[INFO] Cleaned schema "sc_5199_mensik_mvn" (execution time 00:00.018s)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
If I switch order of profiles in xml (not in maven execution command) then the second user is used.
How can I execute both profiles but with their configuration?

try providing the configuration at the execution level rather than the plugin level.
<plugin>
<executions>
<execution>
<id>execution1</id>
<configuration>
</configuration>
</execution>
<execution>
<id>execution2</id>
<configuration>
</configuration>
</execution>
</executions>
</plugin>

Related

How to generate Jacoco integration test report using offline instrumentation?

Build tool: Maven
Reason to use offline instrumentation: Removing Powermock is not an option
Problem:
Both failsafe and surefire are run and reports are generated. However, jacoco.exec is generate but jacoco-it.exec is not. Apart from IT , offline instrumentation, coverage and reporting works fine.
This is the maven plugin configuration I use:
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<executions>
<execution>
<id>default-instrument</id>
<goals>
<goal>instrument</goal>
</goals>
</execution>
<execution>
<id>default-restore-instrumented-classes</id>
<goals>
<goal>restore-instrumented-classes</goal>
</goals>
</execution>
<execution>
<id>default-report</id>
<goals>
<goal>report</goal>
</goals>
</execution>
<execution>
<id>default-report-integration</id>
<goals>
<goal>report-integration</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.16</version>
<configuration>
<systemPropertyVariables>
<jacoco-agent.destfile>target/jacoco.exec</jacoco-agent.destfile>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.15</version>
<executions>
<execution>
<id>integration-tests</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<skipTests>${skip.integration.tests}</skipTests>
</configuration>
</execution>
</executions>
</plugin>
To run the test i use maven clean install.
At the end of the test execution I get the following output:
[INFO]
[INFO] --- maven-failsafe-plugin:2.15:integration-test (integration-tests) # elune ---
[INFO] Skipping execution of surefire because it has already been run for this configuration
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.8:report (default-report) # elune ---
[INFO] Loading execution data file C:\Projects\elune\target\jacoco.exec
[INFO] Analyzed bundle 'elune' with 4 classes
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.8:report-integration (default-report-integration) # elune ---
[INFO] Skipping JaCoCo execution due to missing execution data file.
Another possible pointer might be that the de-instrumentation of the classes happens after the unit tests are run but before the integration tests. But I don't know if this is right or wrong:
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.8:restore-instrumented-classes (default-restore-instrumented-classes) # elune ---
[INFO]
[INFO] --- maven-jar-plugin:2.6:jar (default-jar) # elune ---
[INFO] Building jar: C:\Projects\elune\target\elune-0.0.1-SNAPSHOT.jar
[INFO]
[INFO] --- spring-boot-maven-plugin:1.4.2.RELEASE:repackage (default) # elune ---
[INFO]
[INFO] --- maven-failsafe-plugin:2.15:integration-test (default) # elune ---
[INFO] Failsafe report directory: C:\Projects\elune\target\failsafe-reports
Any idea why the jacoco-it.exec is not showing up?
I think the instrumentation of Integration Tests with the failsafe plugin are just not baked in. The restore-instrumented-classes goal defaults to the prepare-package phase which runs before the integration test phase: http://maven.apache.org/ref/3.3.9/maven-core/lifecycles.html - so it may be enough to move that goal into the post-integration-test phase:
<execution>
<id>default-restore-instrumented-classes</id>
<phase>post-integration-test</phase>
<goals>
<goal>restore-instrumented-classes</goal>
</goals>
</execution>
that may be enough. Otherwise you may be able to change the includes pattern of the surefire plugin to also include the integration tests (if that seems suitable in your case).
#rhinoceros.xn this is the plugin configuration that did the trick for me. But I use mvn clean install to run this
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<executions>
<execution>
<id>default-instrument</id>
<goals>
<goal>instrument</goal>
</goals>
</execution>
<execution>
<id>default-restore-instrumented-classes</id>
<phase>post-integration-test</phase>
<goals>
<goal>restore-instrumented-classes</goal>
</goals>
</execution>
<execution>
<id>default-report</id>
<goals>
<goal>report</goal>
</goals>
</execution>
<execution>
<id>default-report-integration</id>
<goals>
<goal>report-integration</goal>
</goals>
</execution>
</executions>
</plugin>
The jacoco-it.exec is not showing up after I set the phrase.
command line is:
mvn clean install -Djacoco.version=0.7.8 -DfailOnError=false -Dmaven.test.failure.ignore=true
I finally found the problem was that I didn't add configuration jacoco-agent.destfile in maven-failsafe-plugin.
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.16</version>
<configuration>
<systemPropertyVariables>
<jacoco-agent.destfile>target/jacoco.exec</jacoco-agent.destfile>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.15</version>
<configuration>
<systemPropertyVariables>
<jacoco-agent.destfile>target/jacoco-it.exec</jacoco-agent.destfile>
</systemPropertyVariables>
</configuration>
<executions>
<execution>
<id>integration-tests</id>
<goals>
<goal>integration-test</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.version}</version>
<executions>
<execution>
<id>default-instrument</id>
<goals>
<goal>instrument</goal>
</goals>
</execution>
<execution>
<id>default-restore-instrumented-classes</id>
<phase>post-integration-test</phase>
<goals>
<goal>restore-instrumented-classes</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>

does maven profile configured for integration phase execute during build life cycle?

Here is the condensed snippet of pom.xml from my project
<profiles>
<profile>
<id>run-tests</id>
<build>
<plugins>
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>replacer</artifactId>
<version>1.5.2</version>
<executions>
<execution>
<phase>pre-integration-test</phase>
<goals>
<goal>replace</goal>
</goals>
</execution>
</executions>
<configuration>
<includes>
......
</includes>
<replacements>
<replacement>
.......
</replacement>
</replacements>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.18.1</version>
<configuration>
......
</configuration>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<phase>integration-test</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
I have two questions:
1) when I execute mvn clean package -Prun-tests, what happens? I expected none of these plugin goals to execute here because they are bound to integration-test phase. But I see these goals executed why?
2) what does having two goals in execution block mean? please see above in failsafe-plugin
Thanks
A partial answer:
1) No Way. Unless you also have these plugins configured in the main build section to be run in phases up to package.
How did you determine that the plugins had run? Do you have something such as the following in the maven output?
[INFO] --- maven-failsafe-plugin:2.18.1:integration-test (default)
[INFO] --- maven-failsafe-plugin:2.18.1:verify (default)
2) That means that the two goals (mojos) will be executed in the integration-test phase. First the integration-test goal, immediately followed by the verify goal.
Comment: integration-test goal is by default bound to the integration-test phase, whereas the verify goal is bound to the verify phase. So you could have configured the failsafe plugin this way:
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
Note that the phase is ommited

Jacoco Report are not generated in the site

Jacoco reports are not generated when mvn builds the site.
Jacoco reports are generated in my target folder at target\site\jacoco , but somehow I am not able to see "Jacoco Tests" option under "Project Reports" when I try to build the jar site
The only thing I see in the log while generating the site is as below :
[INFO] <<< clirr-maven-plugin:2.6.1:clirr # data-binding <<<
[INFO] configuring report plugin com.cerner.engineering:maven-cerner-ml-dependency-plugin:1.1.1
[INFO] configuring report plugin org.jacoco:jacoco-maven-plugin:0.7.4.201502262128
[INFO] Skipping JaCoCo execution due to missing execution data file:C:\MSVCWorkspace\br-hla-april-data-binding\target\jacoco.exec
I am using the command mvn clean install site
This is how I have configure jacoco in my pom.xml in my build section :
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${surefire.plugin.version}</version>
<configuration>
<excludes>
<exclude>**/*Suite*.java</exclude>
</excludes>
<forkCount>1</forkCount>
<reuseForks>false</reuseForks>
<argLine>-Xms64m -Xmx512m -XX:MaxPermSize=256M -enableassertions -XX:+HeapDumpOnOutOfMemoryError ${jacoco.argLine}</argLine>
<junitArtifactName>junit:junit-dep</junitArtifactName>
</configuration>
</plugin>
Jacoco plugin is called like :
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.version}</version>
<configuration>
<destFile>${basedir}/target/coverage-reports/jacoco-unit.exec</destFile>
<dataFile>${basedir}/target/coverage-reports/jacoco-unit.exec</dataFile>
</configuration>
<executions>
<execution>
<id>jacoco-initialize</id>
<goals>
<goal>prepare-agent</goal>
</goals>
<configuration>
<propertyName>jacoco.argLine</propertyName>
</configuration>
</execution>
<execution>
<id>jacoco-site</id>
<phase>package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
I am not sure what is causing this issue , not to generate Jacoco reports on my site.
Although I am able to see the below in my logs
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.4.201502262128:prepare-agent (default-cli) # data-binding ---
[INFO] argLine set to -javaagent:C:\\_repository\\org\\jacoco\\org.jacoco.agent\\0.7.4.201502262128\\org.jacoco.agent-0.7.4.201502262128-runtime.jar=destfile=C:\\target\\coverage-reports\\jacoco-unit.exec
Thanks !!!
I was able to fix by calling plugin as below
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.version}</version>
<configuration>
<dataFile>${basedir}/target/coverage-reports/jacoco-unit.exec</dataFile>
</configuration>
<executions>
<execution>
<id>jacoco-initialize</id>
<goals>
<goal>prepare-agent</goal>
</goals>
<configuration>
<propertyName>jacoco.argLine</propertyName>
</configuration>
</execution>
</executions>
</plugin>

Maven Plugin for calling Maven Plugins?

does anyone know any maven plugin that can call other maven plugins in a generic way? What I am searching for is anything like a proxy mechanism for scheduling plugin executions in a specific order.
The key is that I have to migrate a huge legacy project to maven which has plenty of ant macros that have to run in a specific order but with maven it is not possible to invoke the same plugin twice in one and the same phase with preserving the execution order when I need to intercept the two executions by the exectuion of a second plugin.
Assume the following: I have plugin A (native2ascii) and plugin B (replacer). Now my execution order must be A,B,A in just one phase. Sure, I can write it like that but the effective pom would look like A,A,B.
So it would be nice to have a 'proxy-plugin' (P) which would simply invoke the configured plugins. This way you could configure P(A),P(B),P(A) in one phase and the effective pom would be able to preserve the execution order.
Thanks so far!
I've tried out Wim's proposal like in the following but it turned out that the execution ids have no impact on the effective pom. The two executions of the replacer plugin are still combined and run before the native2ascii plugin.
Here is my pom:
<build>
<plugins>
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>replacer</artifactId>
<version>1.5.3</version>
<executions>
<execution>
<id>step-1-replacer</id>
<phase>generate-sources</phase>
<goals>
<goal>replace</goal>
</goals>
<configuration>
<file>src/main/order-test/test.txt</file>
<outputFile>target/test-replaced-1.txt</outputFile>
<replacements>
<replacement>
<token>t</token>
<value>xyz</value>
</replacement>
</replacements>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>native2ascii-maven-plugin</artifactId>
<version>1.0-beta-1</version>
<executions>
<execution>
<id>step-2-native2ascii</id>
<phase>generate-sources</phase>
<goals>
<goal>native2ascii</goal>
</goals>
<configuration>
<workDir>target</workDir>
<includes>
<include>test-replaced-1.txt</include>
</includes>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>replacer</artifactId>
<version>1.5.3</version>
<executions>
<execution>
<id>step-3-replacer</id>
<phase>generate-sources</phase>
<goals>
<goal>replace</goal>
</goals>
<configuration>
<file>target/test-replaced-1.txt</file>
<outputFile>target/test-replaced-2.txt</outputFile>
<replacements>
<replacement>
<token>f6</token>
<value>-</value>
</replacement>
<replacement>
<token>e4</token>
<value>></value>
</replacement>
</replacements>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
And here is how it looks like in the effective pom (both replacer executions are run before the native2ascii execution):
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>replacer</artifactId>
<version>1.5.3</version>
<executions>
<execution>
<id>step-1-replacer</id>
<phase>generate-sources</phase>
<goals>
<goal>replace</goal>
</goals>
<configuration>
<file>src/main/order-test/test.txt</file>
<outputFile>target/test-replaced-1.txt</outputFile>
<replacements>
<replacement>
<token>t</token>
<value>xyz</value>
</replacement>
</replacements>
</configuration>
</execution>
<execution>
<id>step-3-replacer</id>
<phase>generate-sources</phase>
<goals>
<goal>replace</goal>
</goals>
<configuration>
<file>target/test-replaced-1.txt</file>
<outputFile>target/test-replaced-2.txt</outputFile>
<replacements>
<replacement>
<token>f6</token>
<value>-</value>
</replacement>
<replacement>
<token>e4</token>
<value>></value>
</replacement>
</replacements>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>native2ascii-maven-plugin</artifactId>
<version>1.0-beta-1</version>
<executions>
<execution>
<id>step-2-native2ascii</id>
<phase>generate-sources</phase>
<goals>
<goal>native2ascii</goal>
</goals>
<configuration>
<workDir>target</workDir>
<includes>
<include>test-replaced-1.txt</include>
</includes>
</configuration>
</execution>
</executions>
</plugin>
And here is the output of the build:
...
[INFO] --- replacer:1.5.3:replace (step-1-replacer) # build-order-test ---
[INFO] Replacement run on 1 file.
[INFO]
[INFO] --- replacer:1.5.3:replace (step-3-replacer) # build-order-test ---
[INFO] Replacement run on 1 file.
[INFO]
[INFO] --- native2ascii-maven-plugin:1.0-beta-1:native2ascii (step-2-native2ascii) # build-order-test ---
[INFO] Includes: [test-replaced-1.txt]
[INFO] Excludes: []
[INFO] Processing /home/shillner/work/workspaces/dev/build-order-test/target/test-replaced-1.txt
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
Take a look at mojo-executor plugin, it can be used to invoke other plugins - from pom.xml and also programmaticaly.
Example:
<plugin>
<groupId>org.twdata.maven</groupId>
<artifactId>mojo-executor-maven-plugin</artifactId>
<version>#project.version#</version>
<executions>
<execution>
<phase>test</phase>
<goals>
<goal>execute-mojo</goal>
</goals>
<configuration>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.0</version>
</plugin>
<goal>list</goal>
<configuration>
</configuration>
</configuration>
</execution>
</executions>
</plugin>
There is no official support, but we are using execution ids in alphabetical order and this works fine for many years already.
Example:
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>step-0-copy-resources</id>
<goals>
<goal>resources</goal>
</goals>
<phase>package</phase>
<configuration>
<outputDirectory>${basedir}/target</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>step-1-build-assembly</id>
<goals>
<goal>single</goal>
</goals>
<phase>package</phase>
<configuration>
<descriptors>
<descriptor>${basedir}/src/main/assembly/descriptor.xml</descriptor>
</descriptors>
<!-- don't attach assembly to be installed -->
<attach>false</attach>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<executions>
<execution>
<id>step-2-build-installer</id>
<phase>package</phase>
<goals>
<goal>execute</goal>
</goals>
</execution>
</executions>
<configuration>
<source>${basedir}/BuildInstaller.groovy</source>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>step-3-attach-artifacts</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<file>${basedir}/target/project-${project.version}.tar.gz</file>
<type>tar.gz</type>
</artifact>
</artifacts>
</configuration>
</execution>
</executions>
</plugin>
Notice how each <id/> starts with "step-x" with x a number.

Maven runs profile executions only after the build executions

Given a following maven pom.xml development profile
<profiles>
<profile>
<id>development</id>
<build>
<plugins>
<plugin>
<groupId>org.liquibase</groupId>
<artifactId>liquibase-maven-plugin</artifactId>
<version>3.0.4</version>
<executions>
<execution>
<id>01-liquibase.dropAll</id>
<phase>process-resources</phase>
<configuration>
[...skip...]
</configuration>
<goals>
<goal>dropAll</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
and main section of pom.xml:
<build>
<plugins>
<plugin>
<groupId>org.apache.openjpa</groupId>
<artifactId>openjpa-maven-plugin</artifactId>
<version>2.2.2</version>
<configuration>
<includes>package/pm/entity/**/*.class</includes>
<addDefaultConstructor>true</addDefaultConstructor>
<enforcePropertyRestrictions>true</enforcePropertyRestrictions>
<persistenceXmlFile>${project.parent.basedir}/forms-webapp/src/main/resources/META-INF/persistence.xml</persistenceXmlFile>
</configuration>
<executions>
<execution>
<id>02-enhancer</id>
<phase>process-classes</phase>
<goals>
<goal>enhance</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.apache.openjpa</groupId>
<artifactId>openjpa</artifactId>
<version>2.2.2</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.liquibase</groupId>
<artifactId>liquibase-maven-plugin</artifactId>
<version>3.0.4</version>
<executions>
<execution>
<id>03-liquibase.update</id>
<phase>process-resources</phase>
<configuration>
[...skipped...]
</configuration>
<goals>
<goal>update</goal>
</goals>
</execution>
<!-- for tests -->
<execution>
<id>04-liquibase-test.dropAll</id>
<phase>process-test-resources</phase>
<configuration>
[...skipped...]
</configuration>
<goals>
<goal>dropAll</goal>
</goals>
</execution>
<execution>
<id>05-liquibase-test.update</id>
<phase>process-test-resources</phase>
<configuration>
[...skipped...]
</configuration>
<goals>
<goal>update</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
I expect that executions will run in the following order:
....
01-liquibase.dropAll
03-liquibase.update
....
But in build log I see:
[INFO] --- liquibase-maven-plugin:3.0.4:update (03-liquibase.update) # forms-entity ---
[INFO] ------------------------------------------------------------------------
[INFO] Parsing Liquibase Properties File
[INFO] File: src/main/resources/liquibase.properties
[INFO] 'classpath' in properties file is not being used by this task.
[INFO] ------------------------------------------------------------------------
[INFO] Executing on Database: jdbc:postgresql://localhost/pman_trunk
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO]
[INFO] --- liquibase-maven-plugin:3.0.4:dropAll (01-liquibase.dropAll) # forms-entity ---
[INFO] ------------------------------------------------------------------------
[INFO] Parsing Liquibase Properties File
[INFO] File: src/main/resources/liquibase.properties
[INFO] 'classpath' in properties file is not being used by this task.
[INFO] ------------------------------------------------------------------------
[INFO] Executing on Database: jdbc:postgresql://localhost/pman_trunk
[INFO] ------------------------------------------------------------------------
Is there any way to fix this wrong execution order?
The executions for id 01-liquibase.dropAll and 03-liquibase.update are executing on the same phase.
You could always move the execution with id 01-liquibase.dropAll to an earlier phase such as generate-resources
<id>01-liquibase.dropAll</id>
<phase>process-resources</phase>
See the Default Lifecycle section in Maven Lifecycle Reference.

Resources