Commit 8d0b047
committed
Only parse environment variables and CLI arguments on startup
Environment variables and CLI arguments can only be changed with a
process restart, so there is no point in parsing them every time we hot
reload our configuration. Instead, we can put the parsed configuration
in a `LazyLock` which will be initialized when we first parse
configuration on startup and then re-used when we hot reload.1 parent b4c7d6c commit 8d0b047
1 file changed
+3
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| |||
66 | 67 | | |
67 | 68 | | |
68 | 69 | | |
69 | | - | |
70 | | - | |
| 70 | + | |
| 71 | + | |
71 | 72 | | |
72 | 73 | | |
73 | 74 | | |
| |||
0 commit comments