Thorntail app on Heroku with JVM metrics enabled - heroku

When I enable Heroku's JVM metrics on my working Thorntail 2.2.0 app, the app fails at startup, and strange errors occur...
Obviously, it has something to do with :
2018-10-08T19:11:34.512200+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS: -javaagent:/app/.heroku/bin/heroku-metrics-agent.jar
Any idea ?
Here is the full startup log :
2018-10-08T19:10:52.554331+00:00 heroku[web.1]: State changed from crashed to starting
2018-10-08T19:11:30.516536+00:00 heroku[web.1]: Starting process with command `java -Djava.net.preferIPv4Stack=true -Xmx224m -Xss512k -Dswarm.datasources.data-sources.XXX.connection-url=jdbc:mysql://XXX/XXX -Dswarm.datasources.data-sources.XXX.driver-name=mysql -Dswarm.datasources.data-sources.XXX.user-name=XXX -Dswarm.datasources.data-sources.XXX.password=XXX -Dswarm.datasources.data-sources.XXX.validate-on-match=true -Dswarm.datasources.data-sources.XXX.background-validation=true "-Dswarm.http.port=8366" -jar adi-web/XXX-webapp/build/libs/XXX-webapp-hollow-thorntail.jar XXX-web/XXX-webapp/build/libs/XXX.war`
2018-10-08T19:11:34.141406+00:00 app[web.1]: [heroku-exec] Starting
2018-10-08T19:11:34.512200+00:00 app[web.1]: Picked up JAVA_TOOL_OPTIONS: -javaagent:/app/.heroku/bin/heroku-metrics-agent.jar
2018-10-08T19:12:35.905056+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.905064+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JAX-RS - STABLE io.thorntail:jaxrs:2.2.0.Final
2018-10-08T19:12:35.908249+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.908256+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Logging - STABLE io.thorntail:logging:2.2.0.Final
2018-10-08T19:12:35.925744+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.925748+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Elytron - STABLE io.thorntail:elytron:2.2.0.Final
2018-10-08T19:12:35.935554+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.935558+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JPA - STABLE io.thorntail:jpa:2.2.0.Final
2018-10-08T19:12:35.946180+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.946183+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Undertow - STABLE io.thorntail:undertow:2.2.0.Final
2018-10-08T19:12:35.984719+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.984724+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Bean Validation - STABLE io.thorntail:bean-validation:2.2.0.Final
2018-10-08T19:12:35.998796+00:00 app[web.1]: Oct 08, 2018 7:12:35 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:35.998800+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JCA - STABLE io.thorntail:jca:2.2.0.Final
2018-10-08T19:12:36.020240+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.020244+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Transactions - STABLE io.thorntail:transactions:2.2.0.Final
2018-10-08T19:12:36.028312+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.028317+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JSF - STABLE io.thorntail:jsf:2.2.0.Final
2018-10-08T19:12:36.032955+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.032959+00:00 app[web.1]: INFO: THORN0013: Installed fraction: CDI Configuration - STABLE io.thorntail:cdi-config:2.2.0.Final
2018-10-08T19:12:36.047870+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.047874+00:00 app[web.1]: INFO: THORN0013: Installed fraction: CDI - STABLE io.thorntail:cdi:2.2.0.Final
2018-10-08T19:12:36.088953+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.088957+00:00 app[web.1]: INFO: THORN0013: Installed fraction: EJB - STABLE io.thorntail:ejb:2.2.0.Final
2018-10-08T19:12:36.095022+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.095026+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Datasources - STABLE io.thorntail:datasources:2.2.0.Final
2018-10-08T19:12:36.101204+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.101208+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JAX-RS with JSON-P - STABLE io.thorntail:jaxrs-jsonp:2.2.0.Final
2018-10-08T19:12:36.102051+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.102054+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JAX-RS with Multipart - STABLE io.thorntail:jaxrs-multipart:2.2.0.Final
2018-10-08T19:12:36.131170+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.131174+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Web - STABLE io.thorntail:web:2.2.0.Final
2018-10-08T19:12:36.137655+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.137659+00:00 app[web.1]: INFO: THORN0013: Installed fraction: Hibernate Validator - STABLE io.thorntail:hibernate-validator:2.2.0.Final
2018-10-08T19:12:36.156735+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.156772+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JAX-RS with Validation - STABLE io.thorntail:jaxrs-validator:2.2.0.Final
2018-10-08T19:12:36.162066+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.wildfly.swarm.container.runtime.ServerBootstrapImpl logFraction
2018-10-08T19:12:36.162070+00:00 app[web.1]: INFO: THORN0013: Installed fraction: JAX-RS with JAXB - STABLE io.thorntail:jaxrs-jaxb:2.2.0.Final
2018-10-08T19:12:36.977514+00:00 app[web.1]: Oct 08, 2018 7:12:36 PM org.jboss.weld.bootstrap.WeldStartup
2018-10-08T19:12:36.977528+00:00 app[web.1]: INFO: WELD-000900: 2.4.3 (Final)
2018-10-08T19:12:37.024143+00:00 app[web.1]: Oct 08, 2018 7:12:37 PM org.jboss.weld.util.ServiceLoader loadClass
2018-10-08T19:12:37.024151+00:00 app[web.1]: WARNING: Could not load service class org.wildfly.swarm.cdi.config.deployment.InjectConfigViewExtension
2018-10-08T19:12:37.062068+00:00 app[web.1]: Oct 08, 2018 7:12:37 PM org.jboss.weld.environment.deployment.discovery.DiscoveryStrategyFactory create
2018-10-08T19:12:37.062074+00:00 app[web.1]: INFO: WELD-ENV-000020: Using jandex for bean discovery
2018-10-08T19:12:41.971025+00:00 app[web.1]: Oct 08, 2018 7:12:41 PM org.jboss.weld.bootstrap.WeldStartup startContainer
2018-10-08T19:12:41.971044+00:00 app[web.1]: INFO: WELD-000101: Transactional services not available. Injection of #Inject UserTransaction not available. Transactional observers will be invoked synchronously.
2018-10-08T19:12:47.095661+00:00 app[web.1]: Oct 08, 2018 7:12:47 PM org.jboss.weld.interceptor.reader.InterceptorMetadataUtils isValidTargetClassLifecycleInterceptorMethod
2018-10-08T19:12:47.095675+00:00 app[web.1]: WARN: WELD-001471: Interceptor method postConstruct defined on class org.wildfly.swarm.container.runtime.wildfly.ShrinkWrapFileSystem is not defined according to the specification. It should not throw java.io.IOException, which is a checked exception.
2018-10-08T19:12:47.095678+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.wildfly.ShrinkWrapFileSystem.postConstruct(ShrinkWrapFileSystem.java:0)
2018-10-08T19:12:47.095680+00:00 app[web.1]: StackTrace
2018-10-08T19:12:47.097952+00:00 app[web.1]: Oct 08, 2018 7:12:47 PM org.jboss.weld.interceptor.reader.InterceptorMetadataUtils isValidTargetClassLifecycleInterceptorMethod
2018-10-08T19:12:47.097963+00:00 app[web.1]: WARN: WELD-001471: Interceptor method setupFactories defined on class org.wildfly.swarm.container.runtime.xmlconfig.StandaloneXMLParserProducer is not defined according to the specification. It should not throw java.lang.Exception, which is a checked exception.
2018-10-08T19:12:47.097966+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.xmlconfig.StandaloneXMLParserProducer.setupFactories(StandaloneXMLParserProducer.java:0)
2018-10-08T19:12:47.097968+00:00 app[web.1]: StackTrace
2018-10-08T19:12:47.461880+00:00 app[web.1]: Oct 08, 2018 7:12:47 PM org.jboss.weld.environment.se.WeldContainer fireContainerInitializedEvent
2018-10-08T19:12:47.461891+00:00 app[web.1]: INFO: WELD-ENV-002003: Weld SE container internal initialized
2018-10-08T19:12:49.530773+00:00 app[web.1]: Oct 08, 2018 7:12:49 PM org.wildfly.swarm.datasources.runtime.DatasourceAndDriverCustomizer attemptInstallation
2018-10-08T19:12:49.530785+00:00 app[web.1]: INFO: THORN1003: Auto-detected JDBC driver for mysql
2018-10-08T19:12:52.625954+00:00 app[web.1]: Oct 08, 2018 7:12:52 PM org.jboss.msc.service.ServiceContainerImpl
2018-10-08T19:12:52.625973+00:00 app[web.1]: INFO: JBoss MSC version 1.2.7.SP1
2018-10-08T19:12:52.975271+00:00 app[web.1]: Oct 08, 2018 7:12:52 PM org.jboss.as.server.ApplicationServerService start
2018-10-08T19:12:52.975283+00:00 app[web.1]: INFO: WFLYSRV0049: Thorntail 2.2.0.Final (WildFly Core 3.0.8.Final) starting
2018-10-08T19:12:53.350956+00:00 app[web.1]: Oct 08, 2018 7:12:53 PM org.wildfly.swarm.container.runtime.cli.CommandLineArgsServiceActivator activate
2018-10-08T19:12:53.350968+00:00 app[web.1]: INFO: THORN0019: Install MSC service for command line args: [XXX-web/XXX-webapp/build/libs/XXX.war]
2018-10-08T19:12:57.444531+00:00 app[web.1]: Oct 08, 2018 7:12:57 PM org.jboss.as.controller.AbstractOperationContext executeStep
2018-10-08T19:12:57.444543+00:00 app[web.1]: ERROR: WFLYCTL0013: Operation ("parallel-extension-add") failed - address: ([])
2018-10-08T19:12:57.444545+00:00 app[web.1]: java.lang.RuntimeException: WFLYCTL0079: Failed initializing module org.jboss.as.logging
2018-10-08T19:12:57.444551+00:00 app[web.1]: at org.jboss.as.controller.extension.ParallelExtensionAddHandler$1.execute(ParallelExtensionAddHandler.java:115)
2018-10-08T19:12:57.444553+00:00 app[web.1]: at org.jboss.as.controller.AbstractOperationContext.executeStep(AbstractOperationContext.java:980)
2018-10-08T19:12:57.444554+00:00 app[web.1]: at org.jboss.as.controller.AbstractOperationContext.processStages(AbstractOperationContext.java:726)
2018-10-08T19:12:57.444556+00:00 app[web.1]: at org.jboss.as.controller.AbstractOperationContext.executeOperation(AbstractOperationContext.java:450)
2018-10-08T19:12:57.444557+00:00 app[web.1]: at org.jboss.as.controller.OperationContextImpl.executeOperation(OperationContextImpl.java:1402)
2018-10-08T19:12:57.444559+00:00 app[web.1]: at org.jboss.as.controller.ModelControllerImpl.boot(ModelControllerImpl.java:490)
2018-10-08T19:12:57.444560+00:00 app[web.1]: at org.jboss.as.controller.AbstractControllerService.boot(AbstractControllerService.java:468)
2018-10-08T19:12:57.444562+00:00 app[web.1]: at org.jboss.as.controller.AbstractControllerService.boot(AbstractControllerService.java:430)
2018-10-08T19:12:57.444563+00:00 app[web.1]: at org.jboss.as.server.ServerService.boot(ServerService.java:437)
2018-10-08T19:12:57.444565+00:00 app[web.1]: at org.jboss.as.server.ServerService.boot(ServerService.java:396)
2018-10-08T19:12:57.444567+00:00 app[web.1]: at org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:370)
2018-10-08T19:12:57.444569+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:748)
2018-10-08T19:12:57.444572+00:00 app[web.1]: Caused by: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: WFLYLOG0078: The logging subsystem requires the log manager to be org.jboss.logmanager.LogManager. The subsystem has not be initialized and cannot be used. To use JBoss Log Manager you must add the system property "java.util.logging.manager" and set it to "org.jboss.logmanager.LogManager"
2018-10-08T19:12:57.444574+00:00 app[web.1]: at java.util.concurrent.FutureTask.report(FutureTask.java:122)
2018-10-08T19:12:57.444576+00:00 app[web.1]: at java.util.concurrent.FutureTask.get(FutureTask.java:192)
2018-10-08T19:12:57.444577+00:00 app[web.1]: at org.jboss.as.controller.extension.ParallelExtensionAddHandler$1.execute(ParallelExtensionAddHandler.java:107)
2018-10-08T19:12:57.444580+00:00 app[web.1]: ... 11 more
2018-10-08T19:12:57.444582+00:00 app[web.1]: Caused by: java.lang.IllegalStateException: WFLYLOG0078: The logging subsystem requires the log manager to be org.jboss.logmanager.LogManager. The subsystem has not be initialized and cannot be used. To use JBoss Log Manager you must add the system property "java.util.logging.manager" and set it to "org.jboss.logmanager.LogManager"
2018-10-08T19:12:57.444584+00:00 app[web.1]: at org.jboss.as.logging.LoggingExtension.initialize(LoggingExtension.java:167)
2018-10-08T19:12:57.444585+00:00 app[web.1]: at org.jboss.as.controller.extension.ExtensionAddHandler.initializeExtension(ExtensionAddHandler.java:131)
2018-10-08T19:12:57.444587+00:00 app[web.1]: at org.jboss.as.controller.extension.ExtensionAddHandler.initializeExtension(ExtensionAddHandler.java:104)
2018-10-08T19:12:57.444594+00:00 app[web.1]: at org.jboss.as.controller.extension.ParallelExtensionAddHandler$ExtensionInitializeTask.call(ParallelExtensionAddHandler.java:144)
2018-10-08T19:12:57.444596+00:00 app[web.1]: at org.jboss.as.controller.extension.ParallelExtensionAddHandler$ExtensionInitializeTask.call(ParallelExtensionAddHandler.java:127)
2018-10-08T19:12:57.444597+00:00 app[web.1]: at java.util.concurrent.FutureTask.run(FutureTask.java:266)
2018-10-08T19:12:57.444599+00:00 app[web.1]: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
2018-10-08T19:12:57.444601+00:00 app[web.1]: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
2018-10-08T19:12:57.444602+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:748)
2018-10-08T19:12:57.444604+00:00 app[web.1]: at org.jboss.threads.JBossThread.run(JBossThread.java:320)
2018-10-08T19:12:57.444605+00:00 app[web.1]:
2018-10-08T19:12:57.550906+00:00 app[web.1]: Oct 08, 2018 7:12:57 PM org.jboss.as.server.ServerService$4 logExit
2018-10-08T19:12:57.550914+00:00 app[web.1]: FATAL: WFLYSRV0056: Server boot has failed in an unrecoverable manner; exiting. See previous messages for details.
2018-10-08T19:12:57.610496+00:00 app[web.1]: java.lang.RuntimeException: java.util.concurrent.ExecutionException: Operation failed
2018-10-08T19:12:57.613703+00:00 app[web.1]: at org.wildfly.swarm.spi.api.ClassLoading.withTCCL(ClassLoading.java:45)
2018-10-08T19:12:57.613954+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.ServerBootstrapImpl.bootstrap(ServerBootstrapImpl.java:113)
2018-10-08T19:12:57.614003+00:00 app[web.1]: at org.wildfly.swarm.Swarm.start(Swarm.java:398)
2018-10-08T19:12:57.614071+00:00 app[web.1]: at org.wildfly.swarm.Swarm.main(Swarm.java:742)
2018-10-08T19:12:57.614650+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-10-08T19:12:57.614695+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2018-10-08T19:12:57.614734+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2018-10-08T19:12:57.615007+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2018-10-08T19:12:57.615056+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.MainInvoker.invoke(MainInvoker.java:53)
2018-10-08T19:12:57.616224+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.Main.run(Main.java:132)
2018-10-08T19:12:57.616292+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.Main.main(Main.java:85)
2018-10-08T19:12:57.616664+00:00 app[web.1]: Caused by: java.util.concurrent.ExecutionException: Operation failed
2018-10-08T19:12:57.617097+00:00 app[web.1]: at org.jboss.threads.AsyncFutureTask.operationFailed(AsyncFutureTask.java:74)
2018-10-08T19:12:57.617154+00:00 app[web.1]: at org.jboss.threads.AsyncFutureTask.get(AsyncFutureTask.java:268)
2018-10-08T19:12:57.617431+00:00 app[web.1]: at org.wildfly.swarm.internal.wildfly.SelfContainedContainer.start(SelfContainedContainer.java:147)
2018-10-08T19:12:57.617478+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.RuntimeServer.start(RuntimeServer.java:213)
2018-10-08T19:12:57.617676+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.RuntimeServer$Proxy$_$$_WeldClientProxy.start(Unknown Source)
2018-10-08T19:12:57.679602+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.ServerBootstrapImpl.lambda$bootstrap$1(ServerBootstrapImpl.java:159)
2018-10-08T19:12:57.679933+00:00 app[web.1]: at org.wildfly.swarm.spi.api.ClassLoading.withTCCL(ClassLoading.java:43)
2018-10-08T19:12:57.679972+00:00 app[web.1]: ... 10 more
2018-10-08T19:12:57.683415+00:00 app[web.1]: Caused by: java.lang.Exception: WFLYSRV0056: Server boot has failed in an unrecoverable manner; exiting. See previous messages for details.
2018-10-08T19:12:57.683485+00:00 app[web.1]: at org.jboss.as.server.BootstrapListener.bootFailure(BootstrapListener.java:87)
2018-10-08T19:12:57.683530+00:00 app[web.1]: at org.jboss.as.server.ServerService.boot(ServerService.java:417)
2018-10-08T19:12:57.683561+00:00 app[web.1]: at org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:370)
2018-10-08T19:12:57.683597+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:748)
2018-10-08T19:12:57.683704+00:00 app[web.1]: java.lang.RuntimeException: java.util.concurrent.ExecutionException: Operation failed
2018-10-08T19:12:57.683756+00:00 app[web.1]: at org.wildfly.swarm.spi.api.ClassLoading.withTCCL(ClassLoading.java:45)
2018-10-08T19:12:57.683786+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.ServerBootstrapImpl.bootstrap(ServerBootstrapImpl.java:113)
2018-10-08T19:12:57.683821+00:00 app[web.1]: at org.wildfly.swarm.Swarm.start(Swarm.java:398)
2018-10-08T19:12:57.683880+00:00 app[web.1]: at org.wildfly.swarm.Swarm.main(Swarm.java:742)
2018-10-08T19:12:57.683942+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-10-08T19:12:57.684004+00:00 app[web.1]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2018-10-08T19:12:57.684034+00:00 app[web.1]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2018-10-08T19:12:57.684088+00:00 app[web.1]: at java.lang.reflect.Method.invoke(Method.java:498)
2018-10-08T19:12:57.684136+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.MainInvoker.invoke(MainInvoker.java:53)
2018-10-08T19:12:57.684184+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.Main.run(Main.java:132)
2018-10-08T19:12:57.684223+00:00 app[web.1]: at org.wildfly.swarm.bootstrap.Main.main(Main.java:85)
2018-10-08T19:12:57.684272+00:00 app[web.1]: Caused by: java.util.concurrent.ExecutionException: Operation failed
2018-10-08T19:12:57.684310+00:00 app[web.1]: at org.jboss.threads.AsyncFutureTask.operationFailed(AsyncFutureTask.java:74)
2018-10-08T19:12:57.684352+00:00 app[web.1]: at org.jboss.threads.AsyncFutureTask.get(AsyncFutureTask.java:268)
2018-10-08T19:12:57.684416+00:00 app[web.1]: at org.wildfly.swarm.internal.wildfly.SelfContainedContainer.start(SelfContainedContainer.java:147)
2018-10-08T19:12:57.684450+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.RuntimeServer.start(RuntimeServer.java:213)
2018-10-08T19:12:57.684480+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.RuntimeServer$Proxy$_$$_WeldClientProxy.start(Unknown Source)
2018-10-08T19:12:57.684522+00:00 app[web.1]: at org.wildfly.swarm.container.runtime.ServerBootstrapImpl.lambda$bootstrap$1(ServerBootstrapImpl.java:159)
2018-10-08T19:12:57.684560+00:00 app[web.1]: at org.wildfly.swarm.spi.api.ClassLoading.withTCCL(ClassLoading.java:43)
2018-10-08T19:12:57.684611+00:00 app[web.1]: ... 10 more
2018-10-08T19:12:57.706797+00:00 app[web.1]: Caused by: java.lang.Exception: WFLYSRV0056: Server boot has failed in an unrecoverable manner; exiting. See previous messages for details.
2018-10-08T19:12:57.706835+00:00 app[web.1]: at org.jboss.as.server.BootstrapListener.bootFailure(BootstrapListener.java:87)
2018-10-08T19:12:57.706895+00:00 app[web.1]: at org.jboss.as.server.ServerService.boot(ServerService.java:417)
2018-10-08T19:12:57.706952+00:00 app[web.1]: at org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:370)
2018-10-08T19:12:57.707004+00:00 app[web.1]: at java.lang.Thread.run(Thread.java:748)
2018-10-08T19:12:57.969309+00:00 heroku[web.1]: Process exited with status 1
2018-10-08T19:12:57.986184+00:00 heroku[web.1]: State changed from starting to crashed

