buildIntegrationsMap builds a map of name to the list of integration notifiers off of a list of receiver config.
(nc []config.Receiver, tmpl *template.Template, firewallDialer *util_net.FirewallDialer, logger log.Logger, notifierWrapper func(string, notify.Notifier) notify.Notifier)
| 507 | // buildIntegrationsMap builds a map of name to the list of integration notifiers off of a |
| 508 | // list of receiver config. |
| 509 | func buildIntegrationsMap(nc []config.Receiver, tmpl *template.Template, firewallDialer *util_net.FirewallDialer, logger log.Logger, notifierWrapper func(string, notify.Notifier) notify.Notifier) (map[string][]notify.Integration, error) { |
| 510 | integrationsMap := make(map[string][]notify.Integration, len(nc)) |
| 511 | for _, rcv := range nc { |
| 512 | integrations, err := buildReceiverIntegrations(rcv, tmpl, firewallDialer, logger, notifierWrapper) |
| 513 | if err != nil { |
| 514 | return nil, err |
| 515 | } |
| 516 | integrationsMap[rcv.Name] = integrations |
| 517 | } |
| 518 | return integrationsMap, nil |
| 519 | } |
| 520 | |
| 521 | // buildReceiverIntegrations builds a list of integration notifiers off of a |
| 522 | // receiver config. |
no test coverage detected