Upgrade from Liquibase Community to Liquibase Secure with Maven

Last updated: September 2, 2025

This article walks you through the steps of upgrading from Liquibase Open Source (Community) to Liquibase Secure using Maven. Maven is a build automation tool commonly used for managing Java-based projects and dependencies.

In this guide, you’ll update your project’s pom.xml file to use the Liquibase Secure Maven plugin and ensure that Liquibase Secure functionality is available on your classpath by removing any exclusions of the liquibase-commercial JAR.

Before you begin

  • A working Maven project that already uses Liquibase Community.

Procedure

1

Update the Maven Plugin

In your pom.xml, replace the Community plugin with the Secure plugin by changing the artifact details to the liquibase-secure-maven-plugin.

Be sure to replace 5.0.0 with the version of Liquibase you'd like to use.

Example code
<plugin>
  <groupId>com.liquibase</groupId>
  <artifactId>liquibase-secure-maven-plugin</artifactId>
  <version>5.0.0</version>
</plugin>
2

Remove any liquibase-commercial exclusions

To ensure Liquibase Secure features are available, remove any dependency exclusions that block the liquibase-commercial JAR. This is sometimes added in Community setups to avoid loading Secure libraries unintentionally.

Look for a block like this in your pom.xml and remove it. You can remove the <exclusions> section or the entire dependency declaration if it’s redundant.

Example code
<dependency>
  <groupId>com.liquibase</groupId>
  <artifactId>liquibase-core</artifactId>
  <version>5.0.0</version>
  <exclusions>
    <exclusion>
      <groupId>com.liquibase</groupId>
      <artifactId>liquibase-secure-maven-plugin</artifactId>
    </exclusion>
  </exclusions>
</dependency>
3

Verify the upgrade

To verify that Liquibase Secure is installed and working correctly, run a Liquibase goal from your Maven project directory. You can run the example code in your terminal. This code generates the raw SQL statements that Liquibase would apply to your database, but does not execute them.

Example code
mvn liquibase:updateSQL

If Liquibase Secure is configured correctly, this command will execute without errors, and you’ll see output indicating that the Liquibase Secure Maven plugin is in use.