Changeset

13120:be4058bb5a7e

util.startup: Record current version in a metric Useful to have this info available when juggling metrics, e.g. to see if things changed between versions.
author Kim Alvefur <zash@zash.se>
date Wed, 31 May 2023 01:14:59 +0200
parents 13119:df57c62165fc
children 13122:45458ecaacae
files util/startup.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/util/startup.lua	Wed May 31 01:07:27 2023 +0200
+++ b/util/startup.lua	Wed May 31 01:14:59 2023 +0200
@@ -367,7 +367,7 @@
 	--- Load and initialise core modules
 	require "prosody.util.xmppstream"
 	require "prosody.core.stanza_router"
-	require "prosody.core.statsmanager"
+	require "prosody.core.statsmanager".metric("gauge", "prosody_info", "", "Prosody version", { "version" }):with_labels(prosody.version):set(1);
 	require "prosody.core.hostmanager"
 	require "prosody.core.portmanager"
 	require "prosody.core.modulemanager"