kinto 19.3.2__py3-none-any.whl → 19.5.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of kinto might be problematic. Click here for more details.
- kinto/core/errors.py +6 -4
- kinto/core/permission/memory.py +3 -2
- kinto/core/permission/testing.py +6 -0
- kinto/plugins/admin/VERSION +1 -1
- kinto/plugins/admin/build/VERSION +1 -1
- kinto/plugins/admin/build/assets/{index-D8oiN37x.css → index-BdpYyatM.css} +1 -1
- kinto/plugins/admin/build/assets/{index-BKIg2XW8.js → index-n-QM_iZE.js} +65 -65
- kinto/plugins/admin/build/index.html +2 -2
- kinto/plugins/prometheus.py +19 -2
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/METADATA +2 -1
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/RECORD +15 -15
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/LICENSE +0 -0
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/WHEEL +0 -0
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/entry_points.txt +0 -0
- {kinto-19.3.2.dist-info → kinto-19.5.0.dist-info}/top_level.txt +0 -0
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
<title>Kinto Administration</title>
|
|
7
7
|
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
8
8
|
<link rel="icon" type="image/x-icon" href="../images/favicon.png">
|
|
9
|
-
<script type="module" crossorigin src="/v1/admin/assets/index-
|
|
10
|
-
<link rel="stylesheet" crossorigin href="/v1/admin/assets/index-
|
|
9
|
+
<script type="module" crossorigin src="/v1/admin/assets/index-n-QM_iZE.js"></script>
|
|
10
|
+
<link rel="stylesheet" crossorigin href="/v1/admin/assets/index-BdpYyatM.css">
|
|
11
11
|
</head>
|
|
12
12
|
|
|
13
13
|
<body>
|
kinto/plugins/prometheus.py
CHANGED
|
@@ -28,7 +28,7 @@ def get_registry():
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
def _fix_metric_name(s):
|
|
31
|
-
return s.replace("-", "_").replace(".", "_")
|
|
31
|
+
return s.replace("-", "_").replace(".", "_").replace(" ", "_")
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
class Timer:
|
|
@@ -68,8 +68,20 @@ class Timer:
|
|
|
68
68
|
|
|
69
69
|
@implementer(metrics.IMetricsService)
|
|
70
70
|
class PrometheusService:
|
|
71
|
+
def __init__(self, prefix=""):
|
|
72
|
+
prefix_clean = ""
|
|
73
|
+
if prefix:
|
|
74
|
+
# In GCP Console, the metrics are grouped by the first
|
|
75
|
+
# word before the first underscore. Here we make sure the specified
|
|
76
|
+
# prefix is not mixed up with metrics names.
|
|
77
|
+
# (eg. `remote-settings` -> `remotesettings_`, `kinto_` -> `kinto_`)
|
|
78
|
+
prefix_clean = _fix_metric_name(prefix).replace("_", "") + "_"
|
|
79
|
+
self.prefix = prefix_clean.lower()
|
|
80
|
+
|
|
71
81
|
def timer(self, key):
|
|
72
82
|
global _METRICS
|
|
83
|
+
key = self.prefix + key
|
|
84
|
+
|
|
73
85
|
if key not in _METRICS:
|
|
74
86
|
_METRICS[key] = prometheus_module.Summary(
|
|
75
87
|
_fix_metric_name(key), f"Summary of {key}", registry=get_registry()
|
|
@@ -84,6 +96,7 @@ class PrometheusService:
|
|
|
84
96
|
|
|
85
97
|
def observe(self, key, value, labels=[]):
|
|
86
98
|
global _METRICS
|
|
99
|
+
key = self.prefix + key
|
|
87
100
|
|
|
88
101
|
if key not in _METRICS:
|
|
89
102
|
_METRICS[key] = prometheus_module.Summary(
|
|
@@ -106,6 +119,7 @@ class PrometheusService:
|
|
|
106
119
|
|
|
107
120
|
def count(self, key, count=1, unique=None):
|
|
108
121
|
global _METRICS
|
|
122
|
+
key = self.prefix + key
|
|
109
123
|
|
|
110
124
|
labels = []
|
|
111
125
|
|
|
@@ -183,4 +197,7 @@ def includeme(config):
|
|
|
183
197
|
pass
|
|
184
198
|
_METRICS.clear()
|
|
185
199
|
|
|
186
|
-
config.
|
|
200
|
+
settings = config.get_settings()
|
|
201
|
+
prefix = settings.get("prometheus_prefix", settings["project_name"])
|
|
202
|
+
|
|
203
|
+
config.registry.registerUtility(PrometheusService(prefix=prefix), metrics.IMetricsService)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: kinto
|
|
3
|
-
Version: 19.
|
|
3
|
+
Version: 19.5.0
|
|
4
4
|
Summary: Kinto Web Service - Store, Sync, Share, and Self-Host.
|
|
5
5
|
Author-email: Mozilla Services <developers@kinto-storage.org>
|
|
6
6
|
License: Copyright 2012 - Mozilla Foundation
|
|
@@ -136,6 +136,7 @@ Contributors
|
|
|
136
136
|
* Balthazar Rouberol <br@imap.cc>
|
|
137
137
|
* Boris Feld <lothiraldan@gmail.com>
|
|
138
138
|
* Brady Dufresne <dufresnebrady@gmail.com>
|
|
139
|
+
* Can Berk Güder <cbguder@mozilla.com>
|
|
139
140
|
* Castro
|
|
140
141
|
* Chirag B. Jadwani <chirag.jadwani@gmail.com>
|
|
141
142
|
* Christophe Gragnic <cgragnic@protonmail.com>
|
|
@@ -10,7 +10,7 @@ kinto/core/__init__.py,sha256=vMPrxTInad09nsWvidn1igX-IqM1M786x9kakm6OILA,8138
|
|
|
10
10
|
kinto/core/authentication.py,sha256=HLA0kREC3GMEsrIsHsQYjVNztYfAF01kb8-pLboByFs,1527
|
|
11
11
|
kinto/core/authorization.py,sha256=GywY25KEzuSSAI709dFHDfdLnKxy3SLEYGwW5FkQ7Qc,13212
|
|
12
12
|
kinto/core/decorators.py,sha256=3SAPWXlyPNUSICZ9mz04bcN-UdbnDuFOtU0bQHHzLis,2178
|
|
13
|
-
kinto/core/errors.py,sha256=
|
|
13
|
+
kinto/core/errors.py,sha256=JXZjkPYjjC0I6x02d2VJRGeaQ2yZYS2zm5o7_ljfyes,8946
|
|
14
14
|
kinto/core/events.py,sha256=SYpXgKMtVjiD9fwYJA2Omdom9yA3nBqi9btdvU1I_nc,10345
|
|
15
15
|
kinto/core/initialization.py,sha256=pdrPVONxznp2W3BfY9Uh-2cwXr-biB1OxcAAKjB1uEU,26679
|
|
16
16
|
kinto/core/metrics.py,sha256=Y6Mt4PUzy2-oudeGr_oCmtX8nIR4SZkzUlPxr58jr-g,2619
|
|
@@ -28,8 +28,8 @@ kinto/core/cache/postgresql/__init__.py,sha256=04OetGaxI89XAHUhtrNtRyipsZTe0bn_Z
|
|
|
28
28
|
kinto/core/cache/postgresql/schema.sql,sha256=a-6lbhqzlNMcig7DCGQ_ULP-Z5nzhNWrZWCpaHTiJPw,503
|
|
29
29
|
kinto/core/listeners/__init__.py,sha256=mBBo0LxNOjL8h8IqRweG1sY_G142FAakhimzKcgQBDQ,203
|
|
30
30
|
kinto/core/permission/__init__.py,sha256=RoI8UJYl3X8ZmuUfVGC8QH1g4EGNrRknUao97D3jKRE,7331
|
|
31
|
-
kinto/core/permission/memory.py,sha256=
|
|
32
|
-
kinto/core/permission/testing.py,sha256=
|
|
31
|
+
kinto/core/permission/memory.py,sha256=ymageLrGfgYxa0j8erOvVq2WPDBgtTo75R0wcL3Wx3Y,6171
|
|
32
|
+
kinto/core/permission/testing.py,sha256=o94YzVhrokh9xHO7s9hxkeoxIjKP_HSRFNj1K2dGaVU,22348
|
|
33
33
|
kinto/core/permission/postgresql/__init__.py,sha256=LRKo4yhrfn9tRm3cLaAVK4ALAn-8Gxb0hI2-QoUevBg,18251
|
|
34
34
|
kinto/core/permission/postgresql/schema.sql,sha256=BlKJNC-omDVF9REaWCTsfKgXupFrmCBX8ZvN4sqTWUU,1344
|
|
35
35
|
kinto/core/permission/postgresql/migrations/migration_001_002.sql,sha256=ey5rDVQfStVStWpyTJn2fmQP5WSA34HhO99PapcgH1k,681
|
|
@@ -78,7 +78,7 @@ kinto/core/views/openapi.py,sha256=YZ7akBoMqmiu0b4AOxlupHU01_kQEHtmzPxJq_iS79Y,9
|
|
|
78
78
|
kinto/core/views/version.py,sha256=-m5G_o0oHTpCgrtfFrHFve6Zqw_gs_szT0Bd8jnNmD4,1419
|
|
79
79
|
kinto/plugins/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
80
80
|
kinto/plugins/flush.py,sha256=mG3J6KI9xP2ICYaxQEscEhUfdkDky-qN0klYap9YPMM,809
|
|
81
|
-
kinto/plugins/prometheus.py,sha256=
|
|
81
|
+
kinto/plugins/prometheus.py,sha256=oGpm1H4-CTVK4kd_GWDyn4nKBCSVq1fypdBoewDMRPk,6209
|
|
82
82
|
kinto/plugins/statsd.py,sha256=-VasJZM1xkhTfFa6_0GgWwfPqKnYS2722bSMDLzZ3pI,2469
|
|
83
83
|
kinto/plugins/accounts/__init__.py,sha256=KX3rTxHf520JNXfAa1RwCMZijSR6kPjOrMbTxMig8yk,4346
|
|
84
84
|
kinto/plugins/accounts/authentication.py,sha256=h7l_KezC8os4sKN1bz3RKEwXwYTYAs21DRzzU9na_U0,3742
|
|
@@ -88,16 +88,16 @@ kinto/plugins/accounts/utils.py,sha256=_IDsQEthJLFjdJ1be-KTxkbiZV-1Xrsfv4nOvdvF0
|
|
|
88
88
|
kinto/plugins/accounts/views/__init__.py,sha256=QpwvsTYci71oRfww8PB2g_6ROrpdvx5s1iA1lN2hCjA,7443
|
|
89
89
|
kinto/plugins/accounts/views/validation.py,sha256=2KpK0ghDK5WJfUh9pc1t1ptWFf7_bnKDau5tG0wjQwU,4631
|
|
90
90
|
kinto/plugins/admin/README.md,sha256=3a9inoO2IHH5aST3xZp_km3ddupHZqadWrQjOQifBRk,105
|
|
91
|
-
kinto/plugins/admin/VERSION,sha256=
|
|
91
|
+
kinto/plugins/admin/VERSION,sha256=60H4bD1nKZtGSQzeEBWKUhFI_cA2QaoUqT-ieXvs14w,6
|
|
92
92
|
kinto/plugins/admin/__init__.py,sha256=057R3q_S4CFiUuqwMIFkyu4prMBnUVc1eo8OUAPeJBs,1327
|
|
93
93
|
kinto/plugins/admin/views.py,sha256=NHQncNB-32ytP03o-ZqisbYEoK7L2QcaK7RBuh0akwg,1338
|
|
94
|
-
kinto/plugins/admin/build/VERSION,sha256=
|
|
95
|
-
kinto/plugins/admin/build/index.html,sha256=
|
|
94
|
+
kinto/plugins/admin/build/VERSION,sha256=60H4bD1nKZtGSQzeEBWKUhFI_cA2QaoUqT-ieXvs14w,6
|
|
95
|
+
kinto/plugins/admin/build/index.html,sha256=jg8vUiSPwIA39mfL6mxAFqgbtgCPpQav_wNZSzwgYjI,467
|
|
96
96
|
kinto/plugins/admin/build/assets/asn1-CGOzndHr.js,sha256=acZ4kKF43mCqr3BgIO-wptx5qHQF0NRS-uhxO-VHgBc,3989
|
|
97
97
|
kinto/plugins/admin/build/assets/clojure-BMjYHr_A.js,sha256=SYpgEG0C5dkSQgMtAejALIQFzA3S0InWn1XquOeNGiA,10815
|
|
98
98
|
kinto/plugins/admin/build/assets/css-BnMrqG3P.js,sha256=qj5HvX1-byua7Xs0K31qoFn_bncMhtZMsOr5e0A-yYo,27132
|
|
99
|
-
kinto/plugins/admin/build/assets/index-
|
|
100
|
-
kinto/plugins/admin/build/assets/index-
|
|
99
|
+
kinto/plugins/admin/build/assets/index-BdpYyatM.css,sha256=XTA4A5XHSbh78ClvPNE-KJnsHmfl6p6cElARPLp86nw,171620
|
|
100
|
+
kinto/plugins/admin/build/assets/index-n-QM_iZE.js,sha256=QsrfBc6_TQLPKnWlvQmp1aZx5Fe5UpmxnvrC9V-QCpg,2733169
|
|
101
101
|
kinto/plugins/admin/build/assets/javascript-iSgyE4tI.js,sha256=KW4RtDugZV0XNnBzAoqSNgq-paMzdd7ArBAunV-t5K0,17092
|
|
102
102
|
kinto/plugins/admin/build/assets/logo-VBRiKSPX.png,sha256=4LXIgVZbcdbMun8bTlCFgnBik7uIkIRILVPFYrTUGgg,5578
|
|
103
103
|
kinto/plugins/admin/build/assets/mllike-C_8OmSiT.js,sha256=XDxcC3JRvVyG3zOFA6HW9YuFJ3sQsutVLc_BLiBu1bA,4826
|
|
@@ -125,9 +125,9 @@ kinto/views/contribute.py,sha256=NEDr2g1HhVwcMBg0qHEZDmWVJ1V31WsM8cRs0Vm6hfc,118
|
|
|
125
125
|
kinto/views/groups.py,sha256=jOq5fX0-4lwZE8k1q5HME2tU7x9052rtBPF7YqcJ-Qg,3181
|
|
126
126
|
kinto/views/permissions.py,sha256=F0_eKx201WyLonXJ5vLdGKa9RcFKjvAihrEEhU1JuLw,9069
|
|
127
127
|
kinto/views/records.py,sha256=lYfACW2L8qcQoyYBD5IX-fTPjFWmGp7GjHq_U4InlyE,5037
|
|
128
|
-
kinto-19.
|
|
129
|
-
kinto-19.
|
|
130
|
-
kinto-19.
|
|
131
|
-
kinto-19.
|
|
132
|
-
kinto-19.
|
|
133
|
-
kinto-19.
|
|
128
|
+
kinto-19.5.0.dist-info/LICENSE,sha256=oNEIMTuTJzppR5ZEyi86yvvtSagveMYXTYFn56zF0Uk,561
|
|
129
|
+
kinto-19.5.0.dist-info/METADATA,sha256=Kct1ODlUKyK7w2dEOub1OH7kHzwTOCCi-240v7Yvklc,8898
|
|
130
|
+
kinto-19.5.0.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
|
131
|
+
kinto-19.5.0.dist-info/entry_points.txt,sha256=3KlqBWPKY81mrCe_oX0I5s1cRO7Q53nCLbnVr5P9LH4,85
|
|
132
|
+
kinto-19.5.0.dist-info/top_level.txt,sha256=EG_YmbZL6FAug9VwopG7JtF9SvH_r0DEnFp-3twPPys,6
|
|
133
|
+
kinto-19.5.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|