在Heroku中向我的应用程序添加SSL证书后,它已经工作了几个小时,直到dynos重新启动。
基本上它是一个http应用程序,我需要将其更改为https,所以我所做的就是添加SSL证书,遵循heroku文档,并且它可以工作几个小时。
现在我收到应用程序错误。
查看它显示的日志:
Aug 24 09:45:33 my-app app/postgres.85: [ORANGE] [3858-1] LOG: restartpoint starting: time
Aug 24 09:45:33 my-app app/postgres.85: [ORANGE] [3859-1] LOG: restartpoint complete: wrote 0 buffers (0.0%); 0 transaction log file(s) added, 0 removed, 10 recycled; write=0.001 s, sync=0.000 s, total=0.018 s; sync files=0, longest=0.000 s, average=0.000 s; distance=163840 kB, estimate=163844 kB
Aug 24 09:45:33 my-app app/postgres.85: [ORANGE] [3860-1] LOG: recovery restart point at 32/B000060
Aug 24 09:45:33 my-app app/postgres.85: [ORANGE] [3860-2] DETAIL: last completed transaction was at log time 2016-08-25 15:42:11.925539+00
Aug 24 09:45:34 my-app app/heroku-postgres: source=HEROKU_POSTGRESQL_ORANGE sample#current_transaction=1935 sample#db_size=7536812.0bytes sample#tables=0 sample#active-connections=2 sample#waiting-connections=0 sample#index-cache-hit-rate=0 sample#table-cache-hit-rate=0 sample#load-avg-1m=0 sample#load-avg-5m=0 sample#load-avg-15m=0 sample#read-iops=0 sample#write-iops=0 sample#memory-total=4045204.0kB sample#memory-<br />Aug 24 09:45:34 my-app app/web.2: Setting JAVA_TOOL_OPTIONS defaults based on dyno size. Custom settings will override them.
Aug 24 09:45:34 my-app app/web.2: Picked up JAVA_TOOL_OPTIONS: -Xmx2g -Dfile.encoding=UTF-8
Aug 24 09:45:35 my-app app/web.2: Expanding oauthxxxx-1.0-SNAPSHOT.war into /app/target/tomcat.27162/webapps/expanded
Aug 24 09:45:35 my-app app/web.2: Adding Context for /app/target/tomcat.27162/webapps/expanded
Aug 24 09:45:35 my-app app/web.2: INFO: No global web.xml found
Aug 24 09:45:35 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment
Aug 24 09:45:35 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.coyote.AbstractProtocol init
Aug 24 09:45:35 my-app app/web.2: INFO: Initializing ProtocolHandler ["http-nio-27162"]
Aug 24 09:45:35 my-app app/web.2: INFO: Using a shared selector for servlet write/read
Aug 24 09:45:35 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.catalina.core.StandardService startInternal
Aug 24 09:45:35 my-app app/web.2: INFO: Starting Servlet Engine: Apache Tomcat/8.0.30
Aug 24 09:45:35 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.catalina.startup.SetContextPropertiesRule begin
Aug 24 09:45:36 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
Aug 24 09:45:36 my-app app/web.2: INFO: Starting service Tomcat
Aug 24 09:45:36 my-app app/web.2: Aug 24, 2016 4:45:35 PM org.apache.catalina.core.StandardEngine startInternal
Aug 24 09:45:36 my-app app/web.2: WARNING: [SetContextPropertiesRule]{Context} Setting property 'antiJARLocking' to 'true' did not find a matching property.
Aug 24 09:45:37 my-app heroku/web.2: State changed from starting to up
Aug 24 09:45:38 my-app app/web.2: Aug 24, 2016 4:45:38 PM org.apache.jasper.servlet.TldScanner scanJars
Aug 24 09:45:38 my-app app/web.2: SEVERE: A child container failed during start
Aug 24 09:45:38 my-app app/web.2: java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]]
Aug 24 09:45:38 my-app app/web.2: at java.util.concurrent.FutureTask.report(FutureTask.java:122)
Aug 24 09:45:38 my-app app/web.2: at java.util.concurrent.FutureTask.get(FutureTask.java:192)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:916)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:871)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398)
Aug 24 09:45:38 my-app app/web.2: at java.util.concurrent.FutureTask.run(FutureTask.java:266)
Aug 24 09:45:38 my-app app/web.2: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
Aug 24 09:45:38 my-app app/web.2: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
Aug 24 09:45:38 my-app app/web.2: at java.lang.Thread.run(Thread.java:745)
Aug 24 09:45:38 my-app app/web.2: Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]]
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
Aug 24 09:45:38 my-app app/web.2: ... 6 more
Aug 24 09:45:38 my-app app/web.2: Caused by: java.lang.NullPointerException
Aug 24 09:45:38 my-app app/web.2: at com.sun.faces.config.InitFacesContext.cleanupInitMaps(InitFacesContext.java:281)
Aug 24 09:45:38 my-app app/web.2: at com.sun.faces.config.InitFacesContext.<init>(InitFacesContext.java:106)
Aug 24 09:45:38 my-app app/web.2: at com.sun.faces.config.FacesInitializer.onStartup(FacesInitializer.java:114)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5244)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
Aug 24 09:45:38 my-app app/web.2: ... 6 more
Aug 24 09:45:38 my-app app/web.2: Aug 24, 2016 4:45:38 PM org.apache.catalina.core.ContainerBase startInternal
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
Aug 24 09:45:38 my-app app/web.2: at webapp.runner.launch.Main.main(Main.java:261)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
Aug 24 09:45:38 my-app app/web.2: at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
Aug 24 09:45:38 my-app app/web.2: Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat]]
Aug 24 09:45:38 my-app app/web.2: INFO: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
Aug 24 09:45:38 my-app app/web.2: Aug 24, 2016 4:45:38 PM org.apache.catalina.core.ContainerBase startInternal
不确定添加证书是否会导致问题,但这是我所做的唯一更改,而不是postgre数据库中的某些更改。
我没有更改代码,因此我不确定你们是否可以告诉我一些相关信息。
谢谢,