I have the JPA server being configured with Spring Profiles to specify application profiles. All good so far.
I have a backing Postgres DB in the AWS cloud that I can point to for a data source and locally, everything works fine. I have hibernate search setting as true. The application starts up without a hitch given the right profile configuration to use.
Locally, I can run the docker image with ZERO issues. However, the MOMENT I try to load the image created from the same docker file, in my AWS service, I get errors that the lucene related TermContent and ResourceTable indices can't be initialized and the app fails to launch.
I have tried every combination of opening up the /app/target directory for open access and still nothing.
ANYONE ABLE TO HELP OR GIVE ME SOMETHING TO LOOK FURHTER INTO THIS WITH??? Am stumped.
Many thanks,
Ryck Birch
Here is the essential error stack:
Caused by: javax.persistence.PersistenceException: [PersistenceUnit: HAPI_PU] Unable to build Hibernate SessionFactory; nested exception is org.hibernate.search.util.common.SearchException: HSEARCH000520: Hibernate Search encountered failures during bootstrap. Failures:
index 'TermConcept':
failures:
- HSEARCH600154: Unable to start index: HSEARCH600015: Unable to initialize index directory: /app/target
Context: index 'TermConcept'
index 'ResourceTable':
failures:
- HSEARCH600154: Unable to start index: HSEARCH600015: Unable to initialize index directory: /app/target
Context: index 'ResourceTable'
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.buildNativeEntityManagerFactory(AbstractEntityManagerFactoryBean.java:421)
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:396)
at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.afterPropertiesSet(LocalContainerEntityManagerFactoryBean.java:341)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1863)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1800)
... 103 common frames omitted