Commit 21419544 by Alexander Zobnin Committed by GitHub

SAML: add metrics (#18194)

parent 3e0625ff
...@@ -56,6 +56,9 @@ var ( ...@@ -56,6 +56,9 @@ var (
// MApiLoginOAuth is a metric api login oauth counter // MApiLoginOAuth is a metric api login oauth counter
MApiLoginOAuth prometheus.Counter MApiLoginOAuth prometheus.Counter
// MApiLoginSAML is a metric api login SAML counter
MApiLoginSAML prometheus.Counter
// MApiOrgCreate is a metric api org created counter // MApiOrgCreate is a metric api org created counter
MApiOrgCreate prometheus.Counter MApiOrgCreate prometheus.Counter
...@@ -243,6 +246,12 @@ func init() { ...@@ -243,6 +246,12 @@ func init() {
Namespace: exporterName, Namespace: exporterName,
}) })
MApiLoginSAML = newCounterStartingAtZero(prometheus.CounterOpts{
Name: "api_login_saml_total",
Help: "api login saml counter",
Namespace: exporterName,
})
MApiOrgCreate = newCounterStartingAtZero(prometheus.CounterOpts{ MApiOrgCreate = newCounterStartingAtZero(prometheus.CounterOpts{
Name: "api_org_create_total", Name: "api_org_create_total",
Help: "api org created counter", Help: "api org created counter",
...@@ -435,6 +444,7 @@ func initMetricVars() { ...@@ -435,6 +444,7 @@ func initMetricVars() {
MApiAdminUserCreate, MApiAdminUserCreate,
MApiLoginPost, MApiLoginPost,
MApiLoginOAuth, MApiLoginOAuth,
MApiLoginSAML,
MApiOrgCreate, MApiOrgCreate,
MApiDashboardSnapshotCreate, MApiDashboardSnapshotCreate,
MApiDashboardSnapshotExternal, MApiDashboardSnapshotExternal,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment