Sorry if this question is repeated but I cannot find a solution in other questions.
I'm trying to deploy my Spring-boot application on heroku. I'm hosting the database, but when i try to deploy I'm getting this error on the logs in heroku.
2016-01-29T05:08:05.730937+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/" h
ost=naturaapp.herokuapp.com request_id=39586950-d3fb-463c-9b21-458ae41b2f36 fwd="190.139.xx.xxx" dyno= connect= service=
status=503 bytes=
2016-01-29T05:08:06.641002+00:00 heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/fav
icon.ico" host=naturaapp.herokuapp.com request_id=75e51dfb-58f1-4524-9a66-52605573097e fwd="190.139.xx.xxx" dyno= connec
t= service= status=503 bytes=
I don't know what I'm doing wrong, can someone explain me what to do?
I already use the command heroku ps:scale web but still getting the same error.
If you need my code, please tell me!
Thank you!
UPDATE
After adding my Procfile with web: java -Dserver.port=$PORT -jar target/*.jar
I'm getting the following errors on my log:
PS C:\Users\Paulo> heroku logs --tail --app naturaapp
2016-01-29T23:59:37.000435+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2016-01-29T23:59:36.950259+00:00 app[web.1]: 2016-01-29 23:59:36.950 INFO 3 --- [ main] o.apache.catalina.core.StandardService : Stopping service Tomcat
2016-01-29T23:59:37.000476+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2016-01-29T23:59:37.000281+00:00 app[web.1]: java.lang.reflect.InvocationTargetException
2016-01-29T23:59:37.000644+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:745)
2016-01-29T23:59:37.000899+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1578)
2016-01-29T23:59:37.000537+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2016-01-29T23:59:37.000841+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaAutoConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2016-01-29T23:59:37.000981+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545)
2016-01-29T23:59:37.001276+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
2016-01-29T23:59:37.000592+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:53)
2016-01-29T23:59:37.001057+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
2016-01-29T23:59:37.001206+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
2016-01-29T23:59:37.001422+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1054)
2016-01-29T23:59:37.001603+00:00 app[web.1]: at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118)
2016-01-29T23:59:37.001134+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
2016-01-29T23:59:37.001349+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
2016-01-29T23:59:37.001717+00:00 app[web.1]: at org.springframework.boot.SpringApplication.doRun(SpringApplication.java:357)
2016-01-29T23:59:37.001512+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:829)
2016-01-29T23:59:37.001860+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1113)
2016-01-29T23:59:37.001810+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:305)
2016-01-29T23:59:37.001812+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1124)
2016-01-29T23:59:37.001661+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:764)
2016-01-29T23:59:37.002285+00:00 app[web.1]: at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:205)
2016-01-29T23:59:37.002345+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:111)
2016-01-29T23:59:37.001914+00:00 app[web.1]: at com.arg.juy.natura.NaturaApplication.main(NaturaApplication.java:19)
2016-01-29T23:59:37.001987+00:00 app[web.1]: ... 6 more
2016-01-29T23:59:37.002119+00:00 app[web.1]: Caused by: org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2016-01-29T23:59:37.001543+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:538)
2016-01-29T23:59:37.002217+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.determineDialect(DialectFactoryImpl.java:104)
2016-01-29T23:59:37.002479+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:206)
2016-01-29T23:59:37.002615+00:00 app[web.1]: at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1845)
2016-01-29T23:59:37.002671+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:857)
2016-01-29T23:59:37.002221+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.buildDialect(DialectFactoryImpl.java:71)
2016-01-29T23:59:37.002409+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:234)
2016-01-29T23:59:37.002556+00:00 app[web.1]: at org.hibernate.cfg.Configuration.buildTypeRegistrations(Configuration.java:1887)
2016-01-29T23:59:37.002737+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:850)
2016-01-29T23:59:37.002806+00:00 app[web.1]: at org.hibernate.boot.registry.classloading.internal.ClassLoaderServiceImpl.withTccl(ClassLoaderServiceImpl.java:425)
2016-01-29T23:59:37.003012+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:343)
2016-01-29T23:59:37.003082+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:318)
2016-01-29T23:59:37.002864+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:849)
2016-01-29T23:59:37.002959+00:00 app[web.1]: at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:60)
2016-01-29T23:59:37.003136+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637)
2016-01-29T23:59:37.003239+00:00 app[web.1]: ... 22 more
2016-01-29T23:59:37.003194+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574)
2016-01-29T23:59:36.895820+00:00 app[web.1]: 2016-01-29 23:59:36.895 WARN 3 --- [ main] ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaAutoConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2016-01-29T23:59:36.957188+00:00 app[web.1]: java.lang.Object.wait(Native Method)
2016-01-29T23:59:36.957183+00:00 app[web.1]: 2016-01-29 23:59:36.957 WARN 3 --- [ost-startStop-1] o.a.c.loader.WebappClassLoaderBase : The web application [ROOT] appears to have started a thread named [Abandoned connection cleanup thread] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
2016-01-29T23:59:36.957190+00:00 app[web.1]: java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:143)
2016-01-29T23:59:36.957191+00:00 app[web.1]: com.mysql.jdbc.AbandonedConnectionCleanupThread.run(AbandonedConnectionCleanupThread.java:43)
2016-01-29T23:59:36.989715+00:00 app[web.1]: 2016-01-29 23:59:36.988 ERROR 3 --- [ main] o.s.boot.SpringApplication : Application startup failed
2016-01-29T23:59:36.989720+00:00 app[web.1]:
2016-01-29T23:59:36.989722+00:00 app[web.1]: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaAutoConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.HibernateException:Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2016-01-29T23:59:36.989724+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1578) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989725+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989726+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989727+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989729+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989728+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989729+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989731+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1054) ~[spring-context-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989738+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:829) ~[spring-context-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989740+00:00 app[web.1]: at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) ~[spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989739+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:538) ~[spring-context-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989741+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:764) [spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989741+00:00 app[web.1]: at org.springframework.boot.SpringApplication.doRun(SpringApplication.java:357) [spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989742+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:305) [spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989743+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1113) [spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989743+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1124) [spring-boot-1.3.1.RELEASE.jar!/:1.3.1.RELEASE]
2016-01-29T23:59:36.989744+00:00 app[web.1]: at com.arg.juy.natura.NaturaApplication.main(NaturaApplication.java:19)[Natura-0.0.1-SNAPSHOT.jar!/:0.0.1-SNAPSHOT]
2016-01-29T23:59:36.989745+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_72-cedar14]
2016-01-29T23:59:36.989746+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_72-cedar14]
2016-01-29T23:59:36.989747+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_72-cedar14]
2016-01-29T23:59:36.989747+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_72-cedar14]
2016-01-29T23:59:36.989748+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:53) [Natura-0.0.1-SNAPSHOT.jar!/:0.0.1-SNAPSHOT]
2016-01-29T23:59:36.989749+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:745) [na:1.8.0_72-cedar14]
2016-01-29T23:59:36.989750+00:00 app[web.1]: Caused by: org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2016-01-29T23:59:36.989756+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.determineDialect(DialectFactoryImpl.java:104) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989762+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.buildDialect(DialectFactoryImpl.java:71) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989763+00:00 app[web.1]: at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:205) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989763+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:111) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989764+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:234) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989764+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:206) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989765+00:00 app[web.1]: at org.hibernate.cfg.Configuration.buildTypeRegistrations(Configuration.java:1887) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989766+00:00 app[web.1]: at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1845) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989771+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:857) ~[hibernate-entitymanager-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989773+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:849) ~[hibernate-entitymanager-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989772+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:850) ~[hibernate-entitymanager-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989773+00:00 app[web.1]: at org.hibernate.boot.registry.classloading.internal.ClassLoaderServiceImpl.withTccl(ClassLoaderServiceImpl.java:425) ~[hibernate-core-4.3.11.Final.jar!/:4.3.11.Final]
2016-01-29T23:59:36.989775+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:318) ~[spring-orm-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989774+00:00 app[web.1]: at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:60) ~[spring-orm-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989775+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:343) ~[spring-orm-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989778+00:00 app[web.1]:
2016-01-29T23:59:36.989778+00:00 app[web.1]: ... 22 common frames omitted
2016-01-29T23:59:36.989777+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.989776+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637) ~[spring-beans-4.2.4.RELEASE.jar!/:4.2.4.RELEASE]
2016-01-29T23:59:36.999565+00:00 app[web.1]: 2016-01-29 23:59:36.999 WARN 3 --- [ main] o.s.boot.SpringApplication : Error handling failed (Error creating bean with name 'delegatingApplicationListener' defined in class path resource [org/springframework/security/config/annotation/web/configuration/WebSecurityConfiguration.class]: BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'metaDataSourceAdvisor': Cannot resolve reference to bean 'methodSecurityMetadataSource' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.security.config.annotation.method.configuration.GlobalMethodSecurityConfiguration': Injection of autowired dependencies failed; nested exception is java.lang.RuntimeException: Could not postProcess org.springframework.security.access.expression.method.DefaultMethodSecurityExpressionHandler#61a1574f of typeclass org.springframework.security.access.expression.method.DefaultMethodSecurityExpressionHandler)
2016-01-29T23:59:38.029307+00:00 heroku[web.1]: Process exited with status 1
2016-01-29T23:59:38.042223+00:00 heroku[web.1]: State changed from starting to crashed
2016-01-29T23:59:40.076012+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=naturaapp.herokuapp.com request_id=8e5f90d5-40eb-470e-a765-f13eaa718b4d fwd="190.139.13.247" dyno= connect= service= status=503 bytes=
2016-01-29T23:59:41.412282+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=naturaapp.herokuapp.com request_id=47328aa0-860c-46ef-a345-4b17190a8329 fwd="190.139.13.247" dyno= connect= service= status=503 bytes=
And my application.properties have all that information that can't found on the deploying
db.driver: org.postgresql.Driver
db.url: jdbc:postgresql://190.139.xx.xxx:5432/poo2015
db.username: pooxxxx
db.password: pooxxxx
# Hibernate
hibernate.dialect: org.hibernate.dialect.PostgreSQLDialect
hibernate.show_sql: true
hibernate.hbm2ddl.auto: update
entitymanager.packagesToScan: com.arg.juy.natura
Sorry if this answer is too late.
That error was because the deploying exceed the timeout connecting to my local database. I solved ot using the database that heroku provides me for free.
Related
I upload the sample app to heroku and I have created the postgress database and I was able to connect using the heroku client using the same credentials provided by heroku database and when I go my app https://spring-boot-api-crud.herokuapp.com/
heroku logs --tail --app spring-boot-api-crud
Any idea what is the error about?
2021-01-22T01:44:00.404332+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:888) [hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.404332+00:00 app[web.1]: at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:57) [spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404332+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:365) [spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404332+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.buildNativeEntityManagerFactory(AbstractEntityManagerFactoryBean.java:390) [spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404333+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:377) [spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404333+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.afterPropertiesSet(LocalContainerEntityManagerFactoryBean.java:341) [spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404333+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1758) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404334+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1695) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404334+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:573) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404334+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:495) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404334+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:317) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404335+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404335+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:315) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404335+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) [spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404335+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1089) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404335+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:859) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404336+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:550) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.404336+00:00 app[web.1]: at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:140) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404336+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:780) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404336+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:412) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404336+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:333) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404337+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1277) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404341+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1265) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.404341+00:00 app[web.1]: at net.guides.springboot2.crud.Application.main(Application.java:15) ~[classes!/:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.404341+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.404342+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.404342+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.404342+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.404342+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) ~[springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.404343+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) ~[springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.404343+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) ~[springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.404343+00:00 app[web.1]: at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) ~[springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.404343+00:00 app[web.1]:
2021-01-22T01:44:00.404531+00:00 app[web.1]: 2021-01-22 01:44:00.404 WARN 4 --- [ main] o.h.e.j.e.i.JdbcEnvironmentInitiator : HHH000342: Could not obtain connection to query metadata : FATAL: role "ckinvlxnnpaagi" is not permitted to log in
2021-01-22T01:44:00.407672+00:00 app[web.1]: 2021-01-22 01:44:00.407 WARN 4 --- [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2021-01-22T01:44:00.412376+00:00 app[web.1]: 2021-01-22 01:44:00.412 INFO 4 --- [ main] o.apache.catalina.core.StandardService : Stopping service [Tomcat]
2021-01-22T01:44:00.461163+00:00 app[web.1]: 2021-01-22 01:44:00.460 INFO 4 --- [ main] ConditionEvaluationReportLoggingListener :
2021-01-22T01:44:00.461165+00:00 app[web.1]:
2021-01-22T01:44:00.461166+00:00 app[web.1]: Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2021-01-22T01:44:00.465789+00:00 app[web.1]: 2021-01-22 01:44:00.465 ERROR 4 --- [ main] o.s.boot.SpringApplication : Application run failed
2021-01-22T01:44:00.465790+00:00 app[web.1]:
2021-01-22T01:44:00.465805+00:00 app[web.1]: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.class]: Invocation of init method failed; nested exception is org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2021-01-22T01:44:00.465806+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1699) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465806+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:573) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465807+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:495) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465808+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:317) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465808+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465809+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:315) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465810+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465810+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1089) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465811+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:859) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465811+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:550) ~[spring-context-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465812+00:00 app[web.1]: at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:140) ~[spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465812+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:780) [spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465813+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:412) [spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465814+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:333) [spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465815+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1277) [spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465815+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1265) [spring-boot-2.0.5.RELEASE.jar!/:2.0.5.RELEASE]
2021-01-22T01:44:00.465816+00:00 app[web.1]: at net.guides.springboot2.crud.Application.main(Application.java:15) [classes!/:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.465817+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.465817+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.465818+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.465818+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_275-heroku]
2021-01-22T01:44:00.465819+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.465819+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.465820+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) [springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.465827+00:00 app[web.1]: at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) [springboot2-postgresql-jpa-hibernate-crud-example-0.0.1-SNAPSHOT.jar:0.0.1-SNAPSHOT]
2021-01-22T01:44:00.465828+00:00 app[web.1]: Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2021-01-22T01:44:00.465828+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:271) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465829+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:233) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465829+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:210) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465829+00:00 app[web.1]: at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:51) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465833+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:94) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465834+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:242) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465834+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:210) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465834+00:00 app[web.1]: at org.hibernate.boot.model.process.spi.MetadataBuildingProcess.handleTypes(MetadataBuildingProcess.java:352) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465835+00:00 app[web.1]: at org.hibernate.boot.model.process.spi.MetadataBuildingProcess.complete(MetadataBuildingProcess.java:111) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465835+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.metadata(EntityManagerFactoryBuilderImpl.java:861) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465835+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:888) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465836+00:00 app[web.1]: at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:57) ~[spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465836+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:365) ~[spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465837+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.buildNativeEntityManagerFactory(AbstractEntityManagerFactoryBean.java:390) ~[spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465837+00:00 app[web.1]: at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:377) ~[spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465837+00:00 app[web.1]: at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.afterPropertiesSet(LocalContainerEntityManagerFactoryBean.java:341) ~[spring-orm-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465838+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1758) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465838+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1695) ~[spring-beans-5.0.9.RELEASE.jar!/:5.0.9.RELEASE]
2021-01-22T01:44:00.465839+00:00 app[web.1]: ... 24 common frames omitted
2021-01-22T01:44:00.465839+00:00 app[web.1]: Caused by: org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set
2021-01-22T01:44:00.465839+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.determineDialect(DialectFactoryImpl.java:100) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465840+00:00 app[web.1]: at org.hibernate.engine.jdbc.dialect.internal.DialectFactoryImpl.buildDialect(DialectFactoryImpl.java:54) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465840+00:00 app[web.1]: at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService(JdbcEnvironmentInitiator.java:137) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465845+00:00 app[web.1]: at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService(JdbcEnvironmentInitiator.java:35) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465845+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.initiateService(StandardServiceRegistryImpl.java:88) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465845+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:259) ~[hibernate-core-5.2.17.Final.jar!/:5.2.17.Final]
2021-01-22T01:44:00.465846+00:00 app[web.1]: ... 41 common frames omitted
2021-01-22T01:44:00.465846+00:00 app[web.1]:
2021-01-22T01:44:00.563064+00:00 heroku[web.1]: Process exited with status 1
2021-01-22T01:44:00.600932+00:00 heroku[web.1]: State changed from starting to crashed
2021-01-22T01:44:43.067940+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=spring-boot-api-crud.herokuapp.com request_id=8ea3adeb-6c57-4f6d-879c-c00b610de7f7 fwd="75.10.187.93" dyno= connect= service= status=503 bytes= protocol=https
2021-01-22T01:44:43.690399+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=spring-boot-api-crud.herokuapp.com request_id=2cd4e5f1-6c5f-4c5f-8589-33ad5bcba06f fwd="75.10.187.93" dyno= connect= service= status=503 bytes= protocol=https
Looks like the source of your problem is here:
2021-01-22T01:44:00.404531+00:00 app[web.1]: 2021-01-22 01:44:00.404 WARN 4 --- [ main] o.h.e.j.e.i.JdbcEnvironmentInitiator : HHH000342: Could not obtain connection to query metadata : FATAL: role "ckinvlxnnpaagi" is not permitted to log in
The role looks like a Heroku database name. Check your database login credentials - URL, username, password.
Good luck.
I've never deployed any sort of JVM web app before so I really have no idea what's going on. From the Heroku log, the error looks to be the following:
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [tld.domain.webapp.FinancialServicesStationApp]; nested exception is java.lang.IllegalStateException: Error processing condition on org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$EmbeddedDatabaseConfiguration**
I am using MariaDB as my database, Gradle for building and the backend is written in kotlin. I used the option to compile the source code on my own machine, which I think should have worked since I can run the site in development mode just fine. Does someone know what could be causing this error and how I can fix it?
This is the full JHipster log:
2020-11-04T01:52:33.805989+00:00 app[web.1]: 2020-11-04 01:52:33.801 INFO 4 --- [ main] .f.FinancialServicesStationApp$Companion : The following profiles are active: prod,heroku
2020-11-04T01:52:35.007983+00:00 app[web.1]: 2020-11-04 01:52:35.007 WARN 4 --- [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [tld.domain.webapp.FinancialServicesStationApp]; nested exception is java.lang.IllegalStateException: Error processing condition on org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$EmbeddedDatabaseConfiguration
2020-11-04T01:52:35.025845+00:00 app[web.1]: 2020-11-04 01:52:35.025 ERROR 4 --- [ main] o.s.boot.SpringApplication : Application run failed
2020-11-04T01:52:35.025847+00:00 app[web.1]:
2020-11-04T01:52:35.025849+00:00 app[web.1]: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [tld.domain.webapp.FinancialServicesStationApp]; nested exception is java.lang.IllegalStateException: Error processing condition on org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$EmbeddedDatabaseConfiguration
2020-11-04T01:52:35.025850+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:609)
2020-11-04T01:52:35.025851+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.access$800(ConfigurationClassParser.java:110)
2020-11-04T01:52:35.025852+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.lambda$processGroupImports$1(ConfigurationClassParser.java:811)
2020-11-04T01:52:35.025853+00:00 app[web.1]: at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
2020-11-04T01:52:35.025854+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.processGroupImports(ConfigurationClassParser.java:808)
2020-11-04T01:52:35.025854+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorHandler.process(ConfigurationClassParser.java:779)
2020-11-04T01:52:35.025856+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:192)
2020-11-04T01:52:35.025856+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:319)
2020-11-04T01:52:35.025857+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:236)
2020-11-04T01:52:35.025857+00:00 app[web.1]: at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275)
2020-11-04T01:52:35.025858+00:00 app[web.1]: at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95)
2020-11-04T01:52:35.025858+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:706)
2020-11-04T01:52:35.025859+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:532)
2020-11-04T01:52:35.025859+00:00 app[web.1]: at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141)
2020-11-04T01:52:35.025860+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747)
2020-11-04T01:52:35.025861+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397)
2020-11-04T01:52:35.025862+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:315)
2020-11-04T01:52:35.025863+00:00 app[web.1]: at tld.domain.webapp.FinancialServicesStationApp$Companion.main(FinancialServicesStationApp.kt:105)
2020-11-04T01:52:35.025863+00:00 app[web.1]: at tld.domain.webapp.FinancialServicesStationApp.main(FinancialServicesStationApp.kt)
2020-11-04T01:52:35.025863+00:00 app[web.1]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2020-11-04T01:52:35.025864+00:00 app[web.1]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2020-11-04T01:52:35.025864+00:00 app[web.1]: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2020-11-04T01:52:35.025865+00:00 app[web.1]: at java.base/java.lang.reflect.Method.invoke(Method.java:564)
2020-11-04T01:52:35.025865+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
2020-11-04T01:52:35.025866+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
2020-11-04T01:52:35.025866+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:51)
2020-11-04T01:52:35.025866+00:00 app[web.1]: at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52)
2020-11-04T01:52:35.025867+00:00 app[web.1]: Caused by: java.lang.IllegalStateException: Error processing condition on org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$EmbeddedDatabaseConfiguration
2020-11-04T01:52:35.025867+00:00 app[web.1]: at org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:60)
2020-11-04T01:52:35.025868+00:00 app[web.1]: at org.springframework.context.annotation.ConditionEvaluator.shouldSkip(ConditionEvaluator.java:108)
2020-11-04T01:52:35.025868+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:225)
2020-11-04T01:52:35.025877+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.processMemberClasses(ConfigurationClassParser.java:371)
2020-11-04T01:52:35.025878+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:271)
2020-11-04T01:52:35.025878+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:249)
2020-11-04T01:52:35.025879+00:00 app[web.1]: at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:599)
2020-11-04T01:52:35.025879+00:00 app[web.1]: ... 26 common frames omitted
2020-11-04T01:52:35.025880+00:00 app[web.1]: Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'JDBC_DATABASE_URL' in value "${JDBC_DATABASE_URL}"
2020-11-04T01:52:35.025880+00:00 app[web.1]: at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:178)
2020-11-04T01:52:35.025880+00:00 app[web.1]: at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:124)
2020-11-04T01:52:35.025881+00:00 app[web.1]: at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:236)
2020-11-04T01:52:35.025881+00:00 app[web.1]: at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:210)
2020-11-04T01:52:35.025882+00:00 app[web.1]: at org.springframework.core.env.AbstractPropertyResolver.resolveNestedPlaceholders(AbstractPropertyResolver.java:227)
2020-11-04T01:52:35.025882+00:00 app[web.1]: at org.springframework.core.env.PropertySourcesPropertyResolver.getProperty(PropertySourcesPropertyResolver.java:88)
2020-11-04T01:52:35.025883+00:00 app[web.1]: at org.springframework.core.env.PropertySourcesPropertyResolver.getProperty(PropertySourcesPropertyResolver.java:62)
2020-11-04T01:52:35.025883+00:00 app[web.1]: at org.springframework.core.env.AbstractEnvironment.getProperty(AbstractEnvironment.java:535)
2020-11-04T01:52:35.025884+00:00 app[web.1]: at org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$EmbeddedDatabaseCondition.getMatchOutcome(DataSourceAutoConfiguration.java:126)
2020-11-04T01:52:35.025884+00:00 app[web.1]: at org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:47)
2020-11-04T01:52:35.025884+00:00 app[web.1]: ... 32 common frames omitted
2020-11-04T01:52:35.025885+00:00 app[web.1]:
2020-11-04T01:52:35.104335+00:00 heroku[web.1]: Process exited with status 1
2020-11-04T01:52:35.142760+00:00 heroku[web.1]: State changed from starting to crashed
2020-11-04T01:55:15.000000+00:00 app[api]: Build failed -- check your build output:
The important part of the error is:
Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'JDBC_DATABASE_URL' in value "${JDBC_DATABASE_URL}"
Heroku deployment could not inject the database properties into your application context and so it fails to start.
So, maybe you did not subscribe to jawsdb add-on or your did not register a payment method. There are few similar questions about this on stackoverflow
I suppose that you deployed using jhipster heroku as described in the doc: https://www.jhipster.tech/heroku/
I'm trying to deploy my springboot application in heroku. This application contains a spriboot back end and ionic framework for front end. All these are packaged in a war file, which is being deployed successfully in my local tomcat and also it works like a charm. When I try to deploy this on heroku, on deploying the Springboot it crashes with the following error:
2019-06-02T10:14:27.864513+00:00 app[web.1]: :: Spring Boot ::
(v2.1.5.RELEASE) 2019-06-02T10:14:27.864559+00:00 app[web.1]:
2019-06-02T10:14:28.086513+00:00 app[web.1]: 2019-06-02 10:14:28.081
INFO 4 --- [ost-startStop-1] c.m.g.movierama.MovieramaApplication
: Starting MovieramaApplication v0.0.1-SNAPSHOT on
5afc3cd9-f86f-466f-9b86-9f66bc5beae7 with PID 4
(/app/target/tomcat.12290/webapps/expanded/WEB-INF/classes started by
u40978 in /app) 2019-06-02T10:14:28.088166+00:00 app[web.1]:
2019-06-02 10:14:28.087 INFO 4 --- [ost-startStop-1]
c.m.g.movierama.MovieramaApplication : No active profile set,
falling back to default profiles: default
2019-06-02T10:14:29.523921+00:00 app[web.1]: 2019-06-02 10:14:29.521
INFO 4 --- [ost-startStop-1] .s.d.r.c.RepositoryConfigurationDelegate
: Bootstrapping Spring Data repositories in DEFAULT mode.
2019-06-02T10:14:29.562415+00:00 app[web.1]: 2019-06-02 10:14:29.562
INFO 4 --- [ost-startStop-1] .s.d.r.c.RepositoryConfigurationDelegate
: Finished Spring Data repository scanning in 26ms. Found 0 repository
interfaces. 2019-06-02T10:14:30.060948+00:00 app[web.1]: 2019-06-02
10:14:30.060 INFO 4 --- [ost-startStop-1]
faultConfiguringBeanFactoryPostProcessor : No bean named
'errorChannel' has been explicitly defined. Therefore, a default
PublishSubscribeChannel will be created.
2019-06-02T10:14:30.068963+00:00 app[web.1]: 2019-06-02 10:14:30.068
INFO 4 --- [ost-startStop-1] faultConfiguringBeanFactoryPostProcessor
: No bean named 'taskScheduler' has been explicitly defined.
Therefore, a default ThreadPoolTaskScheduler will be created.
2019-06-02T10:14:30.075260+00:00 app[web.1]: 2019-06-02 10:14:30.075
INFO 4 --- [ost-startStop-1] faultConfiguringBeanFactoryPostProcessor
: No bean named 'integrationHeaderChannelRegistry' has been explicitly
defined. Therefore, a default DefaultHeaderChannelRegistry will be
created. 2019-06-02T10:14:30.287747+00:00 app[web.1]: 2019-06-02
10:14:30.287 INFO 4 --- [ost-startStop-1]
trationDelegate$BeanPostProcessorChecker : Bean
'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration'
of type
[org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$c5e20e2a]
is not eligible for getting processed by all BeanPostProcessors (for
example: not eligible for auto-proxying)
2019-06-02T10:14:30.363779+00:00 app[web.1]: 2019-06-02 10:14:30.363
INFO 4 --- [ost-startStop-1] trationDelegate$BeanPostProcessorChecker
: Bean
'org.springframework.integration.config.IntegrationManagementConfiguration'
of type
[org.springframework.integration.config.IntegrationManagementConfiguration$$EnhancerBySpringCGLIB$$30d3c959]
is not eligible for getting processed by all BeanPostProcessors (for
example: not eligible for auto-proxying)
2019-06-02T10:14:30.399455+00:00 app[web.1]: 2019-06-02 10:14:30.399
INFO 4 --- [ost-startStop-1] trationDelegate$BeanPostProcessorChecker
: Bean 'integrationDisposableAutoCreatedBeans' of type
[org.springframework.integration.config.annotation.Disposables] is not
eligible for getting processed by all BeanPostProcessors (for example:
not eligible for auto-proxying) 2019-06-02T10:14:30.471157+00:00
app[web.1]: 2019-06-02 10:14:30.470 INFO 4 --- [ost-startStop-1]
o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring
embedded WebApplicationContext 2019-06-02T10:14:30.471413+00:00
app[web.1]: 2019-06-02 10:14:30.471 INFO 4 --- [ost-startStop-1]
o.s.web.context.ContextLoader : Root WebApplicationContext:
initialization completed in 2334 ms 2019-06-02T10:14:31.100545+00:00
app[web.1]: 2019-06-02 10:14:31.100 INFO 4 --- [ost-startStop-1]
com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Starting...
2019-06-02T10:14:31.767558+00:00 app[web.1]: 2019-06-02 10:14:31.767
INFO 4 --- [ost-startStop-1] com.zaxxer.hikari.HikariDataSource
: HikariPool-1 - Start completed. 2019-06-02T10:14:31.942093+00:00
app[web.1]: 2019-06-02 10:14:31.940 INFO 4 --- [ost-startStop-1]
o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing
PersistenceUnitInfo [ 2019-06-02T10:14:31.942096+00:00 app[web.1]:
name: default 2019-06-02T10:14:31.942098+00:00 app[web.1]: ...]
2019-06-02T10:14:32.216822+00:00 app[web.1]: 2019-06-02 10:14:32.216
INFO 4 --- [ost-startStop-1] org.hibernate.Version
: HHH000412: Hibernate Core {5.3.10.Final}
2019-06-02T10:14:32.223817+00:00 app[web.1]: 2019-06-02 10:14:32.223
INFO 4 --- [ost-startStop-1] org.hibernate.cfg.Environment
: HHH000206: hibernate.properties not found
2019-06-02T10:14:32.694566+00:00 app[web.1]: 2019-06-02 10:14:32.694
INFO 4 --- [ost-startStop-1] o.hibernate.annotations.common.Version
: HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
2019-06-02T10:14:33.118437+00:00 app[web.1]: 2019-06-02 10:14:33.118
INFO 4 --- [ost-startStop-1] org.hibernate.dialect.Dialect
: HHH000400: Using dialect: org.hibernate.dialect.MySQL5InnoDBDialect
2019-06-02T10:14:34.600268+00:00 app[web.1]: 2019-06-02 10:14:34.599
INFO 4 --- [ost-startStop-1] j.LocalContainerEntityManagerFactoryBean
: Initialized JPA EntityManagerFactory for persistence unit 'default'
2019-06-02T10:14:35.687724+00:00 heroku[web.1]: State changed from up
to crashed 2019-06-02T10:14:35.405611+00:00 app[web.1]: 2019-06-02
10:14:35.405 WARN 4 --- [ost-startStop-1]
ConfigServletWebServerApplicationContext : Exception encountered
during context initialization - cancelling refresh attempt:
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'requestMappingHandlerAdapter' defined in
class path resource
[org/springframework/boot/autoconfigure/web/servlet/WebMvcAutoConfiguration$EnableWebMvcConfiguration.class]:
Bean instantiation via factory method failed; nested exception is
org.springframework.beans.BeanInstantiationException: Failed to
instantiate
[org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter]:
Factory method 'requestMappingHandlerAdapter' threw exception; nested
exception is java.lang.BootstrapMethodError:
java.lang.IllegalAccessError: no such method:
io.reactivex.Flowable.fromPublisher(Publisher)Flowable/invokeStatic
2019-06-02T10:14:35.409906+00:00 app[web.1]: 2019-06-02 10:14:35.408
INFO 4 --- [ost-startStop-1] j.LocalContainerEntityManagerFactoryBean
: Closing JPA EntityManagerFactory for persistence unit 'default'
2019-06-02T10:14:35.415771+00:00 app[web.1]: 2019-06-02 10:14:35.415
INFO 4 --- [ost-startStop-1] com.zaxxer.hikari.HikariDataSource
: HikariPool-1 - Shutdown initiated...
2019-06-02T10:14:35.449333+00:00 app[web.1]: 2019-06-02 10:14:35.449
INFO 4 --- [ost-startStop-1] com.zaxxer.hikari.HikariDataSource
: HikariPool-1 - Shutdown completed. 2019-06-02T10:14:35.460889+00:00
app[web.1]: 2019-06-02 10:14:35.460 INFO 4 --- [ost-startStop-1]
ConditionEvaluationReportLoggingListener :
2019-06-02T10:14:35.460892+00:00 app[web.1]:
2019-06-02T10:14:35.460894+00:00 app[web.1]: Error starting
ApplicationContext. To display the conditions report re-run your
application with 'debug' enabled. 2019-06-02T10:14:35.470103+00:00
app[web.1]: 2019-06-02 10:14:35.469 ERROR 4 --- [ost-startStop-1]
o.s.boot.SpringApplication : Application run failed
2019-06-02T10:14:35.470106+00:00 app[web.1]:
2019-06-02T10:14:35.470111+00:00 app[web.1]:
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'requestMappingHandlerAdapter' defined in
class path resource
[org/springframework/boot/autoconfigure/web/servlet/WebMvcAutoConfiguration$EnableWebMvcConfiguration.class]:
Bean instantiation via factory method failed; nested exception is
org.springframework.beans.BeanInstantiationException: Failed to
instantiate
[org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter]:
Factory method 'requestMappingHandlerAdapter' threw exception; nested
exception is java.lang.BootstrapMethodError:
java.lang.IllegalAccessError: no such method:
io.reactivex.Flowable.fromPublisher(Publisher)Flowable/invokeStatic
2019-06-02T10:14:35.470113+00:00 app[web.1]: at
org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:627)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470114+00:00 app[web.1]: at
org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:607)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470117+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1321)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470118+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1160)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470124+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470125+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470127+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470128+00:00 app[web.1]: at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470129+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470131+00:00 app[web.1]: at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470132+00:00 app[web.1]: at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:843)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470133+00:00 app[web.1]: at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:877)
~[spring-context-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470135+00:00 app[web.1]: at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:549)
~[spring-context-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470136+00:00 app[web.1]: at
org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:142)
~[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470138+00:00 app[web.1]: at
org.springframework.boot.SpringApplication.refresh(SpringApplication.java:775)
~[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470139+00:00 app[web.1]: at
org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397)
~[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470141+00:00 app[web.1]: at
org.springframework.boot.SpringApplication.run(SpringApplication.java:316)
~[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470142+00:00 app[web.1]: at
org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:157)
[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470143+00:00 app[web.1]: at
org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:137)
[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470150+00:00 app[web.1]: at
org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:91)
[spring-boot-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470151+00:00 app[web.1]: at
org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:171)
[spring-web-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470153+00:00 app[web.1]: at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5272)
[webapp-runner.jar:na] 2019-06-02T10:14:35.470155+00:00 app[web.1]: at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
[webapp-runner.jar:na] 2019-06-02T10:14:35.470156+00:00 app[web.1]: at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1423)
[webapp-runner.jar:na] 2019-06-02T10:14:35.470157+00:00 app[web.1]: at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1413)
[webapp-runner.jar:na] 2019-06-02T10:14:35.470159+00:00 app[web.1]: at
java.util.concurrent.FutureTask.run(FutureTask.java:266)
[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470160+00:00 app[web.1]: at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470161+00:00 app[web.1]: at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470163+00:00 app[web.1]: at
java.lang.Thread.run(Thread.java:748) [na:1.8.0_212-heroku]
2019-06-02T10:14:35.470167+00:00 app[web.1]: Caused by:
org.springframework.beans.BeanInstantiationException: Failed to
instantiate
[org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter]:
Factory method 'requestMappingHandlerAdapter' threw exception; nested
exception is java.lang.BootstrapMethodError:
java.lang.IllegalAccessError: no such method:
io.reactivex.Flowable.fromPublisher(Publisher)Flowable/invokeStatic
2019-06-02T10:14:35.470169+00:00 app[web.1]: at
org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470171+00:00 app[web.1]: at
org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:622)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470173+00:00 app[web.1]: ... 28 common frames
omitted 2019-06-02T10:14:35.470174+00:00 app[web.1]: Caused by:
java.lang.BootstrapMethodError: java.lang.IllegalAccessError: no such
method:
io.reactivex.Flowable.fromPublisher(Publisher)Flowable/invokeStatic
2019-06-02T10:14:35.470176+00:00 app[web.1]: at
org.springframework.core.ReactiveAdapterRegistry$RxJava2Registrar.registerAdapters(ReactiveAdapterRegistry.java:248)
~[spring-core-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470177+00:00 app[web.1]: at
org.springframework.core.ReactiveAdapterRegistry.(ReactiveAdapterRegistry.java:83)
~[spring-core-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470178+00:00 app[web.1]: at
org.springframework.core.ReactiveAdapterRegistry.getSharedInstance(ReactiveAdapterRegistry.java:179)
~[spring-core-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470180+00:00 app[web.1]: at
org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.(RequestMappingHandlerAdapter.java:168)
~[spring-webmvc-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470181+00:00 app[web.1]: at
org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport.createRequestMappingHandlerAdapter(WebMvcConfigurationSupport.java:593)
~[spring-webmvc-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470185+00:00 app[web.1]: at
org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration.createRequestMappingHandlerAdapter(WebMvcAutoConfiguration.java:496)
~[spring-boot-autoconfigure-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470186+00:00 app[web.1]: at
org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport.requestMappingHandlerAdapter(WebMvcConfigurationSupport.java:561)
~[spring-webmvc-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470188+00:00 app[web.1]: at
org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration.requestMappingHandlerAdapter(WebMvcAutoConfiguration.java:484)
~[spring-boot-autoconfigure-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470205+00:00 app[web.1]: at
org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration$$EnhancerBySpringCGLIB$$30cf5eaa.CGLIB$requestMappingHandlerAdapter$7()
~[spring-boot-autoconfigure-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470206+00:00 app[web.1]: at
org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration$$EnhancerBySpringCGLIB$$30cf5eaa$$FastClassBySpringCGLIB$$5e7c894e.invoke()
~[spring-boot-autoconfigure-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470213+00:00 app[web.1]: at
org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244)
~[spring-core-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470214+00:00 app[web.1]: at
org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:363)
~[spring-context-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470216+00:00 app[web.1]: at
org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration$$EnhancerBySpringCGLIB$$30cf5eaa.requestMappingHandlerAdapter()
~[spring-boot-autoconfigure-2.1.5.RELEASE.jar:2.1.5.RELEASE]
2019-06-02T10:14:35.470217+00:00 app[web.1]: at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470219+00:00 app[web.1]: at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470220+00:00 app[web.1]: at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470222+00:00 app[web.1]: at
java.lang.reflect.Method.invoke(Method.java:498)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470223+00:00 app[web.1]: at
org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
~[spring-beans-5.1.7.RELEASE.jar:5.1.7.RELEASE]
2019-06-02T10:14:35.470224+00:00 app[web.1]: ... 29 common frames
omitted 2019-06-02T10:14:35.470226+00:00 app[web.1]: Caused by:
java.lang.IllegalAccessError: no such method:
io.reactivex.Flowable.fromPublisher(Publisher)Flowable/invokeStatic
2019-06-02T10:14:35.470227+00:00 app[web.1]: at
java.lang.invoke.MethodHandleNatives.linkMethodHandleConstant(MethodHandleNatives.java:483)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470228+00:00 app[web.1]:
... 47 common frames omitted 2019-06-02T10:14:35.470231+00:00
app[web.1]: Caused by: java.lang.LinkageError: loader constraint
violation: when resolving method
"io.reactivex.Flowable.fromPublisher(Lorg/reactivestreams/Publisher;)Lio/reactivex/Flowable;"
the class loader (instance of
org/apache/catalina/loader/ParallelWebappClassLoader) of the current
class,
org/springframework/core/ReactiveAdapterRegistry$RxJava2Registrar, and
the class loader (instance of sun/misc/Launcher$AppClassLoader) for
the method's defining class, io/reactivex/Flowable, have different
Class objects for the type org/reactivestreams/Publisher used in the
signature 2019-06-02T10:14:35.470232+00:00 app[web.1]: at
java.lang.invoke.MethodHandleNatives.resolve(Native Method)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470234+00:00 app[web.1]: at
java.lang.invoke.MemberName$Factory.resolve(MemberName.java:975)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470235+00:00 app[web.1]: at
java.lang.invoke.MemberName$Factory.resolveOrFail(MemberName.java:1000)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470236+00:00 app[web.1]: at
java.lang.invoke.MethodHandles$Lookup.resolveOrFail(MethodHandles.java:1394)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470238+00:00 app[web.1]: at
java.lang.invoke.MethodHandles$Lookup.linkMethodHandleConstant(MethodHandles.java:1750)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470239+00:00 app[web.1]: at
java.lang.invoke.MethodHandleNatives.linkMethodHandleConstant(MethodHandleNatives.java:477)
~[na:1.8.0_212-heroku] 2019-06-02T10:14:35.470240+00:00 app[web.1]:
... 47 common frames omitted
My application was running fine locally but when I deployed to heroku, I got application error. I tried several times the same thing happening. I checked database connection and everything is fine. These are my logs
2017-06-13T09:20:30.840039+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2017-06-13T09:20:30.840041+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
2017-06-13T09:20:30.840040+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2017-06-13T09:20:30.840042+00:00 app[web.1]: at org.springframework.boot.loader.WarLauncher.main(WarLauncher.java:59)
2017-06-13T09:20:30.840040+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
2017-06-13T09:20:30.840042+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:50)
2017-06-13T09:20:30.937134+00:00 app[web.1]: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'com.ryantenney.metrics.spring.config.annotation.Dele
gatingMetricsConfiguration': Unsatisfied dependency expressed through method 'setMetricsConfigurers' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyExcep
tion: Error creating bean with name 'metricsConfiguration': Unsatisfied dependency expressed through method 'setHikariDataSource' parameter 0; nested exception is org.springframework.beans.facto
ry.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Hikari.class]: Bean insta
ntiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.zaxxer.hikari.HikariDataSource]: Factory method 'dataSour
ce' threw exception; nested exception is java.lang.IllegalArgumentException: URL must start with 'jdbc'
2017-06-13T09:20:30.840043+00:00 app[web.1]:
2017-06-13T09:20:30.937128+00:00 app[web.1]: 2017-06-13 09:20:30.935 ERROR 4 --- [ main] o.s.boot.SpringApplication : Application startup failed
2017-06-13T09:20:30.937130+00:00 app[web.1]:
2017-06-13T09:20:30.937136+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredMethodElement.inject(AutowiredAnnotationBeanPostProc
essor.java:667)
2017-06-13T09:20:30.937139+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1264)
2017-06-13T09:20:30.937137+00:00 app[web.1]: at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
2017-06-13T09:20:30.937138+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcesso
r.java:366)
2017-06-13T09:20:30.937140+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)
2017-06-13T09:20:30.937139+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:553)
2017-06-13T09:20:30.937143+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
2017-06-13T09:20:30.937141+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
2017-06-13T09:20:30.937141+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
2017-06-13T09:20:30.937142+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
2017-06-13T09:20:30.937143+00:00 app[web.1]: at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:372)
2017-06-13T09:20:30.937146+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)
2017-06-13T09:20:30.937144+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.j
ava:1173)
2017-06-13T09:20:30.937147+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
2017-06-13T09:20:30.937145+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1067)
2017-06-13T09:20:30.937146+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:513)
2017-06-13T09:20:30.937150+00:00 app[web.1]: at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:235)
2017-06-13T09:20:30.937148+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
2017-06-13T09:20:30.937148+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
2017-06-13T09:20:30.937149+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
2017-06-13T09:20:30.937150+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:703)
2017-06-13T09:20:30.937151+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:528)
2017-06-13T09:20:30.937158+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:360)
2017-06-13T09:20:30.937156+00:00 app[web.1]: at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)
2017-06-13T09:20:30.937159+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:303)
2017-06-13T09:20:30.937157+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:693)
2017-06-13T09:20:30.937160+00:00 app[web.1]: at com.mycompany.myapp.Blog3App.main(Blog3App.java:66)
2017-06-13T09:20:30.937161+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2017-06-13T09:20:30.937160+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2017-06-13T09:20:30.937161+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2017-06-13T09:20:30.937162+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2017-06-13T09:20:30.937165+00:00 app[web.1]: at org.springframework.boot.loader.WarLauncher.main(WarLauncher.java:59)
2017-06-13T09:20:30.937163+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
2017-06-13T09:20:30.937166+00:00 app[web.1]: Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'metricsConfiguration': Unsatisfied depend
ency expressed through method 'setHikariDataSource' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined i
n class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Hikari.class]: Bean instantiation via factory method failed; nested exception is org.springframework.be
ans.BeanInstantiationException: Failed to instantiate [com.zaxxer.hikari.HikariDataSource]: Factory method 'dataSource' threw exception; nested exception is java.lang.IllegalArgumentException: U
RL must start with 'jdbc'
2017-06-13T09:20:30.937163+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
2017-06-13T09:20:30.937164+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:50)
2017-06-13T09:20:30.937169+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1264)
2017-06-13T09:20:30.937167+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredMethodElement.inject(AutowiredAnnotationBeanPostProc
essor.java:667)
2017-06-13T09:20:30.937167+00:00 app[web.1]: at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
2017-06-13T09:20:30.937168+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcesso
r.java:366)
2017-06-13T09:20:30.937169+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:553)
2017-06-13T09:20:30.937170+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)
2017-06-13T09:20:30.937171+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
2017-06-13T09:20:30.937172+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
2017-06-13T09:20:30.937171+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
2017-06-13T09:20:30.937173+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
2017-06-13T09:20:30.937175+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveMultipleBeans(DefaultListableBeanFactory.java:1180)
2017-06-13T09:20:30.937173+00:00 app[web.1]: at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:208)
2017-06-13T09:20:30.937174+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.addCandidateEntry(DefaultListableBeanFactory.java:1316)
2017-06-13T09:20:30.937175+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:1282)
2017-06-13T09:20:30.937176+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1096)
2017-06-13T09:20:30.937177+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1066)
2017-06-13T09:20:30.937193+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/sp
ringframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Hikari.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationExceptio
n: Failed to instantiate [com.zaxxer.hikari.HikariDataSource]: Factory method 'dataSource' threw exception; nested exception is java.lang.IllegalArgumentException: URL must start with 'jdbc'
2017-06-13T09:20:30.937178+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredMethodElement.inject(AutowiredAnnotationBeanPostProc
essor.java:659)
2017-06-13T09:20:30.937178+00:00 app[web.1]: ... 34 common frames omitted
2017-06-13T09:20:30.937195+00:00 app[web.1]: at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:599)
2017-06-13T09:20:30.937196+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.j
ava:1173)
2017-06-13T09:20:30.937198+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)
2017-06-13T09:20:30.937196+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1067)
2017-06-13T09:20:30.937197+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:513)
2017-06-13T09:20:30.937201+00:00 app[web.1]: at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:208)
2017-06-13T09:20:30.937199+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
2017-06-13T09:20:30.937202+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1138)
2017-06-13T09:20:30.937199+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
2017-06-13T09:20:30.937200+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
2017-06-13T09:20:30.937200+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
2017-06-13T09:20:30.937205+00:00 app[web.1]: Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.zaxxer.hikari.HikariDataSource]: Factory method 'dataSour
ce' threw exception; nested exception is java.lang.IllegalArgumentException: URL must start with 'jdbc'
2017-06-13T09:20:30.937202+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1066)
2017-06-13T09:20:30.937203+00:00 app[web.1]: at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredMethodElement.inject(AutowiredAnnotationBeanPostProc
essor.java:659)
2017-06-13T09:20:30.937204+00:00 app[web.1]: ... 50 common frames omitted
2017-06-13T09:20:30.937206+00:00 app[web.1]: at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189)
2017-06-13T09:20:30.937209+00:00 app[web.1]: at org.springframework.util.Assert.isTrue(Assert.java:92)
2017-06-13T09:20:30.937207+00:00 app[web.1]: at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)
2017-06-13T09:20:30.937209+00:00 app[web.1]: at org.springframework.boot.jdbc.DatabaseDriver.fromJdbcUrl(DatabaseDriver.java:268)
2017-06-13T09:20:30.937207+00:00 app[web.1]: ... 62 common frames omitted
2017-06-13T09:20:30.937208+00:00 app[web.1]: Caused by: java.lang.IllegalArgumentException: URL must start with 'jdbc'
2017-06-13T09:20:30.937212+00:00 app[web.1]: at org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration$Hikari.dataSource(DataSourceConfiguration.java:80)
2017-06-13T09:20:30.937210+00:00 app[web.1]: at org.springframework.boot.autoconfigure.jdbc.DataSourceProperties.determineDriverClassName(DataSourceProperties.java:238)
2017-06-13T09:20:30.937211+00:00 app[web.1]: at org.springframework.boot.autoconfigure.jdbc.DataSourceProperties.initializeDataSourceBuilder(DataSourceProperties.java:183)
2017-06-13T09:20:30.937211+00:00 app[web.1]: at org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration.createDataSource(DataSourceConfiguration.java:42)
2017-06-13T09:20:30.937215+00:00 app[web.1]: at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)
2017-06-13T09:20:30.937213+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2017-06-13T09:20:30.937216+00:00 app[web.1]: ... 63 common frames omitted
2017-06-13T09:20:30.937213+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2017-06-13T09:20:30.937214+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2017-06-13T09:20:30.937215+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2017-06-13T09:20:30.937217+00:00 app[web.1]:
2017-06-13T09:20:31.436235+00:00 heroku[web.1]: Process exited with status 1
2017-06-13T09:20:31.460943+00:00 heroku[web.1]: State changed from starting to crashed
2017-06-13T09:24:12.753908+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=serene-citadel-75498.herokuapp.com request_id=66b02e97-98a8-442c-85f1-d889ad25ec01
fwd="84.54.96.137" dyno= connect= service= status=503 bytes= protocol=https
2017-06-13T09:24:13.555911+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=serene-citadel-75498.herokuapp.com request_id=4a28374e-0005-4ed5-bc26-1b
0a799f76bb fwd="84.54.96.137" dyno= connect= service= status=503 bytes= protocol=https
EDIT : applicaiton-prod.yml:
datasource:
type: com.zaxxer.hikari.HikariDataSource
url: jdbc:mysql://localhost:3306/db?useUnicode=true&characterEncoding=utf8&useSSL=false
username: root
password: password
applicaiton-heroku.yml:
datasource:
type: com.zaxxer.hikari.HikariDataSource
url: ${JDBC_DATABASE_URL}
username: ${JDBC_DATABASE_USERNAME}
password: ${JDBC_DATABASE_PASSWORD}
If your Heroku account has not been verified, then you cannot install AddOns (such as the Database AddOn). You can solve this by adding a credit card in Heroku's dashboard. Full instructions can be found in Heroku's docs:
To verify your Heroku account:
1) Go to your account page.
2) Click the Billing tab.
3) Click Add Credit Card.
This error is now printed during deployment in JHipster v4.5.3+, in previous versions it was ignored silently.
I am attempting to deploy my webapp to heroku. Since Heroku does not allow the use of a Hibernate DB, I have setup a postgres addon and attempted to configure my app to use it.
However, when I deploy my app, it builds successfully, but when I try to open the app I get an application error. It appears that the tomcat server is unable to connect to the postgres database, and for some reason it looks like its trying to connect to localhost. The Heroku logs are at the bottom of this post.
DataConfig.java
#Configuration
public class DataConfig {
#Autowired
private Environment env;
#Bean
#Primary
#ConfigurationProperties(prefix = "newsitem.db")
public DataSource dataSource() {
BasicDataSource ds = new BasicDataSource();
ds.setDriverClassName(env.getProperty("newsitem.db.driver"));
ds.setUrl(env.getProperty("newsitem.db.url"));
ds.setUsername(env.getProperty("newsitem.db.username"));
ds.setPassword(env.getProperty("newsitem.db.password"));
return ds;
}
app.properties
newsitem.db.url=${JDBC_DATABASE_URL}
newsitem.db.driver=org.postgresql.Driver
newsitem.db.username=${JDBC_DATABASE_USERNAME}
newsitem.db.password=${JDBC_DATABASE_PASSWORD}
This appears to be the primary cause of failure:
Caused by: org.h2.jdbc.JdbcSQLException: Connection is broken: "java.net.ConnectException: Connection refused (Connection refused): localhost" [90067-191]
Heroku logs:
2017-05-03T04:32:52.564241+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:513) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564242+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564245+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564246+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564246+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564247+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564248+00:00 app[web.1]: at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:759) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564249+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:866) ~[spring-context-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564250+00:00 app[web.1]: at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:542) ~[spring-context-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564250+00:00 app[web.1]: at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122) ~[spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564251+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761) [spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564252+00:00 app[web.1]: at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:371) [spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564253+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:315) [spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564253+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1186) [spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564254+00:00 app[web.1]: at org.springframework.boot.SpringApplication.run(SpringApplication.java:1175) [spring-boot-1.4.3.RELEASE.jar!/:1.4.3.RELEASE]
2017-05-03T04:32:52.564255+00:00 app[web.1]: at com.doronzehavi.newsitemweb.Application.main(Application.java:16) [classes!/:na]
2017-05-03T04:32:52.564256+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564256+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564257+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564258+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564259+00:00 app[web.1]: at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [newsitemweb-0.0.1-SNAPSHOT.jar:na]
2017-05-03T04:32:52.564279+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [newsitemweb-0.0.1-SNAPSHOT.jar:na]
2017-05-03T04:32:52.564280+00:00 app[web.1]: at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) [newsitemweb-0.0.1-SNAPSHOT.jar:na]
2017-05-03T04:32:52.564280+00:00 app[web.1]: at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) [newsitemweb-0.0.1-SNAPSHOT.jar:na]
2017-05-03T04:32:52.564282+00:00 app[web.1]: Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.doronzehavi.newsitemweb.dao.NewsSourceDaoImpl]: Constructor threw exception; nested exception is javax.persistence.PersistenceException: Unable to build entity manager factory
2017-05-03T04:32:52.564282+00:00 app[web.1]: at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:154) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564283+00:00 app[web.1]: at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:89) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564284+00:00 app[web.1]: at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1108) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564285+00:00 app[web.1]: ... 25 common frames omitted
2017-05-03T04:32:52.564286+00:00 app[web.1]: Caused by: javax.persistence.PersistenceException: Unable to build entity manager factory
2017-05-03T04:32:52.564286+00:00 app[web.1]: at org.hibernate.jpa.HibernatePersistenceProvider.createEntityManagerFactory(HibernatePersistenceProvider.java:66) ~[hibernate-entitymanager-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564287+00:00 app[web.1]: at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:55) ~[hibernate-jpa-2.1-api-1.0.0.Final.jar!/:1.0.0.Final]
2017-05-03T04:32:52.564288+00:00 app[web.1]: at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:39) ~[hibernate-jpa-2.1-api-1.0.0.Final.jar!/:1.0.0.Final]
2017-05-03T04:32:52.564288+00:00 app[web.1]: at com.doronzehavi.newsitemweb.dao.NewsSourceDaoImpl.<init>(NewsSourceDaoImpl.java:23) ~[classes!/:na]
2017-05-03T04:32:52.564289+00:00 app[web.1]: at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564290+00:00 app[web.1]: at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564290+00:00 app[web.1]: at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564291+00:00 app[web.1]: at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564298+00:00 app[web.1]: at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:142) ~[spring-beans-4.3.5.RELEASE.jar!/:4.3.5.RELEASE]
2017-05-03T04:32:52.564299+00:00 app[web.1]: ... 27 common frames omitted
2017-05-03T04:32:52.564300+00:00 app[web.1]: Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]
2017-05-03T04:32:52.564300+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:264) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564301+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:228) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564302+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:207) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564302+00:00 app[web.1]: at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:51) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564303+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:94) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564304+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:237) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564304+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:207) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564306+00:00 app[web.1]: at org.hibernate.boot.model.process.spi.MetadataBuildingProcess.handleTypes(MetadataBuildingProcess.java:352) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564307+00:00 app[web.1]: at org.hibernate.boot.model.process.spi.MetadataBuildingProcess.complete(MetadataBuildingProcess.java:111) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564311+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.metadata(EntityManagerFactoryBuilderImpl.java:847) ~[hibernate-entitymanager-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564312+00:00 app[web.1]: at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:874) ~[hibernate-entitymanager-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564312+00:00 app[web.1]: at org.hibernate.jpa.HibernatePersistenceProvider.createEntityManagerFactory(HibernatePersistenceProvider.java:58) ~[hibernate-entitymanager-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564313+00:00 app[web.1]: ... 35 common frames omitted
2017-05-03T04:32:52.564313+00:00 app[web.1]: Caused by: org.hibernate.exception.JDBCConnectionException: Error calling Driver#connect
2017-05-03T04:32:52.564314+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.BasicConnectionCreator$1$1.convert(BasicConnectionCreator.java:105) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564315+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.BasicConnectionCreator.convertSqlException(BasicConnectionCreator.java:123) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564315+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.DriverConnectionCreator.makeConnection(DriverConnectionCreator.java:41) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564316+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.BasicConnectionCreator.createConnection(BasicConnectionCreator.java:58) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564317+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.PooledConnections.addConnections(PooledConnections.java:106) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564317+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.PooledConnections.<init>(PooledConnections.java:40) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564318+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.PooledConnections.<init>(PooledConnections.java:19) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564319+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.PooledConnections$Builder.build(PooledConnections.java:138) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564319+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl.buildPool(DriverManagerConnectionProviderImpl.java:110) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564320+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl.configure(DriverManagerConnectionProviderImpl.java:74) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564321+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:94) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564322+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:237) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564323+00:00 app[web.1]: at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.buildJdbcConnectionAccess(JdbcEnvironmentInitiator.java:145) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564324+00:00 app[web.1]: at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService(JdbcEnvironmentInitiator.java:66) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564325+00:00 app[web.1]: at org.hibernate.engine.jdbc.env.internal.JdbcEnvironmentInitiator.initiateService(JdbcEnvironmentInitiator.java:35) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564323+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:207) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564325+00:00 app[web.1]: at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.initiateService(StandardServiceRegistryImpl.java:88) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564326+00:00 app[web.1]: at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:254) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564327+00:00 app[web.1]: ... 46 common frames omitted
2017-05-03T04:32:52.564327+00:00 app[web.1]: Caused by: org.h2.jdbc.JdbcSQLException: Connection is broken: "java.net.ConnectException: Connection refused (Connection refused): localhost" [90067-191]
2017-05-03T04:32:52.564334+00:00 app[web.1]: at org.h2.message.DbException.getJdbcSQLException(DbException.java:345) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564335+00:00 app[web.1]: at org.h2.message.DbException.get(DbException.java:168) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564340+00:00 app[web.1]: at org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:329) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564340+00:00 app[web.1]: at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:107) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564341+00:00 app[web.1]: at org.h2.jdbc.JdbcConnection.<init>(JdbcConnection.java:91) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564339+00:00 app[web.1]: at org.h2.engine.SessionRemote.connectServer(SessionRemote.java:452) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564341+00:00 app[web.1]: at org.h2.Driver.connect(Driver.java:72) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564343+00:00 app[web.1]: at org.hibernate.engine.jdbc.connections.internal.DriverConnectionCreator.makeConnection(DriverConnectionCreator.java:38) ~[hibernate-core-5.0.11.Final.jar!/:5.0.11.Final]
2017-05-03T04:32:52.564344+00:00 app[web.1]: ... 61 common frames omitted
2017-05-03T04:32:52.564344+00:00 app[web.1]: Caused by: java.net.ConnectException: Connection refused (Connection refused)
2017-05-03T04:32:52.564345+00:00 app[web.1]: at java.net.PlainSocketImpl.socketConnect(Native Method) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564346+00:00 app[web.1]: at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564347+00:00 app[web.1]: at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564347+00:00 app[web.1]: at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564348+00:00 app[web.1]: at java.net.Socket.connect(Socket.java:589) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564349+00:00 app[web.1]: at org.h2.util.NetUtils.createSocket(NetUtils.java:122) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564349+00:00 app[web.1]: at org.h2.util.NetUtils.createSocket(NetUtils.java:102) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564346+00:00 app[web.1]: at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) ~[na:1.8.0_121-cedar14]
2017-05-03T04:32:52.564350+00:00 app[web.1]: at org.h2.engine.SessionRemote.initTransfer(SessionRemote.java:114) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564350+00:00 app[web.1]: at org.h2.engine.SessionRemote.connectServer(SessionRemote.java:448) ~[h2-1.4.191.jar!/:na]
2017-05-03T04:32:52.564351+00:00 app[web.1]: ... 66 common frames omitted
2017-05-03T04:32:52.564351+00:00 app[web.1]:
2017-05-03T04:32:52.683659+00:00 heroku[web.1]: Process exited with status 1
2017-05-03T04:32:52.698197+00:00 heroku[web.1]: State changed from starting to crashed
2017-05-03T04:33:21.797903+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=intense-hamlet-29713.herokuapp.com request_id=9d7158ad-6410-49bd-83d0-c072f54fdc81 fwd="198.27.128.5" dyno= connect= service= status=503 bytes= protocol=https
2017-05-03T04:33:22.569682+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=intense-hamlet-29713.herokuapp.com request_id=2894c36e-db93-472e-9faf-553db67c84db fwd="198.27.128.5" dyno= connect= service= status=503 bytes= protocol=https
You are using the H2 db driver. Look at this line in the stacktrace :
org.h2.Driver.connect(Driver.java:72) ~[h2-1.4.191.jar!/:na]
Use the right jdbc driver.