Skip to content
This repository was archived by the owner on Aug 4, 2024. It is now read-only.
This repository was archived by the owner on Aug 4, 2024. It is now read-only.

Hibernate Dialect Issue: java.lang.IllegalStateException: Failed to load ApplicationContext for [WebMergedContextConfiguratio #13

@joyryder

Description

@joyryder

Whenever I run the mvn test I get the following error:

[ERROR] contextLoads Time elapsed: 0.002 s <<< ERROR! java.lang.IllegalStateException: Failed to load ApplicationContext for [WebMergedContextConfiguration@70139a81 testClass = com.programmingtechie.inventoryservice.InventoryServiceApplicationTests, locations = [], classes = [com.programmingtechie.inventoryservice.InventoryServiceApplication], contextInitializerClasses = [], activeProfiles = [], propertySourceLocations = [], propertySourceProperties = ["org.springframework.boot.test.context.SpringBootTestContextBootstrapper=true"], contextCustomizers = [org.springframework.boot.test.context.filter.ExcludeFilterContextCustomizer@742ff096, org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer@79e4c792, org.springframework.boot.test.mock.mockito.MockitoContextCustomizer@0, org.springframework.boot.test.web.client.TestRestTemplateContextCustomizer@5b218417, org.springframework.boot.test.autoconfigure.actuate.observability.ObservabilityContextCustomizerFactory$DisableObservabilityContextCustomizer@9da1, org.springframework.boot.test.autoconfigure.properties.PropertyMappingContextCustomizer@0, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverContextCustomizerFactory$Customizer@7188af83, org.springframework.boot.test.context.SpringBootTestAnnotation@223fe7d3], resourceBasePath = "src/main/webapp", contextLoader = org.springframework.boot.test.context.SpringBootContextLoader, parent = null] Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.class]: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment] Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment] Caused by: org.hibernate.HibernateException: Unable to determine Dialect without JDBC metadata (please set 'javax.persistence.jdbc.url', 'hibernate.connection.url', or 'hibernate.dialect')

This is issue is not going away, please let me know how I can resolve this issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions