jhipster / generator-jhipster

JHipster is a development platform to quickly generate, develop, & deploy modern web applications & microservice architectures.
https://www.jhipster.tech
Apache License 2.0
21.48k stars 4.02k forks source link

Heroku Application Error #700

Closed MartinLichtblau closed 9 years ago

MartinLichtblau commented 9 years ago

I'm confronted with the following error. I use the original jhipster-sample-app and the heroku subgenerator to get it all running on heroku. But when I try to open the webapp it crashes. Any ideas why it doesn't fill in the right address for "$DATABASE_URL"? Or what else has to be done to deploy it on heroku?

heroku_application_error

2014-10-29T14:06:15+00:00 heroku[slug-compiler]: Slug compilation started
2014-10-29T14:07:26+00:00 heroku[slug-compiler]: Slug compilation finished
2014-10-29T14:07:25.867767+00:00 heroku[api]: Deploy 8c770cc by xxx@xx
2014-10-29T14:07:25.867843+00:00 heroku[api]: Release v6 created by xxx@xx
2014-10-29T14:07:56.244257+00:00 heroku[web.1]: State changed from down to start
ing
2014-10-29T14:07:56.244257+00:00 heroku[web.1]: Unidling
2014-10-29T14:08:10.618010+00:00 heroku[web.1]: Starting process with command `j
ava -Xmx384m -Xss512k -XX:+UseCompressedOops -jar target/*.war --spring.profiles
.active=prod --server.port=40709  --spring.datasource.heroku-url=$DATABASE_URL`
2014-10-29T14:08:11.183589+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS:  -Djav
a.rmi.server.useCodebaseOnly=true -Djava.rmi.server.useCodebaseOnly=true
2014-10-29T14:08:12.564860+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke0(Native Method)
2014-10-29T14:08:12.564907+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke(NativeMethodAccessorImpl.java:62)
2014-10-29T14:08:12.564954+00:00 app[web.1]:    at sun.reflect.DelegatingMethodA
ccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2014-10-29T14:08:12.564999+00:00 app[web.1]:    at java.lang.reflect.Method.invo
ke(Method.java:483)
2014-10-29T14:08:12.565045+00:00 app[web.1]:    at org.springframework.boot.load
er.MainMethodRunner.run(MainMethodRunner.java:53)
2014-10-29T14:08:12.565090+00:00 app[web.1]:    at java.lang.Thread.run(Thread.j
ava:745)
2014-10-29T14:08:12.565212+00:00 app[web.1]: Caused by: java.lang.IllegalArgumen
tException: Invalid argument syntax: --spring.datasource.heroku-url=
2014-10-29T14:08:12.565260+00:00 app[web.1]:    at org.springframework.core.env.
SimpleCommandLineArgsParser.parse(SimpleCommandLineArgsParser.java:75)
2014-10-29T14:08:12.565307+00:00 app[web.1]:    at org.springframework.core.env.
SimpleCommandLinePropertySource.<init>(SimpleCommandLinePropertySource.java:87)
2014-10-29T14:08:12.565380+00:00 app[web.1]:    at com.mycompany.myapp.Applicati
on.main(Application.java:50)
2014-10-29T14:08:12.565432+00:00 app[web.1]:    ... 6 more
2014-10-29T14:08:12.564725+00:00 app[web.1]: java.lang.reflect.InvocationTargetE
xception
2014-10-29T14:08:13.295704+00:00 heroku[web.1]: Process exited with status 1
2014-10-29T14:08:13.304874+00:00 heroku[web.1]: State changed from starting to c
rashed
2014-10-29T14:08:13.305623+00:00 heroku[web.1]: State changed from crashed to st
arting
2014-10-29T14:08:24.901667+00:00 heroku[web.1]: Starting process with command `j
ava -Xmx384m -Xss512k -XX:+UseCompressedOops -jar target/*.war --spring.profiles
.active=prod --server.port=43918  --spring.datasource.heroku-url=$DATABASE_URL`
2014-10-29T14:08:25.664944+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS:  -Djav
a.rmi.server.useCodebaseOnly=true -Djava.rmi.server.useCodebaseOnly=true
2014-10-29T14:08:27.303552+00:00 app[web.1]: java.lang.reflect.InvocationTargetE
xception
2014-10-29T14:08:27.303959+00:00 app[web.1]:    at sun.reflect.DelegatingMethodA
ccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2014-10-29T14:08:27.304581+00:00 app[web.1]:    at com.mycompany.myapp.Applicati
on.main(Application.java:50)
2014-10-29T14:08:27.303739+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke0(Native Method)
2014-10-29T14:08:27.303965+00:00 app[web.1]:    at java.lang.reflect.Method.invo
ke(Method.java:483)
2014-10-29T14:08:27.303967+00:00 app[web.1]:    at org.springframework.boot.load
er.MainMethodRunner.run(MainMethodRunner.java:53)
2014-10-29T14:08:27.303968+00:00 app[web.1]:    at java.lang.Thread.run(Thread.j
ava:745)
2014-10-29T14:08:27.304083+00:00 app[web.1]: Caused by: java.lang.IllegalArgumen
tException: Invalid argument syntax: --spring.datasource.heroku-url=
2014-10-29T14:08:27.304140+00:00 app[web.1]:    at org.springframework.core.env.
SimpleCommandLineArgsParser.parse(SimpleCommandLineArgsParser.java:75)
2014-10-29T14:08:27.304186+00:00 app[web.1]:    at org.springframework.core.env.
SimpleCommandLinePropertySource.<init>(SimpleCommandLinePropertySource.java:87)
2014-10-29T14:08:27.304659+00:00 app[web.1]:    ... 6 more
2014-10-29T14:08:27.303798+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke(NativeMethodAccessorImpl.java:62)
2014-10-29T14:08:28.030505+00:00 heroku[web.1]: Process exited with status 1
2014-10-29T14:08:28.042503+00:00 heroku[web.1]: State changed from starting to c
rashed
2014-10-29T14:08:29.321809+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=senlima.herokuapp.com request_id=f7e55783-552f-42
30-9681-b0c39a484902 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=

2014-10-29T14:08:29.329157+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=senlima.herokuapp.com request_id=e91115bb-7f11-41
7e-b2a8-71211f6aa66e fwd="184.72.147.6" dyno= connect= service= status=503 bytes
=
2014-10-29T14:08:30.556504+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=senlima.herokuapp.com request_id=01bd9
ec8-3e00-4a81-8c53-30d9dd008d42 fwd="94.16.78.72" dyno= connect= service= status
=503 bytes=
2014-10-29T14:10:40.626599+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=senlima.herokuapp.com request_id=dab5a518-7169-4c
fd-9bb6-5bb13c3f15f6 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=

2014-10-29T14:10:41.041822+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=senlima.herokuapp.com request_id=033ba
70d-b0af-4592-b6b2-22f2102f1502 fwd="94.16.78.72" dyno= connect= service= status
=503 bytes=
2014-10-29T14:55:46.128844+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=senlima.herokuapp.com request_id=b52723f8-73af-41
68-8061-cb94df5022c9 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=

2014-10-29T14:55:46.689563+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=senlima.herokuapp.com request_id=2bb9b
2e7-364d-420b-ba13-28f7fdb5d531 fwd="94.16.78.72" dyno= connect= service= status
=503 bytes=
´´´
jdubois commented 9 years ago

First of all, please upgraded to v1.5.0 (which I released 5 minutes ago), as it will correct an issue with Heroku. Looks strange that the DATABASE_URL env variable is not set up, but what you have seems a bit strange: you took the sample app and called the sub generator on top of it? Did you have a look at your Heroku dashboard, do you have an SQL database and is it linked to your application? This is what the sub generator does for you, so you shouldn't have to do it.

MartinLichtblau commented 9 years ago

Yes, I did call it in the sample-app folder. I also had a DB in heroku but it wasn't linked to sample-app. Now I deleted all apps I had on heroku, deleted the one DB on heroku, updated to your newest commit and magic. It creates a new database and links it to the sample-app (Which didn't happen before). heroku_database_commit

But there is a new problem which causes the "Application Error". Heroku logs:

