Fix missing environment id for monitoring data.
This commit is contained in:
@@ -65,10 +65,8 @@ func FromContext(ctx context.Context) (Runner, bool) {
|
|||||||
|
|
||||||
// monitorExecutionsRunnerID passes the id of the runner executing the execution into the monitoring Point p.
|
// monitorExecutionsRunnerID passes the id of the runner executing the execution into the monitoring Point p.
|
||||||
func monitorExecutionsRunnerID(env dto.EnvironmentID, runnerID string) storage.WriteCallback[*dto.ExecutionRequest] {
|
func monitorExecutionsRunnerID(env dto.EnvironmentID, runnerID string) storage.WriteCallback[*dto.ExecutionRequest] {
|
||||||
return func(p *write.Point, e *dto.ExecutionRequest, eventType storage.EventType) {
|
return func(p *write.Point, _ *dto.ExecutionRequest, _ storage.EventType) {
|
||||||
if eventType == storage.Creation && e != nil {
|
p.AddTag(monitoring.InfluxKeyEnvironmentID, env.ToString())
|
||||||
p.AddTag(monitoring.InfluxKeyRunnerID, runnerID)
|
p.AddTag(monitoring.InfluxKeyRunnerID, runnerID)
|
||||||
p.AddTag(monitoring.InfluxKeyEnvironmentID, env.ToString())
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user