-
Notifications
You must be signed in to change notification settings - Fork 0
/
urls.py
37 lines (31 loc) · 826 Bytes
/
urls.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# -*- coding: utf-8 -*-
"""
Kay URL dispatch setting.
"""
# following few lines is a urlmapping with an older interface.
"""
from werkzeug.routing import (
Map, Rule, Submount,
EndpointPrefix, RuleTemplate,
)
def make_url():
return Map([
Rule('/_ah/queue/deferred', endpoint='deferred'),
Rule('/maintenance_page', endpoint='_internal/maintenance_page'),
])
all_views = {
'deferred': 'kay.handlers.task.task_handler',
'_internal/maintenance_page': 'kay._internal.views.maintenance_page',
}
"""
from kay.routing import (
ViewGroup, Rule
)
view_groups = [
ViewGroup(
Rule('/_ah/queue/deferred', endpoint='deferred',
view='kay.handlers.task.task_handler'),
Rule('/maintenance_page', endpoint='_internal/maintenance_page',
view='kay._internal.views.maintenance_page'),
)
]