Reputation: 12867
In google app engine, you can do routing at 2 places: in your app.yaml, you can send requests to url's off to different scripts, and inside a script, when you work with wsgiApp, you can again do routing, and send different url's off to different handlers. Is there an advantage of doing your routing in either of these places?
Upvotes: 1
Views: 80
Reputation: 101149
Generally the best approach is to use app.yaml
for 'application level' routing - defining paths for static content, utilities like mapreduce, and your main application - and doing the routing for your app from within a single request handler. This avoids the overhead of defining multiple request handlers for each part of your app, while still preserving isolation for distinct components such as external utilities.
Upvotes: 2
Reputation: 1016
You have to use both. Do the high level routing in app.yaml and the more fine grained routing in the wsgi. The important is that you get a god structure of what is routed in each place. I can not see any argument that the one is superior to the other.
Upvotes: 1