IResourceMonitorBuilder.AddPublisher<T> Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Caution
This API is obsolete and will be removed in a future version. Consider using Resource Monitoring observable instruments.
Adds a resource utilization publisher that gets invoked whenever resource utilization is computed.
public:
generic <typename T>
where T : class, Microsoft::Extensions::Diagnostics::ResourceMonitoring::IResourceUtilizationPublisher Microsoft::Extensions::Diagnostics::ResourceMonitoring::IResourceMonitorBuilder ^ AddPublisher();
[System.Obsolete("This API is obsolete and will be removed in a future version. Consider using Resource Monitoring observable instruments.", DiagnosticId="EXTOBS0001", UrlFormat="https://aka.ms/dotnet-extensions-warnings/{0}")]
public Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceMonitorBuilder AddPublisher<T> () where T : class, Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceUtilizationPublisher;
public Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceMonitorBuilder AddPublisher<T> () where T : class, Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceUtilizationPublisher;
[<System.Obsolete("This API is obsolete and will be removed in a future version. Consider using Resource Monitoring observable instruments.", DiagnosticId="EXTOBS0001", UrlFormat="https://aka.ms/dotnet-extensions-warnings/{0}")>]
abstract member AddPublisher : unit -> Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceMonitorBuilder (requires 'T : null and 'T :> Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceUtilizationPublisher)
abstract member AddPublisher : unit -> Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceMonitorBuilder (requires 'T : null and 'T :> Microsoft.Extensions.Diagnostics.ResourceMonitoring.IResourceUtilizationPublisher)
Public Function AddPublisher(Of T As {Class, IResourceUtilizationPublisher}) () As IResourceMonitorBuilder
Type Parameters
- T
The publisher's implementation type.
Returns
The value of the object instance.
- Attributes
Applies to
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.