func configSentry(cfg *config.Config) {
	err := sentry.Init(sentry.ClientOptions{
		Dsn: cfg.Reporting.SentryDSN,
	})

	if err != nil {
		fmt.Printf("Sentry initialization failed: %v\n", err)
		return
	}

	useSentry = true
	var sentryTags = map[string]string{}

	sentryTags["started_at"] = fmt.Sprintf("%d", time.Now().Unix())

	sentryTags["server.systemd"] = fmt.Sprintf("%v", cfg.Server.Systemd)
	if cfg.Server.Addr != "" {
		sentryTags["server.address"] = cfg.Server.Addr
	}

	sentryTags["metrics.host"] = cfg.Metrics.Host
	sentryTags["metrics.port"] = cfg.Metrics.Port

	if cfg.HipChat.ID != "" {
		sentryTags["hipchat.id"] = cfg.HipChat.ID
	}

	sentryTags["persist.enabled"] = fmt.Sprintf("%v", cfg.Delegations.Persist)
	if cfg.Delegations.Persist {
		sentryTags["persist.mechanism"] = cfg.Delegations.Mechanism
		sentryTags["persist.location"] = cfg.Delegations.Location
	}

	sentry.ConfigureScope(func(scope *sentry.Scope) {
		scope.SetTags(sentryTags)
	})
}
// sentryTags contains additional tags that can be sent to Sentry.
sentryTags contains additional tags that can be sent to Sentry.
// sentryTags contains additional tags that can be sent to Sentry .
func configSentry(cfg *config.Config) {
	err := sentry.Init(sentry.ClientOptions{
		Dsn: cfg.Reporting.SentryDSN,
	})
	if err != nil {
		fmt.Printf("Sentry initialization failed: %v\n", err)
		return
	}
	useSentry = true
	var sentryTags = map[string]string{}
	sentryTags["started_at"] = fmt.Sprintf("%d", time.Now().Unix())
	sentryTags["server.systemd"] = fmt.Sprintf("%v", cfg.Server.Systemd)
	if cfg.Server.Addr != "" {
		sentryTags["server.address"] = cfg.Server.Addr
	}
	sentryTags["metrics.host"] = cfg.Metrics.Host
	sentryTags["metrics.port"] = cfg.Metrics.Port
	if cfg.HipChat.ID != "" {
		sentryTags["hipchat.id"] = cfg.HipChat.ID
	}
	sentryTags["persist.enabled"] = fmt.Sprintf("%v", cfg.Delegations.Persist)
	if cfg.Delegations.Persist {
		sentryTags["persist.mechanism"] = cfg.Delegations.Mechanism
		sentryTags["persist.location"] = cfg.Delegations.Location
	}
	sentry.ConfigureScope(func(scope *sentry.Scope) {
		scope.SetTags(sentryTags)
	})
}
func configSentry ( cfg * config . Config ) { err := sentry . Init ( sentry . ClientOptions { Dsn : cfg . Reporting . SentryDSN , } ) if err != nil { fmt . Printf ( " \n " , err ) return } useSentry = true var sentryTags = map [ string ] string { } sentryTags [ " " ] = fmt . Sprintf ( " " , time . Now ( ) . Unix ( ) ) sentryTags [ " " ] = fmt . Sprintf ( " " , cfg . Server . Systemd ) if cfg . Server . Addr != " " { sentryTags [ " " ] = cfg . Server . Addr } sentryTags [ " " ] = cfg . Metrics . Host sentryTags [ " " ] = cfg . Metrics . Port if cfg . HipChat . ID != " " { sentryTags [ " " ] = cfg . HipChat . ID } sentryTags [ " " ] = fmt . Sprintf ( " " , cfg . Delegations . Persist ) if cfg . Delegations . Persist { sentryTags [ " " ] = cfg . Delegations . Mechanism sentryTags [ " " ] = cfg . Delegations . Location } sentry . ConfigureScope ( func ( scope * sentry . Scope ) { scope . SetTags ( sentryTags ) } ) }
sentryTags contains additional tags that can be sent to Sentry.
sentryTags contains additional tags that can be sent to Sentry .