Stream: hapi
Topic: hapi-fhir-jpaserver-starter Hibernate errors with SQL
Jordan Matelsky (Jul 25 2019 at 15:35):
I think possibly relevant to @James Agnew — trying to get the https://github.com/hapifhir/hapi-fhir-jpaserver-starter repository running in a Docker container with a docker-compose
MySQL container running alongside. Followed the MySQL subheader instructions and got at least the Jetty server running, but the hapi-fhir-jpaserver Servlet status is listed as Not Available. When I check my error logs, it looks like the servlet isn't being initialized due to a Hibernate connection error; but my credentials and DB uri are definitely correct (I can connect from the local machine to the SQL db directly).
Before I spend a bunch more time debugging the SQL connection, is this error familiar to you/anyone? I imagine it's an auth issue but am not sure where to start debugging.
Caused by: javax.persistence.PersistenceException: [PersistenceUnit: HAPI_PU] Unable to build Hibernate SessionFactory; nested exception i s org.hibernate.exception.GenericJDBCException: Unable to open JDBC Connection for DDL execution
Jordan Matelsky (Jul 25 2019 at 15:36):
(Happy to share my docker-compose, hapi.properties, full error log if helpful!)
Jordan Matelsky (Jul 25 2019 at 15:36):
(Sorry to pick on you @James Agnew — but you made the fatal mistake of being the first username I found on that repo :) )
Jordan Matelsky (Jul 25 2019 at 16:54):
(i think @Sean McIlvenna might be involved in that codebase as well?)
Jordan Matelsky (Jul 25 2019 at 18:05):
I may have a solution, will share here for others once I know it's working
Sean McIlvenna (Jul 25 2019 at 18:14):
Did you make sure the dialect property was updated with a valid MySQL dialect in the hapi.properties file?
Sean McIlvenna (Jul 25 2019 at 18:14):
and yes, I do contribute to hapi-fhir-jpaserver-starter... but only a little :)
Sean McIlvenna (Jul 25 2019 at 18:15):
I, too, am interested in getting hapi running in a docker container, though. So, this is definitely of interest to me
Sean McIlvenna (Jul 25 2019 at 18:15):
I just haven't had any time to play around with it, yet
Jordan Matelsky (Jul 25 2019 at 20:32):
@Sean McIlvenna yep — used the configs right out of the README.md on that repo, i think i needed to add one more config line.... will git-diff and report back
Jordan Matelsky (Jul 25 2019 at 21:13):
@Sean McIlvenna (and cc @James Agnew FYSA) — here's the repo where we've got a working Docker-Compose. The big gotcha was keeping the jetty server from spinning up the Servlet until after the mysql container was provisioned and running happily. There's some junk config lines in there but it should be pretty straightforward to see the changes we made! Happy to talk more about, too.
dsh (Nov 22 2019 at 03:17):
Sean McIlvenna (and cc James Agnew FYSA) — here's the repo where we've got a working Docker-Compose. The big gotcha was keeping the jetty server from spinning up the Servlet until after the mysql container was provisioned and running happily. There's some junk config lines in there but it should be pretty straightforward to see the changes we made! Happy to talk more about, too.
@Jordan Matelsky where is the repo? I think you forgot a link
Last updated: Apr 12 2022 at 19:14 UTC