| OLD | NEW |
| 1 # Copyright 2015 The LUCI Authors. All rights reserved. | 1 # Copyright 2015 The LUCI Authors. All rights reserved. |
| 2 # Use of this source code is governed by the Apache v2.0 license that can be | 2 # Use of this source code is governed under the Apache License, Version 2.0 |
| 3 # found in the LICENSE file. | 3 # that can be found in the LICENSE file. |
| 4 | 4 |
| 5 """WSGI app with a cron job endpoint. | 5 """WSGI app with a cron job endpoint. |
| 6 | 6 |
| 7 Used when config component is included via app.yaml includes. If app has | 7 Used when config component is included via app.yaml includes. If app has |
| 8 a backend module, it must be included there. | 8 a backend module, it must be included there. |
| 9 """ | 9 """ |
| 10 | 10 |
| 11 import webapp2 | 11 import webapp2 |
| 12 | 12 |
| 13 from components import utils | 13 from components import utils |
| 14 | 14 |
| 15 from . import handlers | 15 from . import handlers |
| 16 | 16 |
| 17 | 17 |
| 18 def create_backend_application(): | 18 def create_backend_application(): |
| 19 return webapp2.WSGIApplication( | 19 return webapp2.WSGIApplication( |
| 20 handlers.get_backend_routes(), | 20 handlers.get_backend_routes(), |
| 21 debug=utils.is_local_dev_server()) | 21 debug=utils.is_local_dev_server()) |
| 22 | 22 |
| 23 | 23 |
| 24 backend = create_backend_application() | 24 backend = create_backend_application() |
| OLD | NEW |