Mine has a strange behavior, but with satisfactory result. The problem of `The application must supply JDBC connections` occurs, but it creates the changelog normally. #481
Mine has a strange behavior, but with satisfactory result. The problem of The application must supply JDBC connections occurs, but it creates the changelog normally.
console log
[INFO] Scanning for projects...
[INFO]
[INFO] -----------------< br.midwest:folha-pagamento-service >-----------------
[INFO] Building folha-pagamento-service 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- liquibase-maven-plugin:4.4.2:diff (default-cli) @ folha-pagamento-service ---
[INFO] ------------------------------------------------------------------------
[INFO] Loading artifacts into URLClassLoader
[INFO] artifact: file:/home/rntjr/.m2/repository/org/springframework/boot/spring-boot-starter-data-jpa/2.7.10/spring-boot-starter-data-jpa-2.7.10.jar
[...]
[INFO] ------------------------------------------------------------------------
[project, pluginDescriptor]
[INFO] Parsing Liquibase Properties File
[INFO] File: src/main/resources/liquibase.yaml
[INFO] 'classpath' in properties file is not being used by this task.
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO]
[INFO] Liquibase Community 4.4.2 by Datical
[INFO] ####################################################
## _ _ _ _ ##
## | | (_) (_) | ##
## | | _ __ _ _ _ _| |__ __ _ ___ ___ ##
## | | | |/ _` | | | | | '_ \ / _` / __|/ _ \ ##
## | |___| | (_| | |_| | | |_) | (_| \__ \ __/ ##
## \_____/_|\__, |\__,_|_|_.__/ \__,_|___/\___| ##
## | | ##
## |_| ##
## ##
## Get documentation at docs.liquibase.com ##
## Get certified courses at learn.liquibase.com ##
## Free schema change activity reports at ##
## https://hub.liquibase.com ##
## ##
####################################################
Starting Liquibase at 08:17:54 (version 4.4.2 #39 built at 2021-07-22 18:11+0000)
[INFO] Settings
----------------------------
[INFO] driver: org.postgresql.Driver
[INFO] url: jdbc:postgresql://localhost:5432/folha_pagamento
[INFO] username: *****
[INFO] password: *****
[INFO] use empty password: false
[INFO] properties file: src/main/resources/liquibase.yaml
[INFO] properties file will override? false
[INFO] prompt on non-local database? true
[INFO] clear checksums? false
[INFO] changeLogDirectory: null
[INFO] changeLogFile: src/main/resources/master.yaml
[INFO] context(s): null
[INFO] label(s): null
[INFO] referenceDriver: liquibase.ext.hibernate.database.connection.HibernateDriver
[INFO] referenceUrl: hibernate:spring:br.midwest.folhapagamentoservice.entity?dialect=org.hibernate.dialect.PostgreSQL95Dialect
[INFO] referenceUsername: *****
[INFO] referencePassword: *****
[INFO] referenceDefaultSchema: null
[INFO] diffChangeLogFile: src/main/resources/db/changelog/20230421111753_changelog.yaml
[INFO] ------------------------------------------------------------------------
[INFO] Parsing Liquibase Properties File src/main/resources/liquibase.yaml for changeLog parameters
[INFO] Executing on Database: jdbc:postgresql://localhost:5432/folha_pagamento
[INFO] Loading artifacts into URLClassLoader
[INFO] artifact: file:/home/rntjr/.m2/repository/org/springframework/boot/spring-boot-starter-data-jpa/2.7.10/spring-boot-starter-data-jpa-2.7.10.jar
[...]
[INFO] ------------------------------------------------------------------------
[INFO] Reading hibernate configuration hibernate:spring:br.midwest.folhapagamentoservice.entity?dialect=org.hibernate.dialect.PostgreSQL95Dialect
[INFO] Found package br.midwest.folhapagamentoservice.entity
[INFO] HHH000204: Processing PersistenceUnitInfo [name: default]
[INFO] HHH000412: Hibernate ORM core version 5.6.15.Final
[INFO] HCANN000001: Hibernate Commons Annotations {5.1.2.Final}
[WARNING] HHH000181: No appropriate connection provider encountered, assuming application will be supplying connections
[WARNING] HHH000342: Could not obtain connection to query metadata
java.lang.UnsupportedOperationException: The application must supply JDBC connections
at org.hibernate.engine.jdbc.connections.internal.UserSuppliedConnectionProviderImpl.getConnection (UserSuppliedConnectionProviderImpl.java:44)
at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator$ConnectionProviderJdbcConnectionAccess.obtainConnection (JdbcEnvironmentInitiator.java:181)
at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService (JdbcEnvironmentInitiator.java:68)
at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService (JdbcEnvironmentInitiator.java:35)
at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.initiateService (StandardServiceRegistryImpl.java:101)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService (AbstractServiceRegistryImpl.java:272)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService (AbstractServiceRegistryImpl.java:246)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService (AbstractServiceRegistryImpl.java:223)
at org.hibernate.id.factory.internal.DefaultIdentifierGeneratorFactory.injectServices (DefaultIdentifierGeneratorFactory.java:175)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.injectDependencies (AbstractServiceRegistryImpl.java:295)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService (AbstractServiceRegistryImpl.java:252)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService (AbstractServiceRegistryImpl.java:223)
at org.hibernate.boot.internal.InFlightMetadataCollectorImpl.<init> (InFlightMetadataCollectorImpl.java:173)
at org.hibernate.boot.model.process.spi.MetadataBuildingProcess.complete (MetadataBuildingProcess.java:127)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.metadata (EntityManagerFactoryBuilderImpl.java:1460)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build (EntityManagerFactoryBuilderImpl.java:1494)
at liquibase.ext.hibernate.database.HibernateEjb3Database.buildMetadataFromPath (HibernateEjb3Database.java:59)
at liquibase.ext.hibernate.database.HibernateDatabase.buildMetadata (HibernateDatabase.java:143)
at liquibase.ext.hibernate.database.HibernateDatabase.setConnection (HibernateDatabase.java:83)
at liquibase.database.DatabaseFactory.findCorrectDatabaseImplementation (DatabaseFactory.java:121)
at liquibase.database.DatabaseFactory.openDatabase (DatabaseFactory.java:141)
at liquibase.integration.commandline.CommandLineUtils.createDatabaseObject (CommandLineUtils.java:90)
at org.liquibase.maven.plugins.LiquibaseDatabaseDiff.performLiquibaseTask (LiquibaseDatabaseDiff.java:240)
at org.liquibase.maven.plugins.AbstractLiquibaseMojo.lambda$null$0 (AbstractLiquibaseMojo.java:475)
at liquibase.Scope.lambda$child$0 (Scope.java:166)
at liquibase.Scope.child (Scope.java:175)
at liquibase.Scope.child (Scope.java:165)
at liquibase.Scope.child (Scope.java:144)
at org.liquibase.maven.plugins.AbstractLiquibaseMojo.lambda$execute$1 (AbstractLiquibaseMojo.java:401)
at liquibase.Scope.lambda$child$0 (Scope.java:166)
at liquibase.Scope.child (Scope.java:175)
at liquibase.Scope.child (Scope.java:165)
at liquibase.Scope.child (Scope.java:144)
at liquibase.Scope.child (Scope.java:228)
at liquibase.Scope.child (Scope.java:232)
at org.liquibase.maven.plugins.AbstractLiquibaseMojo.execute (AbstractLiquibaseMojo.java:338)
at org.liquibase.maven.plugins.LiquibaseDatabaseDiff.execute (LiquibaseDatabaseDiff.java:204)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:298)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:960)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:293)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:196)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:566)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
at org.codehaus.classworlds.Launcher.main (Launcher.java:47)
[INFO] HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL95Dialect
[INFO] HHH10005002: No explicit CDI BeanManager reference was passed to Hibernate, but CDI is available on the Hibernate ClassLoader.
[INFO] Envers integration enabled? : true
[INFO] HV000001: Hibernate Validator 6.2.5.Final
[INFO] HHH000490: Using JtaPlatform implementation: [org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform]
[INFO] HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL95Dialect
[INFO] Using dialect org.hibernate.dialect.PostgreSQL95Dialect
[INFO] Performing Diff on database postgres @ jdbc:postgresql://localhost:5432/folha_pagamento (Default Schema: public)
[INFO] Found table dependente
[INFO] Found table dependente
[INFO] Found table contato_email_pessoa
[INFO] Found table contato_email_pessoa
[INFO] Found table pessoa
[INFO] Found table pessoa
[INFO] Found table beneficio_dependente
[INFO] Found table beneficio_dependente
[INFO] Found table contato_telefone_pessoa
[INFO] Found table contato_telefone_pessoa
[INFO] Found table pessoa
[INFO] Found primary key pessoaPK
[INFO] Found column id int8
[INFO] Found column create_at timestamp
[INFO] Found column tenant_id varchar(255)
[INFO] Found column update_at timestamp
[INFO] Found column uuid varchar(255)
[INFO] Found column bairro varchar(255)
[INFO] Found column categoria_cnh varchar(255)
[INFO] Found column cep varchar(255)
[INFO] Found column cid_pcd varchar(255)
[INFO] Found column cidade varchar(255)
[INFO] Found column complemento_endereco varchar(255)
[INFO] Found column concelho_ordem_profissional varchar(255)
[INFO] Found column cor_raca varchar(255)
[INFO] Found column cpf varchar(255)
[INFO] Found column data_emissao_cnh date
[INFO] Found column data_expedicao_ctps date
[INFO] Found column data_emissao_identidade date
[INFO] Found column data_expedicao_titulo_eleitor date
[INFO] Found column data_nascimento date
[INFO] Found column data_validade_cnh date
[INFO] Found column escolaridade varchar(255)
[INFO] Found column estado_civil varchar(255)
[INFO] Found column logradouro varchar(255)
[INFO] Found column nacionalidade varchar(255)
[INFO] Found column naturalidade varchar(255)
[INFO] Found column nome_completo varchar(255)
[INFO] Found column nome_conjuge varchar(255)
[INFO] Found column nome_mae varchar(255)
[INFO] Found column nome_social varchar(255)
[INFO] Found column numero_cnh varchar(255)
[INFO] Found column numero_ctps varchar(255)
[INFO] Found column numero_endereco varchar(255)
[INFO] Found column numero_identidade varchar(255)
[INFO] Found column numero_pis_pasep_nit_nis varchar(255)
[INFO] Found column numero_registro_concelho_ordem_profissional varchar(255)
[INFO] Found column numero_titulo_eleitor varchar(255)
[INFO] Found column orgao_expedidor_identidade varchar(255)
[INFO] Found column secao_titulo_eleitor varchar(255)
[INFO] Found column serie_ctps varchar(255)
[INFO] Found column sexo varchar(255)
[INFO] Found column tipo_pcd varchar(255)
[INFO] Found column uf int4
[INFO] Found column uf_ctps varchar(255)
[INFO] Found column uf_orgao_expedidor_identidade varchar(255)
[INFO] Found column uf_titulo_eleitor varchar(255)
[INFO] Found column zona_titulo_eleitor varchar(255)
[INFO] Found table contato_telefone_pessoa
[INFO] Found primary key contato_telefone_pessoaPK
[INFO] Found column id int8
[INFO] Found column create_at timestamp
[INFO] Found column tenant_id varchar(255)
[INFO] Found column update_at timestamp
[INFO] Found column uuid varchar(255)
[INFO] Found column isPrincipal boolean
[INFO] Found column telefone varchar(255)
[INFO] Found column pessoa_id int8
[INFO] Found table contato_email_pessoa
[INFO] Found primary key contato_email_pessoaPK
[INFO] Found column id int8
[INFO] Found column create_at timestamp
[INFO] Found column tenant_id varchar(255)
[INFO] Found column update_at timestamp
[INFO] Found column uuid varchar(255)
[INFO] Found column email varchar(255)
[INFO] Found column is_principal boolean
[INFO] Found column pessoa_id int8
[INFO] Found table dependente
[INFO] Found primary key dependentePK
[INFO] Found column id int8
[INFO] Found column create_at timestamp
[INFO] Found column tenant_id varchar(255)
[INFO] Found column update_at timestamp
[INFO] Found column uuid varchar(255)
[INFO] Found column cpf varchar(255)
[INFO] Found column data_limite_irpf date
[INFO] Found column data_salario_familia date
[INFO] Found column data_nascimento date
[INFO] Found column dependencia varchar(255)
[INFO] Found column escolaridade varchar(255)
[INFO] Found column estado_civil varchar(255)
[INFO] Found column is_dependente_financeiro boolean
[INFO] Found column is_dependente_pcd boolean
[INFO] Found column is_universitario boolean
[INFO] Found column naturalidade varchar(255)
[INFO] Found column nome_completo varchar(255)
[INFO] Found column parentesco varchar(255)
[INFO] Found column sexo varchar(255)
[INFO] Found column pessoa_id int8
[INFO] Found table beneficio_dependente
[INFO] Found primary key beneficio_dependentePK
[INFO] Found column id int8
[INFO] Found column create_at timestamp
[INFO] Found column tenant_id varchar(255)
[INFO] Found column update_at timestamp
[INFO] Found column uuid varchar(255)
[INFO] Found column codigo varchar(255)
[INFO] Found column data_final date
[INFO] Found column data_inicio date
[INFO] Found column dependente_id int8
BEST PRACTICE: The changelog generated by diffChangeLog/generateChangeLog should be inspected for correctness and completeness before being deployed.
[INFO] changeSets count: 0
[INFO] No changesets to add.
[INFO] Differences written to Change Log File, src/main/resources/db/changelog/20230421111753_changelog.yaml
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.892 s
[INFO] Finished at: 2023-04-21T08:17:56-03:00
[INFO] ------------------------------------------------------------------------
Mine has a strange behavior, but with satisfactory result. The problem of
The application must supply JDBC connections
occurs, but it creates the changelog normally.console log
pom.xml
application.yaml
liquibase.yaml
master.xml
generated changelog
Originally posted by @rntjr in https://github.com/liquibase/liquibase-hibernate/issues/381#issuecomment-1517676580