Reputation: 84
I have a Spring Boot application which is deployed to Heroku. I've been using ClearDB ignite for some time and everything worked perfectly, but today I upgraded ClearDB addon to punch(paid), because I needed more capacity and now when I open my app it seems that it's unable to connect to a db and logs prove this.
So I imported my local mysql file into cleardb, and I can see all my tables in there when I connect to it through command line. Basically I did all the same steps as when I was using ignite.
But what's interesting, when I was using ignite, and executed heroku run env command, all variables such as SPRING_DATASOURCE_URL, SPRING_DATASOURCE_USERNAME, SPRING_DATASOURCE_PASSWORD were already set in env variables list, so I didn't have to specify them in my application.properties file.
Now when I run this command, only CLEARDB_DATABASE_URL is there. I tried to set them inside properties file.
(I modified username and password on purpose now for screenshot)
I also tried setting these using DataSourceBuilder but nothing seems to work.
Anyone has any ideas what it might be?
Thanks in advance
Upvotes: 0
Views: 131
Reputation: 84
Resolved by creating new heroku app and only adding ClearDB punch addon, imported local db and everything works. Looks like when I added a new cleardb addon while still using free one mixed up some config settings, I don't have any other explanation. Anyways, problem solved.
Upvotes: 0