{"action":"created","issue":{"url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/3097","repository_url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix","labels_url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/3097/labels{/name}","comments_url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/3097/comments","events_url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/3097/events","html_url":"https://github.com/spring-cloud/spring-cloud-netflix/issues/3097","id":343392145,"node_id":"MDU6SXNzdWUzNDMzOTIxNDU=","number":3097,"title":"ZuulHandlerMapping Not Happening On Startup So First Request Super Slow","user":{"login":"bbk-pij-2012-22","id":2492086,"node_id":"MDQ6VXNlcjI0OTIwODY=","avatar_url":"https://avatars3.githubusercontent.com/u/2492086?v=4","gravatar_id":"","url":"https://api.github.com/users/bbk-pij-2012-22","html_url":"https://github.com/bbk-pij-2012-22","followers_url":"https://api.github.com/users/bbk-pij-2012-22/followers","following_url":"https://api.github.com/users/bbk-pij-2012-22/following{/other_user}","gists_url":"https://api.github.com/users/bbk-pij-2012-22/gists{/gist_id}","starred_url":"https://api.github.com/users/bbk-pij-2012-22/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbk-pij-2012-22/subscriptions","organizations_url":"https://api.github.com/users/bbk-pij-2012-22/orgs","repos_url":"https://api.github.com/users/bbk-pij-2012-22/repos","events_url":"https://api.github.com/users/bbk-pij-2012-22/events{/privacy}","received_events_url":"https://api.github.com/users/bbk-pij-2012-22/received_events","type":"User","site_admin":false},"labels":[{"id":222072230,"node_id":"MDU6TGFiZWwyMjIwNzIyMzA=","url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/labels/waiting%20for%20feedback","name":"waiting for feedback","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":18,"created_at":"2018-07-22T09:38:11Z","updated_at":"2018-07-27T15:15:36Z","closed_at":null,"author_association":"NONE","body":"I think this is just a question because most likely we've got some poor config choice that's causing this.\r\n\r\nJust a note to say thanks first: Zuul is amazing! : ) We absolutely love it. It works really well and was super easy to integrate with our existing cloud services.\r\n\r\nAnyway on to the question/problem:\r\nWe're using docker (and compose) to containerise and deploy multiple services including the cloud services with Eureka as our service registry and Zuul of course as our gateway. All the services can find each other and everything goes to the right place via the gateway as expected. However, the first request to the gateway is super slow. **We've seen similar threads complaining that this causes timeouts etc.** and we've tried various things we've seen in those threads including altering the timeout settings (haphazardly with a bit of trial and error and you can see we've done this badly both in the application.properties file and from the fact that the output warns us it's a weird setup) and we overcame the timeout problems but this obviously didn't address the actual issue that the first request is so slow. We also saw that we could set ribbon eager loading, which we've tried but doesn't seem to have helped. \r\n\r\nHere are the application.properties from the zuul spring boot project (we really haven't learned what we're doing with these properly yet): https://gist.github.com/bbk-pij-2012-22/d5bd22151b57c7258cfbccff786ad978\r\n\r\nHere are the bootstrap.properties from the same project: https://gist.github.com/bbk-pij-2012-22/e159f7027f86541b27da131d0a5115bb\r\n\r\nHere is the output from the gateway during the first request (not on app startup but once everything is running and we make the first request to the gateway): https://gist.github.com/bbk-pij-2012-22/06ed5c75cffc0bcde391c85d11e14288 \r\n\r\nSo we can see in the output that the gateway is busy getting the services during the first request and we guessed that this is the cause of the delay but the eager loading property did not help us. There are quite a few other lines of output that we don't really understand. \r\n\r\nNote: we are not using any defined routing to or ports for the services. All services are assigned a random port on registration with eureka and we expect Zuul to find the services by name when we hit the gateway with the extension (which it does).\r\n\r\nSo I guess the questions are: \r\n1. Is there some config that we're missing to force the gateway to load these services at startup (if that's even the cause of the delay? \r\n2. Are we hashing together settings in the application.properties that shouldn't go together/don't make sense?\r\n\r\nMany thanks in advance and sorry for our lack of understanding."},"comment":{"url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/comments/408449619","html_url":"https://github.com/spring-cloud/spring-cloud-netflix/issues/3097#issuecomment-408449619","issue_url":"https://api.github.com/repos/spring-cloud/spring-cloud-netflix/issues/3097","id":408449619,"node_id":"MDEyOklzc3VlQ29tbWVudDQwODQ0OTYxOQ==","user":{"login":"bbk-pij-2012-22","id":2492086,"node_id":"MDQ6VXNlcjI0OTIwODY=","avatar_url":"https://avatars3.githubusercontent.com/u/2492086?v=4","gravatar_id":"","url":"https://api.github.com/users/bbk-pij-2012-22","html_url":"https://github.com/bbk-pij-2012-22","followers_url":"https://api.github.com/users/bbk-pij-2012-22/followers","following_url":"https://api.github.com/users/bbk-pij-2012-22/following{/other_user}","gists_url":"https://api.github.com/users/bbk-pij-2012-22/gists{/gist_id}","starred_url":"https://api.github.com/users/bbk-pij-2012-22/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbk-pij-2012-22/subscriptions","organizations_url":"https://api.github.com/users/bbk-pij-2012-22/orgs","repos_url":"https://api.github.com/users/bbk-pij-2012-22/repos","events_url":"https://api.github.com/users/bbk-pij-2012-22/events{/privacy}","received_events_url":"https://api.github.com/users/bbk-pij-2012-22/received_events","type":"User","site_admin":false},"created_at":"2018-07-27T15:15:36Z","updated_at":"2018-07-27T15:15:36Z","author_association":"NONE","body":"Thanks. I really appreciate the continued efforts to help.\r\n\r\nPlease could you tell me exactly what to provide so I don't just add lots of irrelevant spam for you."}}
{"actor":{"display_login":"bbk-pij-2012-22"}}