Pool.getConnection(HikariPool.java:192) ~[HikariCP-1.4.0.jar!/:na]
2014-10-29T16:12:34.715572+00:00 app[web.1]:    at com.zaxxer.hikari.HikariDataS
ource.getConnection(HikariDataSource.java:91) ~[HikariCP-1.4.0.jar!/:na]
2014-10-29T16:12:34.715574+00:00 app[web.1]:    at liquibase.integration.spring.
SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:296) ~[liquibase-core-3.
1.1.jar!/:na]
2014-10-29T16:12:34.715575+00:00 app[web.1]:    ... 89 common frames omitted
2014-10-29T16:12:34.715576+00:00 app[web.1]: Caused by: java.lang.NullPointerExc
eption: null
2014-10-29T16:12:34.715577+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional
.MysqlDataSource.getConnection(MysqlDataSource.java:429) ~[mysql-connector-java-
5.1.32.jar!/:na]
2014-10-29T16:12:34.715578+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional
.MysqlDataSource.getConnection(MysqlDataSource.java:139) ~[mysql-connector-java-
5.1.32.jar!/:na]
2014-10-29T16:12:34.715580+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional
.MysqlDataSource.getConnection(MysqlDataSource.java:109) ~[mysql-connector-java-
5.1.32.jar!/:na]
2014-10-29T16:12:34.715581+00:00 app[web.1]:    at com.zaxxer.hikari.pool.Hikari
Pool.addConnection(HikariPool.java:378) ~[HikariCP-1.4.0.jar!/:na]
2014-10-29T16:12:34.715582+00:00 app[web.1]:    at com.zaxxer.hikari.pool.Hikari
Pool.access$400(HikariPool.java:61) ~[HikariCP-1.4.0.jar!/:na]
2014-10-29T16:12:34.715584+00:00 app[web.1]:    at com.zaxxer.hikari.pool.Hikari
Pool$1AddConnection.run(HikariPool.java:302) ~[HikariCP-1.4.0.jar!/:na]
2014-10-29T16:12:34.715592+00:00 app[web.1]:    at java.util.concurrent.Executor
s$RunnableAdapter.call(Executors.java:511) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.715593+00:00 app[web.1]:    at java.util.concurrent.FutureTa
sk.run(FutureTask.java:266) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.715595+00:00 app[web.1]:    at java.util.concurrent.ThreadPo
olExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.715596+00:00 app[web.1]:    at java.util.concurrent.ThreadPo
olExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.715597+00:00 app[web.1]:    ... 1 common frames omitted
2014-10-29T16:12:34.737361+00:00 app[web.1]: [ERROR] org.springframework.boot.Sp
ringApplication - Application startup failed
2014-10-29T16:12:34.737366+00:00 app[web.1]: org.springframework.beans.factory.B
eanCreationException: Error creating bean with name 'com.ryantenney.metrics.spri
ng.config.annotation.DelegatingMetricsConfiguration': BeanPostProcessor before i
nstantiation of bean failed; nested exception is org.springframework.beans.facto
ry.BeanCreationException: Error creating bean with name 'org.springframework.cac
he.annotation.ProxyCachingConfiguration': Injection of autowired dependencies fa
iled; nested exception is org.springframework.beans.factory.BeanCreationExceptio
n: Could not autowire field: private java.util.Collection org.springframework.ca
che.annotation.AbstractCachingConfiguration.cacheManagerBeans; nested exception
is org.springframework.beans.factory.BeanCreationException: Error creating bean
with name 'cacheConfiguration': Injection of persistence dependencies failed; ne
sted exception is org.springframework.beans.factory.BeanCreationException: Error
 creating bean with name 'liquibase' defined in class path resource [com/mycompa
ny/myapp/config/DatabaseConfiguration.class]: Invocation of init method failed;
nested exception is liquibase.exception.DatabaseException: java.sql.SQLException
: Timeout of 30000ms encountered waiting for connection.
2014-10-29T16:12:34.737369+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapab
leBeanFactory.java:471) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737371+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302) ~[spr
ing-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737373+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegis
try.java:228) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737375+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298) ~[sprin
g-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737376+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193) ~[spring-
beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737378+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolv
er.java:370) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737394+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(Ab
stractAutowireCapableBeanFactory.java:1095) ~[spring-beans-4.0.7.RELEASE.jar!/:4
.0.7.RELEASE]
2014-10-29T16:12:34.737395+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutow
ireCapableBeanFactory.java:990) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE
]
2014-10-29T16:12:34.737397+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCap
ableBeanFactory.java:504) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737399+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapab
leBeanFactory.java:475) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737400+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302) ~[spr
ing-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737403+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegis
try.java:228) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737405+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298) ~[sprin
g-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737407+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:198) ~[spring-
beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737408+00:00 app[web.1]:    at org.springframework.context.s
upport.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcesso
rRegistrationDelegate.java:232) ~[spring-context-4.0.7.RELEASE.jar!/:4.0.7.RELEA
SE]
2014-10-29T16:12:34.737414+00:00 app[web.1]:    at org.springframework.context.s
upport.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplication
Context.java:620) ~[spring-context-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737416+00:00 app[web.1]:    at org.springframework.context.s
upport.AbstractApplicationContext.refresh(AbstractApplicationContext.java:4
67) ~[spring-context-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737418+00:00 app[web.1]:    at org.springframework.boot.cont
ext.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext
.java:109) ~[spring-boot-1.1.8.RELEASE.jar!/:1.1.8.RELEASE]
2014-10-29T16:12:34.737419+00:00 app[web.1]:    at org.springframework.boot.Spri
ngApplication.refresh(SpringApplication.java:691) ~[spring-boot-1.1.8.RELEASE.ja
r!/:1.1.8.RELEASE]
2014-10-29T16:12:34.737421+00:00 app[web.1]:    at org.springframework.boot.Spri
ngApplication.run(SpringApplication.java:320) ~[spring-boot-1.1.8.RELEASE.jar!/:
1.1.8.RELEASE]
2014-10-29T16:12:34.737423+00:00 app[web.1]:    at com.mycompany.myapp.Applicati
on.main(Application.java:56) [classes!/:na]
2014-10-29T16:12:34.737424+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke0(Native Method) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.737426+00:00 app[web.1]:    at sun.reflect.NativeMethodAcces
sorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.737427+00:00 app[web.1]:    at sun.reflect.DelegatingMethodA
ccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.737429+00:00 app[web.1]:    at java.lang.reflect.Method.invo
ke(Method.java:483) ~[na:1.8.0_20-'slim']
2014-10-29T16:12:34.737431+00:00 app[web.1]:    at org.springframework.boot.load
er.MainMethodRunner.run(MainMethodRunner.java:53) [jhipster-0.0.1-SNAPSHOT.war!/
:na]
2014-10-29T16:12:34.737432+00:00 app[web.1]:    at java.lang.Thread.run(Thread.j
ava:745) [na:1.8.0_20-'slim']
2014-10-29T16:12:34.737451+00:00 app[web.1]: Caused by: org.springframework.bean
s.factory.BeanCreationException: Error creating bean with name 'org.springframew
ork.cache.annotation.ProxyCachingConfiguration': Injection of autowired dependen
cies failed; nested exception is org.springframework.beans.factory.BeanCreationE
xception: Could not autowire field: private java.util.Collection org.springframe
work.cache.annotation.AbstractCachingConfiguration.cacheManagerBeans; nested exc
eption is org.springframework.beans.factory.BeanCreationException: Error creatin
g bean with name 'cacheConfiguration': Injection of persistence dependencies fai
led; nested exception is org.springframework.beans.factory.BeanCreationException
: Error creating bean with name 'liquibase' defined in class path resource [com/
mycompany/myapp/config/DatabaseConfiguration.class]: Invocation of init method f
ailed; nested exception is liquibase.exception.DatabaseException: java.sql.SQLEx
ception: Timeout of 30000ms encountered waiting for connection.
2014-10-29T16:12:34.737453+00:00 app[web.1]:    at org.springframework.beans.fac
tory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(A
utowiredAnnotationBeanPostProcessor.java:293) ~[spring-beans-4.0.7.RELEASE.jar!/
:4.0.7.RELEASE]
2014-10-29T16:12:34.737501+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCap
ableBeanFactory.java:1186) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737503+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCap
ableBeanFactory.java:537) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737505+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapab
leBeanFactory.java:475) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737517+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302) ~[spr
ing-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737519+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegis
try.java:228) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737520+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298) ~[sprin
g-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737528+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193) ~[spring-
beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737529+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolv
er.java:370) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737543+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(Ab
stractAutowireCapableBeanFactory.java:1095) ~[spring-beans-4.0.7.RELEASE.jar!/:4
.0.7.RELEASE]
2014-10-29T16:12:34.737545+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutow
ireCapableBeanFactory.java:990) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE
]
2014-10-29T16:12:34.737546+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCap
ableBeanFactory.java:504) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737547+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapab
leBeanFactory.java:475) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737549+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302) ~[spr
ing-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737550+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegis
try.java:228) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737551+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298) ~[sprin
g-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737552+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:198) ~[spring-
beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737553+00:00 app[web.1]:    at org.springframework.aop.frame
work.autoproxy.BeanFactoryAdvisorRetrievalHelper.findAdvisorBeans(BeanFactoryAdv
isorRetrievalHelper.java:92) ~[spring-aop-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737555+00:00 app[web.1]:    at org.springframework.aop.frame
work.autoproxy.AbstractAdvisorAutoProxyCreator.findCandidateAdvisors(AbstractAdv
isorAutoProxyCreator.java:101) ~[spring-aop-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737556+00:00 app[web.1]:    at org.springframework.aop.aspec
tj.annotation.AnnotationAwareAspectJAutoProxyCreator.findCandidateAdvisors(Annot
ationAwareAspectJAutoProxyCreator.java:85) ~[spring-aop-4.0.7.RELEASE.jar!/:4.0.
7.RELEASE]
2014-10-29T16:12:34.737557+00:00 app[web.1]:    at org.springframework.aop.aspec
tj.autoproxy.AspectJAwareAdvisorAutoProxyCreator.shouldSkip(AspectJAwareAdvisorA
utoProxyCreator.java:103) ~[spring-aop-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737558+00:00 app[web.1]:    at org.springframework.aop.frame
work.autoproxy.AbstractAutoProxyCreator.postProcessBeforeInstantiation(AbstractA
utoProxyCreator.java:289) ~[spring-aop-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737559+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeIns
tantiation(AbstractAutowireCapableBeanFactory.java:959) ~[spring-beans-4.0.7.REL
EASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737561+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.resolveBeforeInstantiation(Abstr
actAutowireCapableBeanFactory.java:931) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7
.RELEASE]
2014-10-29T16:12:34.737562+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapab
leBeanFactory.java:465) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737563+00:00 app[web.1]:    ... 26 common frames omitted
2014-10-29T16:12:34.737564+00:00 app[web.1]: Caused by: org.springframework.bean
s.factory.BeanCreationException: Could not autowire field: private java.util.Col
lection org.springframework.cache.annotation.AbstractCachingConfiguration.cacheM
anagerBeans; nested exception is org.springframework.beans.factory.BeanCreationE
xception: Error creating bean with name 'cacheConfiguration': Injection of persi
stence dependencies failed; nested exception is org.springframework.beans.factor
y.BeanCreationException: Error creating bean with name 'liquibase' defined in cl
ass path resource [com/mycompany/myapp/config/DatabaseConfiguration.class]: Invo
cation of init method failed; nested exception is liquibase.exception.DatabaseEx
ception: java.sql.SQLException: Timeout of 30000ms encountered waiting for conne
ction.
2014-10-29T16:12:34.737566+00:00 app[web.1]:    at org.springframework.beans.fac
tory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.injec
t(AutowiredAnnotationBeanPostProcessor.java:509) ~[spring-beans-4.0.7.RELEASE.ja
r!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737570+00:00 app[web.1]:    at org.springframework.beans.fac
tory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87) ~[spring-bea
ns-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:12:34.737571+00:00 app[web.1]:    at org.springframework.beans.fac
tory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(A
utowiredAnnotationBeanPostProcessor.java:290) ~[spring-beans-4.0.7.RELEASE.jar!/
:4.0.7.RELEASE]
2014-10-29T16:12:34.737572+00:00 app[web.1]:    ... 50 common frames omitted
2014-10-29T16:12:34.737574+00:00 app[web.1]: Caused by: org.springframework.bean
s.factory.BeanCreationException: Error creating bean with name 'cacheConfigurati
on': Injection of persistence dependencies failed; nested exception is org.sprin
gframework.beans.factory.BeanCreationException: Error creating bean with name 'l
iquibase' defined in class path resource [com/mycompany/myapp/config/DatabaseCon
figuration.class]: Invocation of init method failed; nested exception is liquiba
se.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encoun
tered waiting for connection.
2014-10-29T16:12:34.737575+00:00 app[web.1]:    at org.springframework.orm.jpa.s
upport.PersistenceAnnotationBeanPostProcessor.postProcessPropertyValues(Persiste
nceAnnotationBeanPostProcessor.java:356) ~[spring-orm-4.0.7.RELEASE.jar!/:4.0.7.
RELEASE]
2014-10-29T16:12:34.737576+00:00 app[web.1]:    at org.springframework.beans.fac
tory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCap
ableBeanFactory.java:1186) ~[spring-beans-4.0.7.RELEASE.jar!/:4.0.7.RELEASE]
2014-10-29T16:17:41.735947+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=jhiphero.herokuapp.com request_id=6c8d1aea-a575-4
bff-927a-55090113bc93 fwd="94.16.78.72" dyno= connect= service= status=503 bytes
=
2014-10-29T16:20:11.309668+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=20e0
1c9c-0359-41eb-8ce7-f31819311741 fwd="94.16.78.72" dyno= connect= service= statu
s=503 bytes=
2014-10-29T16:17:42.430944+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=7b47
1efd-89df-4fb3-a888-7704e5c5f517 fwd="94.16.78.72" dyno= connect= service= statu
s=503 bytes=
2014-10-29T16:21:38.638620+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=jhiphero.herokuapp.com request_id=669a6a04-e95c-4
424-8d8d-23d935ad2700 fwd="94.16.78.72" dyno= connect= service= status=503 bytes
=
2014-10-29T16:20:09.483590+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=jhiphero.herokuapp.com request_id=fa2800d7-19cb-4
b67-87e9-c2187c01e64d fwd="94.16.78.72" dyno= connect= service= status=503 bytes
=
2014-10-29T16:21:39.305080+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=afbd
d374-8030-46a2-9380-4e54beff51af fwd="94.16.78.72" dyno= connect= service= statu
s=503 bytes=
2014-10-29T16:26:48.646653+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=jhiphero.herokuapp.com request_id=70ef2868-1163-4
f3e-9f89-029bcfe84b72 fwd="94.16.78.72" dyno= connect= service= status=503 bytes
=
2014-10-29T16:26:49.349469+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=32dd
cec5-19c4-48ce-9756-8dbe6d6312ab fwd="94.16.78.72" dyno= connect= service= statu
s=503 bytes=
2014-10-29T16:30:11.413811+00:00 heroku[router]: at=error code=H10 desc="App cra
shed" method=GET path="/" host=jhiphero.herokuapp.com request_id=45b0fb5b-10cd-4
119-9dca-bbf54319a7fd fwd="94.16.78.72" dyno= connect= service= status=503 bytes
=
´´´´
MartinLichtblau commented 9 years ago

Update: In the log above I tried to reach the webapp right after it was deployed and the database was not ready yet. That was the reason for the timeout. So now, judging by the log, the "favicon.ico" or sth. with the path is the problem...

2014-10-29T16:17:41.735947+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=6c8d1aea-a575-4bff-927a-55090113bc93 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:20:11.309668+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=20e01c9c-0359-41eb-8ce7-f31819311741 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:17:42.430944+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=7b471efd-89df-4fb3-a888-7704e5c5f517 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:21:38.638620+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=669a6a04-e95c-4424-8d8d-23d935ad2700 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:20:09.483590+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=fa2800d7-19cb-4b67-87e9-c2187c01e64d fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:21:39.305080+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=afbdd374-8030-46a2-9380-4e54beff51af fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:26:48.646653+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=70ef2868-1163-4f3e-9f89-029bcfe84b72 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:26:49.349469+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=32ddcec5-19c4-48ce-9756-8dbe6d6312ab fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:30:11.413811+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=45b0fb5b-10cd-4119-9dca-bbf54319a7fd fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:31:06.465949+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=4f65e029-46d6-42f1-aa9a-7ad564a1bea1 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:31:07.253450+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=d7461ca1-3c26-42dc-bd54-c702dc5c59f2 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:30:12.097361+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=5ff8a87b-e1b2-4114-8baf-a6c014194cf0 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:30:43.288758+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=bdf08188-f9ab-4258-be76-617f0ce588f1 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:30:42.748580+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=55d90faf-a20f-4a43-bf22-e9b900fb7dee fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:46:26.415485+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=130d701e-4221-443f-abf1-47df6725feb7 fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
2014-10-29T16:46:27.015017+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=9d3bee70-4fa9-41e8-888b-7754725ea6ea fwd="94.16.78.72" dyno= connect= service= status=503 bytes=
´´´´
jdubois commented 9 years ago

From your log above I see a timeout in your database connection -> are you sure it is configured correctly? Is it locked by liquibase, in its lock table?

MartinLichtblau commented 9 years ago

Yes, but I think there was a timeout because the database wasn't started the moment I tried to reach the webapp. Somewhere in the heroku doc they say that a new database needs a few minutes to be reachable. I can't say for sure that the DB is configured correctly - But as far as I can see, it is.

The only Error I get now is this one. heroku_crash

P.S.: I could give you access to the heroku-project. This way you could see it by yourself.

jdubois commented 9 years ago

Yes, but I think this error is just due to the Heroku router: it is "pinging" the app to see if it alive, and as it's not alive it's marking it as crashed. Your "real" error must be somewhere up in your logs, and I think it's the database.

MartinLichtblau commented 9 years ago

Yes, you are right. Restarting the webapp with "heroku restart" doesn't work either. So it's in crashed state all the time.

2014-10-30T11:10:05.939940+00:00 heroku[web.1]: State changed from crashed to starting
2014-10-30T11:13:19.885281+00:00 heroku[router]: at=error code=H20 desc="App boot timeout" method=GET path="/" host=jhiphero.herokuapp.com request_id=4ec937b8-02f1-42f4-9add-bf3da837998c fwd="213.157.26.191" dyno= connect= service= status=503 bytes=
2014-10-30T11:13:28.578496+00:00 heroku[web.1]: Starting process with command `java -Xmx384m -Xss512k -XX:+UseCompressedOops -jar target/*.war --spring.profiles.active=prod --server.port=59279  --spring.datasource.heroku-url=postgres://nlqmnshbytquhe:u7R8EwNo8RBco1Wj-D19YCRMIJ@ec2-54-217-224-123.eu-west-1.compute.amazonaws.com:5432/dr2ggh4tj2ibq`
2014-10-30T11:13:31.113950+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS:  -Djava.rmi.server.useCodebaseOnly=true -Djava.rmi.server.useCodebaseOnly=true
2014-10-30T11:13:54.188266+00:00 app[web.1]: [DEBUG] com.mycompany.myapp.Application - Running with Spring Boot v1.1.8.RELEASE, Spring v4.0.7.RELEASE
2014-10-30T11:13:54.188088+00:00 app[web.1]: [INFO] com.mycompany.myapp.Application - Starting Application on be16d68e-b904-453f-b038-dde579104053 with PID 3 (started by u55388 in /app)
2014-10-30T11:14:18.829439+00:00 heroku[web.1]: State changed from starting to down
2014-10-30T11:14:29.422084+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
2014-10-30T11:14:29.422084+00:00 heroku[web.1]: Stopping process with SIGKILL
2014-10-30T11:14:30.757877+00:00 heroku[web.1]: Process exited with status 137

The real error is, that the Autowiring and Bean creation fails on heroku. Any idea why? It used JDK1.8. Perhaps that's causing the problem, because it tells

Could not autowire field: private java.util.Collection org.springframework.cache.annotation.AbstractCachingConfiguration.cacheManagerBeans

Here's the full log:

D:\jhiphero\deploy\heroku>heroku logs -t
2014-10-30T10:56:39.472253+00:00 app[web.1]:    at com.mycompany.myapp.Application.main(Application.java:56)
2014-10-30T10:56:39.472338+00:00 app[web.1]:    ... 6 more
2014-10-30T10:56:39.472615+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.cache.annotation.ProxyCachingConfiguration': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private java.util.Collection org.springframework.cache.annotation.AbstractCachingConfiguration.cacheManagerBeans; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cacheConfiguration': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [com/mycompany/myapp/config/DatabaseConfiguration.class]: Invocation of init method failed; nested exception is liquibase.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.472721+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:293)
2014-10-30T10:56:39.472821+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1186)
2014-10-30T10:56:39.472920+00:00 ap
p[web.1]:       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)
2014-10-30T10:56:39.473090+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
2014-10-30T10:56:39.473011+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
2014-10-30T10:56:39.473175+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
2014-10-30T10:56:39.473269+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
2014-10-30T10:56:39.473364+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
2014-10-30T10:56:39.473447+00:00 app[web.1]:    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:370)
2014-10-30T10:56:39.473530+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1095)
2014-10-30T10:56:39.473623+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:990)
2014-10-30T10:56:39.473717+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504)
2014-10-30T10:56:39.474106+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
2014-10-30T10:56:39.473832+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
2014-10-30T10:56:39.473913+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
2014-10-30T10:56:39.474005+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
2014-10-30T10:56:39.474197+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:198)
2014-10-30T10:56:39.474315+00:00 app[web.1]:    at org.springframework.aop.framework.autoproxy.BeanFactoryAdvisorRetrievalHelper.findAdvisorBeans(BeanFactoryAdvisorRetrievalHelper.java:92)
2014-10-30T10:56:39.474359+00:00 app[web.1]:    at org.springframework.aop.framework.autoproxy.AbstractAdvisorAutoProxyCreator.findCandidateAdvisors(AbstractAdvisorAutoProxyCreator.java:101)
2014-10-30T10:56:39.474409+00:00 app[web.1]:    at org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator.findCandidateAdvisors(AnnotationAwareAspectJAutoProxyCreator.java:85)
2014-10-30T10:56:39.474478+00:00 app[web.1]:    at org.springframework.aop.aspectj.autoproxy.AspectJAwareAdvisorAutoProxyCreator.shouldSkip(AspectJAwareAdvisorAutoProxyCreator.java:103)
2014-10-30T10:56:39.474512+00:00 app[web.1]:    at org.springframework.aop.framework.autoproxy.AbstractAutoProxyCreator.postProcessBeforeInstantiation(AbstractAutoProxyCreator.java:289)
2014-10-30T10:56:39.474564+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInstantiation(AbstractAutowireCapableBeanFactory.java:959)
2014-10-30T10:56:39.474607+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.resolveBeforeInstantiation(AbstractAutowireCapableBeanFactory.java:931)
2014-10-30T10:56:39.474650+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:465)
2014-10-30T10:56:39.474707+00:00 app[web.1]:    ... 26 more
2014-10-30T10:56:39.474863+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private java.util.Collection org.springframework.cache.annotation.AbstractCachingConfiguration.cac
heManagerBeans; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cacheConfiguration': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [com/mycompany/myapp/config/DatabaseConfiguration.class]: Invocation of init method failed; nested exception is liquibase.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.474904+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:509)
2014-10-30T10:56:39.474951+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87)
2014-10-30T10:56:39.474999+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:290)
2014-10-30T10:56:39.475058+00:00 app[web.1]:    ... 50 more
2014-10-30T10:56:39.475231+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cacheConfiguration': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factor
y.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [com/mycompany/myapp/config/DatabaseConfiguration.class]: Invocation of init method failed; nested exception is liquibase.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.475355+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.postProcessPropertyValues(PersistenceAnnotationBeanPostProcessor.java:356)
2014-10-30T10:56:39.475411+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1186)
2014-10-30T10:56:39.475459+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)
2014-10-30T10:56:39.475593+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
2014-10-30T10:56:39.475676+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
2014-10-30T10:56:39.475722+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
2014-10-30T10:56:39.475821+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
2014-10-30T10:56:39.475880+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
2014-10-30T10:56:39.475929+00:00 app[web.1]:    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:370)
2014-10-30T10:56:39.475977+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1095)
2014-10-30T10:56:39.476020+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:990)
2014-10-30T10:56:39.476062+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504)
2014-10-30T10:56:39.476103+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
2014-10-30T10:56:39.476148+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
2014-10-30T10:56:39.476190+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
2014-10-30T10:56:39.476233+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
2014-10-30T10:56:39.476284+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
2014-10-30T10:56:39.476330+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:1021)
2014-10-30T10:56:39.476390+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:916)
2014-10-30T10:56:39.476452+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:862)
2014-10-30T10:56:39.476519+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:481)
2014-10-30T10:56:39.476583+00:00 app[web.1]:    ... 52 more
2014-10-30T10:56:39.476748+00:00 app[web.1]: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [com/mycompany/myapp/config/DatabaseConfiguration.class]: Invocation of init method failed; nested exception is liquibase.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.476834+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1554)
2014-10-30T10:56:39.476992+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
2014-10-30T10:56:39.476917+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:539)
2014-10-30T10:56:39.477063+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
2014-10-30T10:56:39.477281+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
2014-10-30T10:56:39.477708+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87)
2014-10-30T10:56:39.477769+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.postProcessPropertyValues(PersistenceAnnotationBeanPostProcessor.java:353)
2014-10-30T10:56:39.477820+00:00 app[web.1]:    ... 72 more
2014-10-30T10:56:39.477887+00:00 app[web.1]: Caused by: liquibase.exception.DatabaseException: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.477944+00:00 app[web.1]:    at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:301)
2014-10-30T10:56:39.478009+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1613)
2014-10-30T10:56:39.477322+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:292)
2014-10-30T10:56:39.477527+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.findEntityManagerFactory(PersistenceAnnotationBeanPostProcessor.java:515)
2014-10-30T10:56:39.477570+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor$PersistenceElement.resolveEntityManager(PersistenceAnnotationBeanPostProcessor.java:682)
2014-10-30T10:56:39.477616+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor$PersistenceElement.getResourceToInject(PersistenceAnnotationBeanPostProcessor.java:655)
2014-10-30T10:56:39.477461+00:00 app[web.1]:    at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.findDefaultEntityManagerFactory(PersistenceAnnotationBeanPostProcessor.java:549)
2014-10-30T10:56:39.477150+00:00 app[web.1]:    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
2014-10-30T10:56:39.477233+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
2014-10-30T10:56:39.477662+00:00 app[web.1]:    at org.springframework.beans.factory.annotation.InjectionMetadata$InjectedElement.inject(InjectionMetadata.java:155)
2014-10-30T10:56:39.478160+00:00 app[web.1]: Caused by: java.sql.SQLException: Timeout of 30000ms encountered waiting for connection.
2014-10-30T10:56:39.478209+00:00 app[web.1]:    at com.zaxxer.hikari.pool.HikariPool.getConnection(HikariPool.java:192)
2014-10-30T10:56:39.478261+00:00 app[web.1]:    at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:91)
2014-10-30T10:56:39.478298+00:00 app[web.1]:    at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:296)
2014-10-30T10:56:39.478334+00:00 app[web.1]:    ... 89 more
2014-10-30T10:56:39.478387+00:00 app[web.1]: Caused by: java.lang.NullPointerException
2014-10-30T10:56:39.478423+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional.MysqlDataSource.getConnection(MysqlDataSource.java:429)
2014-10-30T10:56:39.478049+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1550)
2014-10-30T10:56:39.478091+00:00 app[web.1]:    ... 87 more
2014-10-30T10:56:39.478821+00:00 app[web.1]:    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
2014-10-30T10:56:39.478848+00:00 app[web.1]:    ... 1 more
2014-10-30T10:56:39.478465+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional.MysqlDataSource.getConnection(MysqlDataSource.java:139)
2014-10-30T10:56:39.478501+00:00 app[web.1]:    at com.mysql.jdbc.jdbc2.optional.MysqlDataSource.getConnection(MysqlDataSource.java:109)
2014-10-30T10:56:39.478547+00:00 app[web.1]:    at com.zaxxer.hikari.pool.HikariPool.addConnection(HikariPool.java:378)
2014-10-30T10:56:39.478586+00:00 app[web.1]:    at com.zaxxer.hikari.pool.HikariPool.access$400(HikariPool.java:61)
2014-10-30T10:56:39.478623+00:00 app[web.1]:    at com.zaxxer.hikari.pool.HikariPool$1AddConnection.run(HikariPool.java:302)
2014-10-30T10:56:39.478667+00:00 app[web.1]:    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
2014-10-30T10:56:39.478707+00:00 app[web.1]:    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
2014-10-30T10:56:39.478759+00:00 app[web.1]:    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
2014-10-30T10:56:39.477403+00:00 app[web.1]:    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
2014-10-30T10:56:40.257806+00:00 heroku[web.1]: Process exited with status 1
2014-10-30T10:5
6:40.271946+00:00 heroku[web.1]: State changed from starting to crashed
2014-10-30T10:59:52.796811+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=jhiphero.herokuapp.com request_id=52d46a66-f76c-4497-9c02-ebaa2b2b232f fwd="213.157.26.191" dyno= connect= service= status=503 bytes=
2014-10-30T10:59:53.212574+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=jhiphero.herokuapp.com request_id=137d1913-36b4-4dab-8a4e-5c80a80843fe fwd="213.157.26.191" dyno= connect= service= status=503 bytes=
´´´
jdubois commented 9 years ago

