pomerium/internal/zero/reconciler/report_status.go
2024-04-19 11:33:43 -04:00

23 lines
483 B
Go

package reconciler
import (
"github.com/pomerium/pomerium/pkg/health"
)
func (c *service) ReportBundleAppliedSuccess(
bundleID string,
metadata map[string]string,
) {
var attr []health.Attr
for k, v := range metadata {
attr = append(attr, health.StrAttr(k, v))
}
health.ReportOK(health.ZeroResourceBundle(bundleID), attr...)
}
func (c *service) ReportBundleAppliedFailure(
bundleID string,
err error,
) {
health.ReportError(health.ZeroResourceBundle(bundleID), err)
}