I am pretty new with Jhipster development.
I developped an application with Jhipster (v 3.4.2), the application is working well with postgre in dev mode (the application is running and I can save entities in the database), but when I switch to production mode using
the application is working well, but I can't save anything to the database (still postgre)
The odd thing is, I can see all of the created entities when in dev mode in the detailed page of the entity, but I can't add a new one in prod mode as I said.
application-prod.ymlfiles contain the same datasource (url, name, username and pass).
Moreover, there is no stacktrace when I try to save something in production mode, just an internal Server error on the page, no logs whatsoever.
To build jhipster with prod profile use:
./mvnw -Pprod package (as you already did)
Now, when starting application make sure u activete PROD profile for running app:
./jhipster-0.0.1-SNAPSHOT.war --spring.profiles.active=prod If you are on Windows, use: java -jar jhipster-0.0.1-SNAPSHOT.war --spring.profiles.active=prod
More details: http://jhipster.github.io/production/