hydra-queue-runner: read metrics port from queue_runner_metrics_port config

This commit is contained in:
Cole Helbling 2022-03-29 08:46:43 -07:00
parent 9cdc5aceed
commit 905a7a7beb
2 changed files with 3 additions and 3 deletions

View file

@ -47,8 +47,8 @@ State::State(uint16_t metricsPort)
, maxLogSize(config->getIntOption("max_log_size", 64ULL << 20))
, uploadLogsToBinaryCache(config->getBoolOption("upload_logs_to_binary_cache", false))
, rootsDir(config->getStrOption("gc_roots_dir", fmt("%s/gcroots/per-user/%s/hydra-roots", settings.nixStateDir, getEnvOrDie("LOGNAME"))))
, metricsPort(config->getIntOption("queue_runner_metrics_port", metricsPort))
, registry(std::make_shared<prometheus::Registry>())
, metricsPort(metricsPort)
{
hydraData = getEnvOrDie("HYDRA_DATA");

View file

@ -434,10 +434,10 @@ private:
via gc_roots_dir. */
nix::Path rootsDir;
std::shared_ptr<prometheus::Registry> registry;
uint16_t metricsPort;
std::shared_ptr<prometheus::Registry> registry;
public:
State(uint16_t metricsPort);