Related

Heroku - Ruby error loop

I have not made any changes to ruby files, just a few layout changes and am seeing the following errors in Papertrail on my server. I did some digging by can't seem to find an answer.
Also the same code base is running in a QA system with no errors. Both servers are on the same build, Cedar-14, with the only difference being that the Prod server has a worker Dyno and QA does not.
Feb 01 11:24:46 skincaremarketplace app/worker.1: Don't know how to build
task 'jobs:work'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli/exec.rb:74:in `load'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli/exec.rb:74:in `kernel_load'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli/exec.rb:27:in `run'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli.rb:360:in `exec'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/vendor/thor/lib/thor.rb:369:in `dispatch'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli.rb:20:in `dispatch'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/vendor/thor/lib/thor/base.rb:444:in `start'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/cli.rb:10:in `start'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/exe/bundle:30:in `block in <top (required)>'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/lib/bundler/friendly_errors.rb:121:in `with_friendly_errors'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/vendor/bundle/ruby/2.2.0/gems/bundler-1.15.2/exe/bundle:22:in `<top (required)>'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/bin/bundle:3:in `load'
Feb 01 11:24:46 skincaremarketplace app/worker.1: /app/bin/bundle:3:in `<main>'
Feb 01 11:24:46 skincaremarketplace app/worker.1: (See full trace by running task with --trace)
Feb 01 11:24:46 skincaremarketplace heroku/worker.1: Process exited with status 1
Feb 01 11:40:45 skincaremarketplace heroku/worker.1: State changed from crashed to starting
Feb 01 11:40:52 skincaremarketplace heroku/worker.1: Starting process with command `bundle exec rake jobs:work`
Feb 01 11:40:52 skincaremarketplace heroku/worker.1: State changed from starting to up
Feb 01 11:41:02 skincaremarketplace heroku/worker.1: Process exited with status 1
Feb 01 11:41:02 skincaremarketplace heroku/worker.1: State changed from up to crashed
Feb 01 11:41:02 skincaremarketplace app/worker.1: rake aborted!
Your prod server worker dyno tries to run bundle exec rake jobs:work (check your Procfile). Looks like you don't have that task. It normally should be in lib/tasks/jobs.rake.
If you scale up your QA workers they'll be failing too.
After reviewing the configuration on Heroku, All of our other applications that follow the same pattern, do not use jobs:work, or have a jobs.rake file. The worker was turned on in error. The investigation did shed some light, so thank you Stan.

Odoo on AWS Elastic Beanstalk OSError: [Errno 13] Permission denied

I'm a newbies on Odoo.
Lately I have been deploying Odoo on AWS Elastic Beanstalk via EB cli.
After I do "eb deploy" the server show this message:
INFO: New application version was deployed to running EC2 instances.
INFO: Environment update completed successfully.
When I go to the site. It shows this:
500 Internal Server Error
Here is my "eb logs":
/var/log/httpd/error_log:
[Wed Sep 20 01:41:03.331534 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] mod_wsgi (pid=10846): Exception occurred processing WSGI script '/opt/python/current/app/odoo-wsgi.py'.
[Wed Sep 20 01:41:03.331570 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] Traceback (most recent call last):
[Wed Sep 20 01:41:03.331586 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/service/wsgi_server.py", line 186, in application
[Wed Sep 20 01:41:03.331606 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] return application_unproxied(environ, start_response)
[Wed Sep 20 01:41:03.331614 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/service/wsgi_server.py", line 172, in application_unproxied
[Wed Sep 20 01:41:03.331624 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] result = handler(environ, start_response)
[Wed Sep 20 01:41:03.331630 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/http.py", line 1308, in __call__
[Wed Sep 20 01:41:03.331641 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] return self.dispatch(environ, start_response)
[Wed Sep 20 01:41:03.331646 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/http.py", line 1282, in __call__
[Wed Sep 20 01:41:03.331655 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] return self.app(environ, start_wrapped)
[Wed Sep 20 01:41:03.331660 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/run/venv/lib64/python2.7/site-packages/werkzeug/wsgi.py", line 600, in __call__
[Wed Sep 20 01:41:03.331672 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] return self.app(environ, start_response)
[Wed Sep 20 01:41:03.331678 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/http.py", line 1445, in dispatch
[Wed Sep 20 01:41:03.331686 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] explicit_session = self.setup_session(httprequest)
[Wed Sep 20 01:41:03.331692 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/http.py", line 1342, in setup_session
[Wed Sep 20 01:41:03.331700 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] session_gc(self.session_store)
[Wed Sep 20 01:41:03.331705 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/tools/func.py", line 23, in __get__
[Wed Sep 20 01:41:03.331714 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] value = self.fget(obj)
[Wed Sep 20 01:41:03.331720 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/http.py", line 1293, in session_store
[Wed Sep 20 01:41:03.331727 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] path = odoo.tools.config.session_dir
[Wed Sep 20 01:41:03.331733 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/current/app/odoo/tools/config.py", line 600, in session_dir
[Wed Sep 20 01:41:03.331751 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] os.makedirs(d, 0700)
[Wed Sep 20 01:41:03.331757 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/run/baselinenv/lib64/python2.7/os.py", line 150, in makedirs
[Wed Sep 20 01:41:03.331768 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] makedirs(head, mode)
[Wed Sep 20 01:41:03.331773 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] File "/opt/python/run/baselinenv/lib64/python2.7/os.py", line 157, in makedirs
[Wed Sep 20 01:41:03.331780 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] mkdir(name, mode)
[Wed Sep 20 01:41:03.331796 2017] [:error] [pid 10846] [remote 127.0.0.1:24340] OSError: [Errno 13] Permission denied: '/var/lib/odoo'
/var/log/eb-activity.log:
Disabled forced hourly log rotation.
[2017-09-20T01:41:04.743Z] INFO [10486] - [Application update app-53e273-170920_083852#76/AddonsAfter/ConfigLogRotation] : Completed activity. Result:
Successfully execute hooks in directory /opt/elasticbeanstalk/addons/logpublish/hooks/config.
[2017-09-20T01:41:04.743Z] INFO [10486] - [Application update app-53e273-170920_083852#76/AddonsAfter] : Completed activity.
[2017-09-20T01:41:04.743Z] INFO [10486] - [Application update app-53e273-170920_083852#76] : Completed activity. Result:
Application update - Command CMD-AppDeploy succeeded
[2017-09-20T01:42:45.599Z] INFO [10989] - [CMD-TailLogs] : Starting activity...
[2017-09-20T01:42:45.599Z] INFO [10989] - [CMD-TailLogs/AddonsBefore] : Starting activity...
[2017-09-20T01:42:45.599Z] INFO [10989] - [CMD-TailLogs/AddonsBefore] : Completed activity.
[2017-09-20T01:42:45.599Z] INFO [10989] - [CMD-TailLogs/TailLogs] : Starting activity...
[2017-09-20T01:42:45.599Z] INFO [10989] - [CMD-TailLogs/TailLogs/TailLogs] : Starting activity...
[2017-09-20T01:42:45.845Z] INFO [10989] - [CMD-TailLogs/TailLogs/TailLogs] : Completed activity.
[2017-09-20T01:42:45.845Z] INFO [10989] - [CMD-TailLogs/TailLogs] : Completed activity. Result:
CMD-TailLogs - stage 0 - Command CMD-TailLogs stage 0 completed
[2017-09-20T01:42:45.845Z] INFO [10989] - [CMD-TailLogs/AddonsAfter] : Starting activity...
[2017-09-20T01:42:45.845Z] INFO [10989] - [CMD-TailLogs/AddonsAfter] : Completed activity.
[2017-09-20T01:42:45.845Z] INFO [10989] - [CMD-TailLogs] : Completed activity. Result:
CMD-TailLogs - Command CMD-TailLogs succeeded
[2017-09-20T01:47:03.218Z] INFO [11141] - [CMD-TailLogs] : Starting activity...
[2017-09-20T01:47:03.218Z] INFO [11141] - [CMD-TailLogs/AddonsBefore] : Starting activity...
[2017-09-20T01:47:03.218Z] INFO [11141] - [CMD-TailLogs/AddonsBefore] : Completed activity.
[2017-09-20T01:47:03.218Z] INFO [11141] - [CMD-TailLogs/TailLogs] : Starting activity...
[2017-09-20T01:47:03.218Z] INFO [11141] - [CMD-TailLogs/TailLogs/TailLogs] : Starting activity...
/var/log/httpd/access_log:
127.0.0.1 (-) - - [20/Sep/2017:01:40:57 +0000] "GET / HTTP/1.1" 500 527 "-" "Python-urllib/2.7"
127.0.0.1 (-) - - [20/Sep/2017:01:41:01 +0000] "GET / HTTP/1.1" 500 527 "-" "Python-urllib/2.7"
127.0.0.1 (-) - - [20/Sep/2017:01:41:02 +0000] "GET / HTTP/1.1" 500 527 "-" "Python-urllib/2.7"
127.0.0.1 (-) - - [20/Sep/2017:01:41:03 +0000] "GET / HTTP/1.1" 500 527 "-" "Python-urllib/2.7"
I would like to know if anyone had the same problem like this before. If so what did you do to resolve the issue? Or anyone has any idea how to deal with this problem?
I am sorry I could not post images because the site require reputation > 10 . :(
Hello I suggest you Reinstall Odoo in your AWS Ubuntu 16.04
Follow the link :
https://www.getopenerp.com/install-odoo-10-on-ubuntu-16-04/
it's good and Perfect installation on odoo

Rails. First request too slow, times out, the next ones are faster

I'm developing a rails application. After pushing the git on Heroku without trouble, the app show an error "request time out" inside the webbrowser.
If i'm re-trying 1 minute after, the app display the page very quikly on the webbrowser.
CONFIGURATION
Find below my configuration
Rails 5.1.2
psql (PostgreSQL) 9.6.1
The main info inside the gem file:
ruby '2.2.6'
gem 'rails', '~> 5.1.1'
gem 'pg', '~> 0.18'
gem 'puma', '~> 3.7'
Heroku
Standard-2X dynos, Shared, 1 GB RAM
Heroku Postgres :: Brown
Memcached Cloud :free
Papertrail :free
STANDARD PLAN
LOG
The log of the first very long request ( notice that I restart the server before the test to reproduce the problem that append every morning at the first request)
Aug 25 03:28:15 myapplication app/web.1: => Booting Puma
Aug 25 03:28:15 myapplication app/web.1: => Rails 5.1.2 application starting in production on http://0.0.0.0:41080
Aug 25 03:28:15 myapplication app/web.1: => Run `rails server -h` for more startup options
Aug 25 03:28:15 myapplication app/web.1: [4] Puma starting in cluster mode...
Aug 25 03:28:15 myapplication app/web.1: [4] * Version 3.9.1 (ruby 2.2.6-p396), codename: Private Caller
Aug 25 03:28:15 myapplication app/web.1: [4] * Min threads: 5, max threads: 5
Aug 25 03:28:15 myapplication app/web.1: [4] * Environment: production
Aug 25 03:28:15 myapplication app/web.1: [4] * Process workers: 2
Aug 25 03:28:15 myapplication app/web.1: [4] * Preloading application
Aug 25 03:28:15 myapplication app/web.1: [4] * Listening on tcp://0.0.0.0:41080
Aug 25 03:28:15 myapplication app/web.1: [4] Use Ctrl-C to stop
Aug 25 03:28:15 myapplication app/web.1: [4] - Worker 0 (pid: 6) booted, phase: 0
Aug 25 03:28:15 myapplication app/web.1: [4] - Worker 1 (pid: 19) booted, phase: 0
Aug 25 03:28:15 myapplication heroku/web.1: State changed from starting to up
Aug 25 03:28:37 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.057733 sample#memory-total=4044984kB sample#memory-free=1550168kB sample#memory-cached=1945532kB sample#memory-postgres=16880kB
Aug 25 03:30:38 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.029687 sample#memory-total=4044984kB sample#memory-free=1550000kB sample#memory-cached=1945544kB sample#memory-postgres=16880kB
Aug 25 03:31:39 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.029687 sample#memory-total=4044984kB sample#memory-free=1549940kB sample#memory-cached=1945564kB sample#memory-postgres=16880kB
Aug 25 03:32:38 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.029687 sample#memory-total=4044984kB sample#memory-free=1550284kB sample#memory-cached=1945568kB sample#memory-postgres=16880kB
Aug 25 03:33:39 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.030191 sample#memory-total=4044984kB sample#memory-free=1550128kB sample#memory-cached=1945580kB sample#memory-postgres=16880kB
Aug 25 03:33:51 myapplication heroku/router: at=info method=GET path="/" host=myapplication.herokuapp.com request_id=afa5c118-7319-4b9b-a945-60ed57a63062 fwd="90.87.43.215" dyno=web.1 connect=0ms service=72ms status=301 bytes=371 protocol=https
Aug 25 03:33:51 myapplication app/web.1: I, [2017-08-25T10:33:50.584824 #19] INFO -- : [afa5c118-7319-4b9b-a945-60ed57a63062] Started GET "/" for 90.87.43.215 at 2017-08-25 10:33:50 +0000
Aug 25 03:33:51 myapplication app/web.1: I, [2017-08-25T10:33:50.665212 #19] INFO -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Started GET "/projets/new" for 90.87.43.215 at 2017-08-25 10:33:50 +0000
Aug 25 03:33:51 myapplication app/web.1: I, [2017-08-25T10:33:50.670054 #19] INFO -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Processing by ProjetsController#new as HTML
Aug 25 03:33:51 myapplication app/web.1: D, [2017-08-25T10:33:50.783930 #19] DEBUG -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] User Load (3.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 2], ["LIMIT", 1]]
Aug 25 03:33:51 myapplication app/web.1: D, [2017-08-25T10:33:50.928475 #19] DEBUG -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Regleconfiguration Load (3.4ms) SELECT "regleconfigurations".* FROM "regleconfigurations" ORDER BY "regleconfigurations"."id" DESC LIMIT $1 [["LIMIT", 1]]
Aug 25 03:33:51 myapplication app/web.1: D, [2017-08-25T10:33:50.955570 #19] DEBUG -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Tarifoptionbt Load (3.2ms) SELECT "tarifoptionbts".* FROM "tarifoptionbts"
Aug 25 03:33:51 myapplication app/web.1: I, [2017-08-25T10:33:50.989799 #19] INFO -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Rendering projets/new.html.erb within layouts/application
Aug 25 03:34:21 myapplication heroku/router: at=error code=H12 desc="Request timeout" method=GET path="/projets/new" host=myapplication.herokuapp.com request_id=6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61 fwd="90.87.43.215" dyno=web.1 connect=0ms service=30001ms status=503 bytes=0 protocol=https
Aug 25 03:34:39 myapplication app/heroku-postgres: source=HEROKU_POSTGRESQL_BROWN sample#current_transaction=2339 sample#db_size=25066008bytes sample#tables=21 sample#active-connections=3 sample#waiting-connections=0 sample#index-cache-hit-rate=0.99931 sample#table-cache-hit-rate=0.996 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0.029687 sample#memory-total=4044984kB sample#memory-free=1547512kB sample#memory-cached=1945596kB sample#memory-postgres=20036kB
Aug 25 03:35:37 myapplication app/web.1: I, [2017-08-25T10:35:37.131381 #19] INFO -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Rendered projets/_etapebar.html.erb (106132.4ms)
[.....] render 30 partial view
Aug 25 03:35:38 myapplication app/web.1: I, [2017-08-25T10:35:37.495939 #19] INFO -- : [6db31a1a-39a5-4a8f-9ba1-cf35ceae5f61] Completed 200 OK in 106826ms (Views: 106499.5ms | ActiveRecord: 50.2ms)
If I render a second time the same view I get this log:
Aug 25 05:42:45 myapplication app/web.1: I, [2017-08-25T12:42:44.339695 #19] INFO -- : [9c38a6b8-73d4-4e31-9ac3-df2ec8b21049] Started GET "/projets/new" for 90.87.43.215 at 2017-08-25 12:42:44 +0000
Aug 25 05:42:45 myapplication app/web.1: I, [2017-08-25T12:42:44.341197 #19] INFO -- : [9c38a6b8-73d4-4e31-9ac3-df2ec8b21049] Processing by ProjetsController#new as HTML
Aug 25 05:42:45 myapplication app/web.1: D, [2017-08-25T12:42:44.348612 #19] DEBUG -- : [9c38a6b8-73d4-4e31-9ac3-df2ec8b21049] User Load (1.7ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 2], ["LIMIT", 1]]
Aug 25 05:42:45 myapplication app/web.1: I, [2017-08-25T12:42:44.351579 #19] INFO -- : [9c38a6b8-73d4-4e31-9ac3-df2ec8b21049] Completed 200 OK in 10ms (ActiveRecord: 1.7ms)
The application jump from a 106 second to serve a first request ( that's create a Heroku error) to a very short time in a second render
ASSET
Log show that the second call get asset from request.
In my app, on each page, I load the js of the current controller:
in application.html.erb
<%= stylesheet_link_tag controller.controller_name if TarifsDynamique::Application.assets.find_asset("#{controller.controller_name}.css") %>
<%= javascript_include_tag params[:controller] if TarifsDynamique::Application.assets.find_asset("#{controller.controller_name}.js") %>
and in from application.js and .css, i remove //=require .
and in asset.rb , I add
Rails.application.config.assets.precompile += ["#{controller}.js", "#{controller}.css"]
whith all the controller.
It's work find ( in devvellpoment and in production after the first call).
but when, I try to
$Heroku run assets:precompile
I got this error
Running rake assets:precompile on ⬢ myapplication... up, run.9829 (Standard-1X)
Yarn executable was not detected in the system.
Download Yarn at https://yarnpkg.com/en/docs/install
...
CACHE
I try to add cache to speed up the first page
cache action inside the controler:
class ProjetsController < ApplicationController
caches_action :new, :edit
cache the view: new.html.erb
<%= render 'form', projet: #projet, cached: true %>
active cache inside production.rb
Rails.application.configure do
config.cache_classes = true
NO IDEA
I have no more idea
If you get an idea , its will be so helpfull !
Thanks.
[EDIT]
SOLUTION
Hi,
I finally found what's going on !
I have 50 images to compile in the asset folder.
Even if I precompile them, at the first request after a long sleep, Rails precompile them again that take tomany time.
1- I move image on amason S3,
2- change image_tag to image_static_tag
3- create a image_static_tag helper that serve static file from s3
4- redeploy the app and now everything is ok !!
THANKS FOR YOUR HELP

Passenger startup failure on Heroku Cache Control

I am receiving a startup error for two of my projects when deploying to Heroku. Both work fine locally, it seems like the worker startup of sidekiq causes problems for passenger. I don't really understand where the problem could come from and have checked my procfile, my sidekiq conf and other elements. Any input would be much appreciated.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9294 67/7fd6fe14d700 age/Cor/App/Implementation.cpp:304 ]: Could not spawn process for application /app: An error occured while starting up the preloader.
Nov 03 01:25:15 zugone-production app/web.1: Error ID: 1a5af3e4
Nov 03 01:25:15 zugone-production app/web.1: Error details saved to: /tmp/passenger-error-UjpmyP.html
Nov 03 01:25:15 zugone-production app/web.1: Message from application: /app/vendor/bundle/ruby/2.0.0/gems/heroku-deflater-0.6.1/lib/heroku-deflater/serve_zipped_assets.rb:15: syntax error, unexpected ':', expecting =>
Nov 03 01:25:15 zugone-production app/web.1: ...= { headers: { 'Cache-Control': cache_control } } if Rails::...
Nov 03 01:25:15 zugone-production app/web.1: ... ^ (SyntaxError)
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/heroku-deflater-0.6.1/lib/heroku-deflater/railtie.rb:3:in `<top (required)>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/heroku-deflater-0.6.1/lib/heroku-deflater.rb:1:in `<top (required)>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:76:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:72:in `each'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:72:in `block in require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:61:in `each'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler/runtime.rb:61:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/bundler-1.9.7/lib/bundler.rb:134:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/config/application.rb:9:in `<top (required)>'
Nov 03 01:25:15 zugone-production app/web.1: /app/config/environment.rb:2:in `require'
Nov 03 01:25:15 zugone-production app/web.1: /app/config/environment.rb:2:in `<top (required)>'
Nov 03 01:25:15 zugone-production app/web.1: config.ru:3:in `require'
Nov 03 01:25:15 zugone-production app/web.1: config.ru:3:in `block in <main>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `instance_eval'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `initialize'
Nov 03 01:25:15 zugone-production app/web.1: config.ru:1:in `new'
Nov 03 01:25:15 zugone-production app/web.1: config.ru:1:in `<main>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/passenger-5.0.21/src/helper-scripts/rack-preloader.rb:110:in `eval'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/passenger-5.0.21/src/helper-scripts/rack-preloader.rb:110:in `preload_app'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/passenger-5.0.21/src/helper-scripts/rack-preloader.rb:156:in `<module:App>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/passenger-5.0.21/src/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
Nov 03 01:25:15 zugone-production app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/passenger-5.0.21/src/helper-scripts/rack-preloader.rb:29:in `<main>'
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9793 67/7fd6dbfff700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 3-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9801 67/7fd6f6ffe700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 1-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9803 67/7fd6f5ffd700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 2-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9806 67/7fd6c3fff700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 6-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9807 67/7fd6c1ffd700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 8-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9809 67/7fd6c2ffe700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 7-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9811 67/7fd6daffe700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 4-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:15 zugone-production app/web.1: [ 2015-11-03 09:25:14.9812 67/7fd6d9ffd700 age/Cor/Req/CheckoutSession.cpp:253 ]: [Client 5-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 1a5af3e4. Please see earlier logs for details about the error.
Nov 03 01:25:16 zugone-production heroku/router: at=info method=GET path="/" host=www.zug-erstattung.de request_id=39412581-e55c-4e29-8730-c4c1694b660b fwd="172.21.225.211,130.238.98.89" dyno=web.1 connect=1ms service=5903ms status=500 bytes=2847
Nov 03 01:25:16 zugone-production app/worker.1: /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require': /app/vendor/bundle/ruby/2.0.0/gems/heroku-deflater-0.6.1/lib/heroku-deflater/serve_zipped_assets.rb:15: syntax error, unexpected ':', expecting => (SyntaxError)
Nov 03 01:25:16 zugone-production app/worker.1: ...= { headers: { 'Cache-Control': cache_control } } if Rails::...
Nov 03 01:25:16 zugone-production app/worker.1: ... ^
I had same problem as following 1 hour ago.
SyntaxError:
/app/vendor/bundle/ruby/2.1.0/gems/heroku-deflater-0.6.1/lib/heroku-deflater/serve_zipped_assets.rb:15:
syntax error, unexpected ':', expecting => ...= { headers: {
'Cache-Control': cache_control } } if Rails::...
It seems that heroku-deflater was updated 21 hours ago.
Though I don't know the reason this error is caused at all,
I was able to make my apps work well on Heroku by define heroku-deflater version on Gemfile like this.
■ Gemfile
gem 'heroku-deflater', '0.5.3 ', :group => :production
I would like to wait that heroku-deflater will be updated again.
Thank you!

Failing to catch Errno::ECONNRESET in Ruby code

In my Rails 3.1 project, deployed to Heroku, I have a rake task that generates a few hundred thousand small PNGs based on records in the database and uploads the results to S3 using fog, one file at a time. (Before I was using heroku, the task saved the files locally and everything worked fine.) When I run the task using heroku run:detached, it runs for a while, and uploads a bunch of files, but eventually fails with Connection reset by peer (Errno::ECONNRESET). What's weird about this is that I've modified the script to catch and retry that exception like so:
file_exists = false
retry_count = 10
begin
file_exists = directory.files.head(filekey)
rescue Errno::ECONNRESET => e
if retry_count > 0 then
logger.warning("Connection reset: #{e.inspect}")
retry_count -= 1
sleep(1)
retry
else
raise
end
end
According to the stack trace, file_exists = directory.files.head(filekey) is the line of my code that leads to the exception, so I feel like I'm missing something about Ruby exception handling. I'd love to know what I'm doing wrong, since I'm not 100% sure if this is a problem with my begin/rescue block, the way fog handles network errors, or what.
Here's the complete stack trace:
Nov 07 12:08:01 ... app/run.1: Connection reset by peer (Errno::ECONNRESET)
Nov 07 12:08:01 ... app/run.1: /app/vendor/ruby-1.8.7/lib/ruby/1.8/openssl/buffering.rb:36:in `sysread'
Nov 07 12:08:01 ... app/run.1: /app/vendor/ruby-1.8.7/lib/ruby/1.8/openssl/buffering.rb:36:in `fill_rbuff'
Nov 07 12:08:01 ... app/run.1: /app/vendor/ruby-1.8.7/lib/ruby/1.8/openssl/buffering.rb:68:in `read'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/socket.rb:121:in `read'
Nov 07 12:08:01 ... app/run.1: /app/vendor/ruby-1.8.7/lib/ruby/1.8/timeout.rb:67:in `timeout'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/socket.rb:120:in `read'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/ssl_socket.rb:79:in `read'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/response.rb:21:in `parse'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/connection.rb:275:in `request_kernel'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/excon-0.16.7/lib/excon/connection.rb:103:in `request'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/fog-1.6.0/lib/fog/core/connection.rb:20:in `request'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/fog-1.6.0/lib/fog/aws/storage.rb:392:in `request'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/fog-1.6.0/lib/fog/aws/requests/storage/head_object.rb:53:in `head_object'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/fog-1.6.0/lib/fog/aws/models/storage/files.rb:98:in `head'
Nov 07 12:08:01 ... app/run.1: /app/lib/tasks/assets.rake:45
Nov 07 12:08:01 ... app/run.1: /app/lib/tasks/assets.rake:37:in `each'
Nov 07 12:08:01 ... app/run.1: /app/lib/tasks/assets.rake:37
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/activerecord-3.1.8/lib/active_record/relation/batches.rb:21:in `find_each'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/activerecord-3.1.8/lib/active_record/relation/batches.rb:21:in `each'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/activerecord-3.1.8/lib/active_record/relation/batches.rb:21:in `find_each'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/activerecord-3.1.8/lib/active_record/relation/batches.rb:69:in `find_in_batches'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/activerecord-3.1.8/lib/active_record/relation/batches.rb:20:in `find_each'
Nov 07 12:08:01 ... app/run.1: /app/lib/tasks/assets.rake:35
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `execute'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `invoke_with_call_chain'
Nov 07 12:08:01 ... app/run.1: /app/vendor/ruby-1.8.7/lib/ruby/1.8/monitor.rb:242:in `synchronize'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:116:in `invoke_task'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `top_level'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `each'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `top_level'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:88:in `top_level'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:66:in `run'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/gems/rake-0.9.2.2/bin/rake:33
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/bin/rake:23:in `load'
Nov 07 12:08:01 ... app/run.1: /app/vendor/bundle/ruby/1.8/bin/rake:23
Nov 07 12:08:01 ... app/run.1: Tasks: TOP => ...:make_outlines
Nov 07 12:08:02 ... heroku/run.1: Process exited with status 1
Nov 07 12:08:02 ... heroku/run.1: State changed from up to complete
perhaps try like this:
begin
...
rescue Errno::ECONNRESET => e
...
rescue => e
...
end

Resources