Export (0) Print
Expand All

HealthMonitoringSection.HeartbeatInterval Property

Gets or sets the interval used by the application domain when it raises the WebHeartbeatEvent event.

Namespace:  System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)

[ConfigurationPropertyAttribute("heartbeatInterval", DefaultValue = "00:00:00")]
[TypeConverterAttribute(typeof(TimeSpanSecondsConverter))]
[TimeSpanValidatorAttribute(MinValueString = "00:00:00", MaxValueString = "24.20:31:23")]
public TimeSpan HeartbeatInterval { get; set; }

Property Value

Type: System.TimeSpan
The interval used by the application domain when it raises the WebHeartbeatEvent event.

If the TimeSpan value is zero ticks, no WebHeartbeatEvent event is raised.

The following code example shows how to use the HeartBeatInterval property. This code example is part of a larger example provided for the HealthMonitoringSection class.


// Get the current HeartBeatInterval property value.
TimeSpan heartBeatIntervalValue = healthMonitoringSection.HeartbeatInterval;

// Set the HeartBeatInterval property to 
// TimeSpan.Parse("00:10:00").
healthMonitoringSection.HeartbeatInterval = TimeSpan.Parse("00:10:00");

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0
Show:
© 2015 Microsoft