Commit graph

15 commits

Author SHA1 Message Date
Lars Strojny
f30dfe0cee
Use constant instead of magic number 2022-11-24 20:18:48 +01:00
Lars Strojny
65304798de
Memoized renderering (#37)
Pre-render metrics on discovery once and then reuse rendered response.
2022-11-24 19:35:02 +01:00
Lars Strojny
7c7673f1c2
Fix code smells (#36)
Fix code smells detected by SonarCloud
2022-11-23 14:30:23 +01:00
Lars Strojny
261fa74ac9
Add configuration option for the metric server interface (#25)
Add a configuration option `interface` to allow configuring where the
HTTP metric server should bind to.
2022-11-17 13:15:07 +01:00
Lars Strojny
ce8876793d
Fall back to IPv4 if EAFNOSUPPORT (#24)
If listening to `::` fails, try `0.0.0.0` instead. Addresses #22
2022-11-16 22:47:41 +01:00
Lars Strojny
f8007b55ca
Add experimental support for basic auth and TLS (#23)
Allows restricting access to the monitoring endpoint using basic auth
and configure TLS certificates.
2022-11-16 22:19:08 +01:00
Lars Strojny
479fbe5727 Refactor internal APIs 2022-11-14 01:20:53 +01:00
Lars Strojny
34be5bbca2 Implement consistent request logging 2022-11-13 13:34:33 +01:00
Lars Strojny
8102144b85 Explicit type imports 2022-11-13 13:34:09 +01:00
Lars Strojny
1088a78079
Strict type imports (#17)
When a symbols is only used as a type, require `import type {…}`
2022-11-10 13:00:45 +01:00
Lars Strojny
71e45a3d8c
More user-friendly (and developer-friendly) zod error reporting (#12)
Show each error message from zod and include an excerpt of the data
around the failing path if possible
2022-11-09 21:36:23 +01:00
Lars Strojny
2bd799ca9c
Integration tests for the fastify HTTP adapter (#11) 2022-11-09 19:08:24 +01:00
Lars Strojny
84761dfa93 Replace runtypes with zod, validate config, stricter eslint config 2022-11-08 19:13:34 +01:00
Lars Strojny
ba3786bf6d Fix linting issues 2022-11-07 23:02:24 +01:00
Lars Strojny
7fd1c5a03c Extract prometheus server 2022-11-07 22:31:17 +01:00