To me the real error is:

java.sql.SQLException: Timeout of 30000ms encountered waiting for connection

Liquibase is waiting to have a database connection, which times out, so the total start up of the application is more than 60s, and so it is killed by Heroku.

jdubois commented 9 years ago

I'm closing this as it is a database connection error, so this is not directly a JHipster issue

MartinLichtblau commented 9 years ago

Yeah, ok. But, is it possible, or were you able to run the jhipster sample-app on heroku?

jdubois commented 9 years ago

Yes of course. Can you access your database with a database explorer?

MartinLichtblau commented 9 years ago

Yes, I was able to access it via pgadmin.

So, I updated rubyonrails and tried a lot. I the end I was able to create a working instance on heroku. But, the generator didn't do the job as it should. Three days ago it created the webapp and pushed it to heroku, but it was not running alright on heroku. Now it creates the deploy folder correct but it fails to push it to heroku.

Running "copy:generateHerokuDirectory" (copy) task
Created 137 directories, copied 1444 files

Done, without errors.

Adding files for initial commit
× [Error: stderr maxBuffer exceeded.]

Uploading your initial application code.
 This may take several minutes depending on your connection speed...
Initializing repository
, done.

-----> Deleting 0 files matching .slugignore patterns.

 !     Push rejected, no Cedar-supported app detected

To git@heroku.com:jhiphero3.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:jhiphero3.git'

Error: Command failed: Initializing repository, done.

-----> Deleting 0 files matching .slugignore patterns.

 !     Push rejected, no Cedar-supported app detected

To git@heroku.com:jhiphero3.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:jhiphero3.git'

At least I can deploy the webapp inside the deploy/heroku folder manually on heroku and that's how it worked in the end................

atomfrede commented 3 years ago

Please don't comment on old issues. We can help You best when you provide the details asked in our issue template.