Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create internal lib dir #2850

Merged
merged 5 commits into from
May 19, 2022
Merged

Create internal lib dir #2850

merged 5 commits into from
May 19, 2022

Conversation

nvoxland
Copy link
Contributor

@nvoxland nvoxland commented May 16, 2022

Description

  • Moves the shipped jar files to a new internal/lib directory without version info in the filename
  • Moves the classpath creation logic out of the batch/bash scripts into a new LiquibaseLauncher class which now handles the additional directory.
  • Adds a list of all the libraries used (including version) to the output of liquibase --version

Fixes #2845

Things to be aware of

  • Changes the CLI launch script for linux/mac and windows
  • Moves the logic for building up the classpath, so need to test that the priority of locations is preserved.
    • Priority is: liquibase_libs beats liquibase_home/lib beats liquibase_home/internal/lib

Things to worry about

  • No unit tests for the launcher or script changes since they are "initializing" stuff that's hard to unit test currently
  • Is it correctly respecting and reporting on the jar file location priorities?

- Removed version from libraries added to internal/lib
- Moved classpath creation logic from batch/bash scripts to new LiquibaseLauncher class that wraps LiquibaseCommandLine
@github-actions
Copy link

github-actions bot commented May 16, 2022

Unit Test Results

  4 512 files  ±0    4 512 suites  ±0   32m 7s ⏱️ - 1m 41s
  4 419 tests ±0    4 201 ✔️  - 4     218 💤 +4  0 ±0 
52 308 runs  ±0  47 296 ✔️  - 4  5 012 💤 +4  0 ±0 

Results for commit 8e9eaa2. ± Comparison against base commit 818022c.

♻️ This comment has been updated with latest results.

@kevin-atx kevin-atx added this to the NEXT milestone May 17, 2022
@nvoxland nvoxland requested a review from suryaaki2 May 17, 2022 14:09
@FBurguer
Copy link

FBurguer commented May 18, 2022

The liquibase --version command list correctly all the jar files and their location, liquibase also runs the correct jar file as the priority list Nathan provided.
Output Example:

Libraries:

  • liquibase_libs/hsqldb.jar: HSQLDB 2.5.2
  • internal/lib/jaxb-api.jar: jaxb-api 2.3.1
  • lib/h2.jar: H2 Database Engine 2.1.212

Tests Environments:
Database: h2 2
SO: Windows 10
Java: 18.0.1

Database: h2 2
SO: Ubuntu
Java: 1.8.0_312

# Conflicts:
#	liquibase-cli/src/main/java/liquibase/integration/commandline/LiquibaseCommandLine.java
@nvoxland nvoxland merged commit 08452bd into master May 19, 2022
@nvoxland nvoxland deleted the create-internal-lib-dir branch May 19, 2022 02:47
@FBurguer FBurguer self-assigned this May 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Remove version from filenames in LIQUIBASE_HOME/lib
5 participants