public static WardenConfiguration.Builder AddAzureStorageWatcher(this WardenConfiguration.Builder builder, string name, string connectionString, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(AzureStorageWatcher.Create(name, connectionString, @group: group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Performance watcher to the the WardenConfiguration with the default name of Performance Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the PerformanceWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="delay">Delay between resource usage calculation while using the default performance counter (100 ms by default).</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddPerformanceWatcher( this WardenConfiguration.Builder builder, string name, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?delay = null) { builder.AddWatcher(PerformanceWatcher.Create(name, delay), hooks); return(builder); }
/// <summary> /// Extension method for adding the Process watcher to the the WardenConfiguration with the default name of Process Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the ProcessWatcher.</param> /// <param name="processName">Name of the process.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddProcessWatcher( this WardenConfiguration.Builder builder, string name, string processName, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(ProcessWatcher.Create(name, processName), hooks); return(builder); }
/// <summary> /// Extension method for adding the Redis watcher to the the WardenConfiguration with the default name of Redis Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="connectionString">Connection string of the Redis database.</param>m /// <param name="database">Name of the Redis database.</param> /// <param name="timeout">Optional timeout of the Redis query (5 seconds by default).</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddRedisWatcher( this WardenConfiguration.Builder builder, string connectionString, int database, TimeSpan?timeout = null, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(RedisWatcher.Create(connectionString, database, timeout), hooks); return(builder); }
/// <summary> /// Extension method for adding the MSSQL watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the MsSqlWatcher.</param> /// <param name="connectionString">Connection string of the MSSQL database.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMsSqlWatcher( this WardenConfiguration.Builder builder, string name, string connectionString, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(MsSqlWatcher.Create(connectionString), hooks); return(builder); }
/// <summary> /// Extension method for adding the Disk watcher to the the WardenConfiguration with the default name of Disk Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddDiskWatcher( this WardenConfiguration.Builder builder, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(DiskWatcher.Create(), hooks); return(builder); }
/// <summary> /// Extension method for adding the MSSQL watcher to the the WardenConfiguration with the default name of MSSQL Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="configuration">Configuration of MsSqlWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMsSqlWatcher( this WardenConfiguration.Builder builder, MsSqlWatcherConfiguration configuration, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(MsSqlWatcher.Create(configuration), hooks); return(builder); }
/// <summary> /// Extension method for adding the Process watcher to the the WardenConfiguration with the default name of Process Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="processName">Name of the process.</param> /// <param name="configurator">Lambda expression for configuring the ProcessWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddProcessWatcher( this WardenConfiguration.Builder builder, string processName, Action <ProcessWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(ProcessWatcher.Create(processName, configurator), hooks); return(builder); }
/// <summary> /// Extension method for adding the Performance watcher to the the WardenConfiguration with the default name of Performance Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="configurator">Lambda expression for configuring the PerformanceWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="delay">Delay between resource usage calculation while using the default performance counter (100 ms by default).</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddPerformanceWatcher( this WardenConfiguration.Builder builder, Action <PerformanceWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?delay = null) { builder.AddWatcher(PerformanceWatcher.Create(delay, configurator), hooks); return(builder); }
/// <summary> /// Extension method for adding the Redis watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the RedisWatcher.</param> /// <param name="configuration">Configuration of RedisWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddRedisWatcher( this WardenConfiguration.Builder builder, string name, RedisWatcherConfiguration configuration, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(RedisWatcher.Create(name, configuration), hooks); return(builder); }
/// <summary> /// Extension method for adding the Process watcher to the the WardenConfiguration with the default name of Process Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="processName">Name of the process.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddProcessWatcher( this WardenConfiguration.Builder builder, string processName, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(ProcessWatcher.Create(processName), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Disk watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="configurator">Lambda expression for configuring the DiskWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddDiskWatcher( this WardenConfiguration.Builder builder, Action <DiskWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(DiskWatcher.Create(configurator), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Disk watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the DiskWatcher.</param> /// <param name="configuration">Configuration of DiskWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddDiskWatcher( this WardenConfiguration.Builder builder, string name, DiskWatcherConfiguration configuration, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(DiskWatcher.Create(name, configuration), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Disk watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the DiskWatcher.</param> /// <param name="configurator">Lambda expression for configuring the DiskWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddDiskWatcher( this WardenConfiguration.Builder builder, string name, Action <DiskWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null) { builder.AddWatcher(DiskWatcher.Create(name, configurator), hooks); return(builder); }
/// <summary> /// Extension method for adding the Performance watcher to the the WardenConfiguration with the default name of Performance Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="delay">Delay between resource usage calculation while using the default performance counter (100 ms by default).</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddPerformanceWatcher( this WardenConfiguration.Builder builder, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?delay = null, TimeSpan?interval = null) { builder.AddWatcher(PerformanceWatcher.Create(delay), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the MongoDB watcher to the the WardenConfiguration with the default name of MongoDB Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="configuration">Configuration of MongoDbWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMongoDbWatcher( this WardenConfiguration.Builder builder, MongoDbWatcherConfiguration configuration, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(MongoDbWatcher.Create(configuration), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Disk watcher to the the WardenConfiguration with the default name of Disk Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that DiskWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddDiskWatcher( this WardenConfiguration.Builder builder, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(DiskWatcher.Create(group: group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the MongoDB watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the MongoDbWatcher.</param> /// <param name="connectionString">Connection string of the MongoDB database.</param> /// <param name="database">Name of the MongoDB database.</param> /// <param name="configurator">Lambda expression for configuring the MongoDbWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="timeout">Optional timeout of the MongoDB query (5 seconds by default).</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMongoDbWatcher( this WardenConfiguration.Builder builder, string name, string connectionString, string database, Action <MongoDbWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?timeout = null) { builder.AddWatcher(MongoDbWatcher.Create(name, connectionString, database, timeout, configurator), hooks); return(builder); }
/// <summary> /// Extension method for adding the MSSQL watcher to the the WardenConfiguration with the default name of MSSQL Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="connectionString">Connection string of the MSSQL database.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that MsSqlWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMsSqlWatcher( this WardenConfiguration.Builder builder, string connectionString, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(MsSqlWatcher.Create(connectionString, group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Performance watcher to the the WardenConfiguration with the default name of Performance Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="configuration">Configuration of PerformanceWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that PerformanceWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddPerformanceWatcher( this WardenConfiguration.Builder builder, PerformanceWatcherConfiguration configuration, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(PerformanceWatcher.Create(configuration, group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Server watcher to the the WardenConfiguration with the default name of Server Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="hostname">Hostname to be resolved.</param> /// <param name="port">Optional port number of the hostname (0 means not specified).</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddServerWatcher( this WardenConfiguration.Builder builder, string hostname, int port = 0, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(ServerWatcher.Create(hostname, port), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Process watcher to the the WardenConfiguration with the default name of Process Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="processName">Name of the process.</param> /// <param name="machineName">Optional name of the remote machine.</param> /// <param name="configurator">Lambda expression for configuring the ProcessWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that ProcessWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddProcessWatcher( this WardenConfiguration.Builder builder, string processName, Action <ProcessWatcherConfiguration.Default> configurator, string machineName = null, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(ProcessWatcher.Create(processName, machineName, configurator, group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the MSSQL watcher to the the WardenConfiguration. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the MsSqlWatcher.</param> /// <param name="connectionString">Connection string of the MSSQL database.</param> /// <param name="configurator">Lambda expression for configuring the MsSqlWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMsSqlWatcher( this WardenConfiguration.Builder builder, string name, string connectionString, Action <MsSqlWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null) { builder.AddWatcher(MsSqlWatcher.Create(name, connectionString, configurator), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Performance watcher to the the WardenConfiguration with the default name of Performance Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="name">Name of the PerformanceWatcher.</param> /// <param name="configurator">Lambda expression for configuring the PerformanceWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="delay">Delay between resource usage calculation while using the default performance counter (100 ms by default).</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that PerformanceWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddPerformanceWatcher( this WardenConfiguration.Builder builder, string name, Action <PerformanceWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?delay = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(PerformanceWatcher.Create(name, delay, configurator, group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Redis watcher to the the WardenConfiguration with the default name of Redis Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="connectionString">Connection string of the Redis database.</param> /// <param name="database">Name of the Redis database.</param> /// <param name="configurator">Lambda expression for configuring the RedisWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="timeout">Optional timeout of the Redis query (5 seconds by default).</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddRedisWatcher( this WardenConfiguration.Builder builder, string connectionString, int database, Action <RedisWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?timeout = null, TimeSpan?interval = null) { builder.AddWatcher(RedisWatcher.Create(connectionString, database, timeout, configurator), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the MongoDB watcher to the the WardenConfiguration with the default name of MongoDB Watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="connectionString">Connection string of the MongoDB database.</param> /// <param name="database">Name of the MongoDB database.</param> /// <param name="timeout">Optional timeout of the MongoDB query (5 seconds by default).</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that MongoDbWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddMongoDbWatcher( this WardenConfiguration.Builder builder, string connectionString, string database, TimeSpan?timeout = null, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(MongoDbWatcher.Create(connectionString, database, timeout, group: group), hooks, interval); return(builder); }
/// <summary> /// Extension method for adding the Server watcher to the the WardenConfiguration with the default name of Server watcher. /// </summary> /// <param name="builder">Instance of the Warden configuration builder.</param> /// <param name="hostname">Hostname to be resolved.</param> /// <param name="configurator">Lambda expression for configuring the ServerWatcher.</param> /// <param name="hooks">Optional lambda expression for configuring the watcher hooks.</param> /// <param name="port">Optional port number of the hostname (0 means not specified).</param> /// <param name="interval">Optional interval (5 seconds by default) after which the next check will be invoked.</param> /// <param name="group">Optional name of the group that ServerWatcher belongs to.</param> /// <returns>Instance of fluent builder for the WardenConfiguration.</returns> public static WardenConfiguration.Builder AddServerWatcher( this WardenConfiguration.Builder builder, string hostname, Action <ServerWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, int port = 0, TimeSpan?interval = null, string group = null) { builder.AddWatcher(ServerWatcher.Create(hostname, port, configurator, group), hooks, interval); return(builder); }
public static WardenConfiguration.Builder AddAzureServiceBusWatcher(this WardenConfiguration.Builder builder, string connectionString, Action <AzureServiceBusWatcherConfiguration.Default> configurator, Action <WatcherHooksConfiguration.Builder> hooks = null, TimeSpan?interval = null, string group = null) { builder.AddWatcher(AzureServiceBusWatcher.Create(connectionString, configurator, @group: group), hooks, interval); return(builder); }