Ejemplo n.º 1
0
 public static IHealthChecksBuilder AddSqlServers(
     this IHealthChecksBuilder builder,
     AcuWebSites acuWebSites,
     TimeSpan?timeout = null)
 {
     return(acuWebSites.Aggregate(builder,
                                  (current, acuWebSite) => current.AddSqlServer(name: $"Sql [{acuWebSite.Name}]",
                                                                                connectionString: acuWebSite.ConnectionString,
                                                                                tags: new List <string> {
         "sql", acuWebSite.Name
     },
                                                                                timeout: timeout)));
 }
Ejemplo n.º 2
0
 public static IHealthChecksBuilder AddActiveUsers(
     this IHealthChecksBuilder builder,
     AcuWebSites acuWebSites,
     TimeSpan?timeout = null)
 {
     return(acuWebSites.Aggregate(builder,
                                  (current, acuWebSite) => current.AddCheck(name: $"Users [{acuWebSite.Name}]",
                                                                            instance: new ActiveUsersChecker(acuWebSite),
                                                                            tags: new List <string> {
         "users", acuWebSite.Name
     },
                                                                            timeout: timeout)));
 }
Ejemplo n.º 3
0
 public static IHealthChecksBuilder AddUrls(
     this IHealthChecksBuilder builder,
     AcuWebSites acuWebSites,
     TimeSpan?timeout = null)
 {
     return(acuWebSites.Aggregate(builder,
                                  (current, acuWebSite) => current.AddUrlGroup(name: $"Url [{acuWebSite.Name}]",
                                                                               uri: new Uri(acuWebSite.Url),
                                                                               tags: new List <string> {
         "url", acuWebSite.Name
     },
                                                                               timeout: timeout)));
 }