diff options
| author | songyanchao <[email protected]> | 2023-12-25 02:55:23 +0000 |
|---|---|---|
| committer | songyanchao <[email protected]> | 2023-12-25 02:55:23 +0000 |
| commit | 8711dcbb38389e8a3a2fc5ad3f33408a5db5bb2d (patch) | |
| tree | d32228b6e0f1e31744842d845843fa8069478221 /tools/monit_device | |
| parent | dc452792e6886750af698e999c2a059d43d0606d (diff) | |
🐞 fix(TSG-18110): Fix issue with missing Prometheus metrics output.v4.6.67-20231225
Fix issue with missing Prometheus metrics output.
Diffstat (limited to 'tools/monit_device')
| -rwxr-xr-x | tools/monit_device/monit_device.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/monit_device/monit_device.py b/tools/monit_device/monit_device.py index fd5e9e0..c25032f 100755 --- a/tools/monit_device/monit_device.py +++ b/tools/monit_device/monit_device.py @@ -171,7 +171,7 @@ def setup_argv_parser(phydev_list): parser.add_argument('--prometheus-client', help='Run as prometheus client', action='store_true', default=0) - parser.add_argument('--prometheus-client-listen-port', help='Default Port of prometheus client', + parser.add_argument('--prometheus-client-listen-port', help='Default Port(8901) of prometheus client', type=int, default=8901) return parser.parse_args() @@ -203,7 +203,7 @@ class PrometheusClient(BaseHTTPRequestHandler): self.send_response(200) self.send_header('Content-type', 'text/plain; version=0.0.4') self.end_headers() - self.wfile.write(resp) + self.wfile.write(resp.encode('utf-8')) else: self.send_error(404) self.end_headers() |
