我需要帮助设置heroku部署-日志显示没有错误,页面显示404

7xllpg7q  于 2021-07-14  发布在  Java
关注(0)|答案(0)|浏览(214)

我成功地在heroku上部署了我的应用程序。这是日志

2021-02-24T20:36:45.711648+00:00 app[web.1]: 2021-02-24 20:36:45.711  INFO 4 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: any request, [org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter@5c2375a9, org.springframework.security.web.context.SecurityContextPersistenceFilter@59cba5a, org.springframework.security.web.header.HeaderWriterFilter@301eda63, org.springframework.web.filter.CorsFilter@60129b9a, org.springframework.security.web.authentication.logout.LogoutFilter@3f67593e, org.springframework.security.web.savedrequest.RequestCacheAwareFilter@6f19ac19, org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter@768fc0f2, org.springframework.security.web.authentication.AnonymousAuthenticationFilter@78d6692f, org.springframework.security.web.session.SessionManagementFilter@341814d3, org.springframework.security.web.access.ExceptionTranslationFilter@20f5281c]
2021-02-24T20:36:45.823041+00:00 app[web.1]: 2021-02-24 20:36:45.822  INFO 4 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService 'applicationTaskExecutor'
2021-02-24T20:36:46.292036+00:00 app[web.1]: 2021-02-24 20:36:46.291  INFO 4 --- [           main] o.s.s.c.ThreadPoolTaskScheduler          : Initializing ExecutorService 'taskScheduler'
2021-02-24T20:36:46.358202+00:00 app[web.1]: 2021-02-24 20:36:46.357  INFO 4 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 47499 (http) with context path ''
2021-02-24T20:36:46.375800+00:00 app[web.1]: 2021-02-24 20:36:46.375  INFO 4 --- [           main] org.marius.projekt.Main                  : Started Main in 5.904 seconds (JVM running for 7.982)
2021-02-24T20:36:46.528468+00:00 heroku[web.1]: State changed from starting to up
2021-02-24T20:37:30.409312+00:00 app[web.1]: 2021-02-24 20:37:30.409  INFO 4 --- [io-47499-exec-3] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
2021-02-24T20:37:30.409435+00:00 app[web.1]: 2021-02-24 20:37:30.409  INFO 4 --- [io-47499-exec-3] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
2021-02-24T20:37:30.419132+00:00 app[web.1]: 2021-02-24 20:37:30.418  INFO 4 --- [io-47499-exec-3] o.s.web.servlet.DispatcherServlet        : Completed initialization in 9 ms
2021-02-24T20:37:30.641157+00:00 heroku[router]: at=info method=GET path="/" host=tvoje-pocasie.herokuapp.com request_id=06668414-6a22-4320-8ed5-3d7a17a26f1d fwd="188.167.228.254" dyno=web.1 connect=0ms service=266ms status=404 bytes=780 protocol=https
2021-02-24T20:38:49.703274+00:00 heroku[router]: at=info method=GET path="/" host=tvoje-pocasie.herokuapp.com request_id=bf50a347-205c-4877-9d45-07ab0bcda6bd fwd="188.167.228.254" dyno=web.1 connect=0ms service=17ms status=404 bytes=780 protocol=https
2021-02-24T20:39:06.634908+00:00 heroku[router]: at=info method=GET path="/forecast" host=tvoje-pocasie.herokuapp.com request_id=e211f62c-a8c1-4166-8d3e-f09778bea073 fwd="188.167.228.254" dyno=web.1 connect=0ms service=13ms status=404 bytes=780 protocol=https

我的heroku本地车运行良好。我在后端使用gradle和groovy,在前端使用react我的应用程序。属性:

spring.data.mongodb.uri=${MONGO_URI}
spring.data.mongodb.host=${HOST}

# spring.data.mongodb.host=tvoje-pocasie.herokuapp.com

spring.data.mongodb.port=27017

# spring.data.mongodb.port=5837

spring.data.mongodb.database=weatherManager
spring.servlet.multipart.max-file-size=256MB
spring.servlet.multipart.max-request-size=256MB
spring.servlet.multipart.enabled=true

主人在哪里https://tvoje-pocasie.herokuapp.com/
我也试过了

spring.data.mongodb.uri=${MONGO_URI}
spring.data.mongodb.host=localhost

# spring.data.mongodb.host=tvoje-pocasie.herokuapp.com

spring.data.mongodb.port=27017

# spring.data.mongodb.port=5837

spring.data.mongodb.database=weatherManager
spring.servlet.multipart.max-file-size=256MB
spring.servlet.multipart.max-request-size=256MB
spring.servlet.multipart.enabled=true

我可以打电话。我不知道还能尝试什么。日志

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题