Show / Hide Table of Contents

Interface IInstrumentation

Stipulates instrumentation contract

Inherited Members
IApplicationComponent.ComponentSID
IApplicationComponent.ComponentDirector
IApplicationComponent.ComponentCommonName
System.IDisposable.Dispose()
ILocalizedTimeProvider.TimeLocation
ILocalizedTimeProvider.LocalizedTime
ILocalizedTimeProvider.UniversalTimeToLocalizedTime(DateTime)
ILocalizedTimeProvider.LocalizedTimeToUniversalTime(DateTime)
Namespace: NFX.Instrumentation
Assembly: NFX.dll
Syntax
public interface IInstrumentation : IApplicationComponent, IDisposable, ILocalizedTimeProvider

Properties

DataTypes

Enumerates distinct types of Datum ever recorded in the instance. This property may be used to build UIs for instrumentation, i.e. datum type tree. Returned data is NOT ORDERED

Declaration
IEnumerable<Type> DataTypes { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<System.Type>

Enabled

Indicates whether instrumentation is enabled

Declaration
bool Enabled { get; }
Property Value
Type Description
System.Boolean

MaxRecordCount

Gets/Sets the maximum record count that this instance can store

Declaration
int MaxRecordCount { get; }
Property Value
Type Description
System.Int32

OSInstrumentationIntervalMS

Specifies how often OS instrumentation such as CPU and RAM is sampled. Value of zero disables OS sampling

Declaration
int OSInstrumentationIntervalMS { get; }
Property Value
Type Description
System.Int32

Overflown

Returns true to indicate that instrumentation does not have any space left to record more data at the present moment

Declaration
bool Overflown { get; }
Property Value
Type Description
System.Boolean

ProcessingIntervalMS

Specifies how often aggregation is performed

Declaration
int ProcessingIntervalMS { get; }
Property Value
Type Description
System.Int32

RecordCount

Returns current record count in the instance

Declaration
int RecordCount { get; }
Property Value
Type Description
System.Int32

ResultBufferSize

Returns the size of the ring buffer where result (aggregated) instrumentation records are kept in memory. The maximum buffer capacity is returned, not how many results have been buffered so far. If this property is less than or equal to zero then result buffering in memory is disabled

Declaration
int ResultBufferSize { get; }
Property Value
Type Description
System.Int32

SelfInstrumented

When true, outputs instrumentation data about the self (how many datum buffers, etc.)

Declaration
bool SelfInstrumented { get; }
Property Value
Type Description
System.Boolean

Methods

GetBufferedResults(Int32)

Returns the specified number of samples from the ring result buffer in the near-chronological order, meaning that data is already sorted by time MOST of the TIME, however sorting is NOT GUARANTEED for all result records returned as enumeration is a lazy procedure that does not make copies/take locks. The enumeration is empty if ResultBufferSize is less or equal to zero entries. If count is less or equal to zero then the system returns all results available.

Declaration
IEnumerable<Datum> GetBufferedResults(int count = 0)
Parameters
Type Name Description
System.Int32 count
Returns
Type Description
System.Collections.Generic.IEnumerable<Datum>

GetBufferedResultsSince(DateTime)

Returns samples starting around the the specified UTCdate in the near-chronological order, meaning that data is already sorted by time MOST of the TIME, however sorting is NOT GUARANTEED for all result records returned as enumeration is a lazy procedure that does not make copies/take locks. The enumeration is empty if ResultBufferSize is less or equal to zero entries

Declaration
IEnumerable<Datum> GetBufferedResultsSince(DateTime utcStart)
Parameters
Type Name Description
System.DateTime utcStart
Returns
Type Description
System.Collections.Generic.IEnumerable<Datum>

GetDatumTypeSources(Type, out Datum)

Enumerates sources per Datum type ever recorded by the instance. This property may be used to build UIs for instrumentation, i.e. datum type tree. Returned data is NOT ORDERED. Returns default instance so caller may get default description/unit name

Declaration
IEnumerable<string> GetDatumTypeSources(Type datumType, out Datum defaultInstance)
Parameters
Type Name Description
System.Type datumType
Datum defaultInstance
Returns
Type Description
System.Collections.Generic.IEnumerable<System.String>

Record(Datum)

Records instrumentation datum

Declaration
void Record(Datum datum)
Parameters
Type Name Description
Datum datum

Extension Methods

MiscUtils.NonNull<T>(T, Func<Exception>, String)
ObjectValueConversion.AsString(Object, String, ConvertErrorHandling)
ObjectValueConversion.AsNonNullOrEmptyString(Object)
ObjectValueConversion.AsLaconicConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsJSONConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsXMLConfig(Object, ConfigSectionNode, ConvertErrorHandling)
ObjectValueConversion.AsChar(Object, Char, ConvertErrorHandling)
ObjectValueConversion.AsNullableChar(Object, Nullable<Char>, ConvertErrorHandling)
ObjectValueConversion.AsByte(Object, Byte, ConvertErrorHandling)
ObjectValueConversion.AsNullableByte(Object, Nullable<Byte>, ConvertErrorHandling)
ObjectValueConversion.AsSByte(Object, SByte, ConvertErrorHandling)
ObjectValueConversion.AsNullableSByte(Object, Nullable<SByte>, ConvertErrorHandling)
ObjectValueConversion.AsShort(Object, Int16, ConvertErrorHandling)
ObjectValueConversion.AsNullableShort(Object, Nullable<Int16>, ConvertErrorHandling)
ObjectValueConversion.AsUShort(Object, UInt16, ConvertErrorHandling)
ObjectValueConversion.AsNullableUShort(Object, Nullable<UInt16>, ConvertErrorHandling)
ObjectValueConversion.AsInt(Object, Int32, ConvertErrorHandling)
ObjectValueConversion.AsNullableInt(Object, Nullable<Int32>, ConvertErrorHandling)
ObjectValueConversion.AsUInt(Object, UInt32, ConvertErrorHandling)
ObjectValueConversion.AsNullableUInt(Object, Nullable<UInt32>, ConvertErrorHandling)
ObjectValueConversion.AsLong(Object, Int64, ConvertErrorHandling)
ObjectValueConversion.AsNullableLong(Object, Nullable<Int64>, ConvertErrorHandling)
ObjectValueConversion.AsULong(Object, UInt64, ConvertErrorHandling)
ObjectValueConversion.AsNullableULong(Object, Nullable<UInt64>, ConvertErrorHandling)
ObjectValueConversion.AsDouble(Object, Double, ConvertErrorHandling)
ObjectValueConversion.AsNullableDouble(Object, Nullable<Double>, ConvertErrorHandling)
ObjectValueConversion.AsFloat(Object, Single, ConvertErrorHandling)
ObjectValueConversion.AsNullableFloat(Object, Nullable<Single>, ConvertErrorHandling)
ObjectValueConversion.AsDecimal(Object, Decimal, ConvertErrorHandling)
ObjectValueConversion.AsNullableDecimal(Object, Nullable<Decimal>, ConvertErrorHandling)
ObjectValueConversion.AsBool(Object, Boolean, ConvertErrorHandling)
ObjectValueConversion.AsNullableBool(Object, Nullable<Boolean>, ConvertErrorHandling)
ObjectValueConversion.AsGUID(Object, Guid, ConvertErrorHandling)
ObjectValueConversion.AsNullableGUID(Object, Nullable<Guid>, ConvertErrorHandling)
ObjectValueConversion.AsDateTime(Object)
ObjectValueConversion.AsDateTime(Object, DateTime, ConvertErrorHandling)
ObjectValueConversion.AsNullableDateTime(Object, Nullable<DateTime>, ConvertErrorHandling)
ObjectValueConversion.AsGDID(Object)
ObjectValueConversion.AsGDID(Object, GDID, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDID(Object, Nullable<GDID>, ConvertErrorHandling)
ObjectValueConversion.AsGDIDSymbol(Object)
ObjectValueConversion.AsGDIDSymbol(Object, GDIDSymbol, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDIDSymbol(Object, Nullable<GDIDSymbol>, ConvertErrorHandling)
ObjectValueConversion.AsTimeSpan(Object)
ObjectValueConversion.AsTimeSpan(Object, TimeSpan, ConvertErrorHandling)
ObjectValueConversion.AsNullableTimeSpan(Object, Nullable<TimeSpan>, ConvertErrorHandling)
ObjectValueConversion.AsEnum<TEnum>(Object, TEnum, ConvertErrorHandling)
ObjectValueConversion.AsNullableEnum<TEnum>(Object, Nullable<TEnum>, ConvertErrorHandling)
ObjectValueConversion.AsUri(Object, Uri, ConvertErrorHandling)
JSONExtensions.ToJSON(Object, JSONWritingOptions)
JSONExtensions.ToJSON(Object, TextWriter, JSONWritingOptions)
JSONExtensions.ToJSON(Object, Stream, JSONWritingOptions, Encoding)
ErlObject.ToErlObject(Object)
ErlObject.ToErlObject(Object, ErlTypeOrder, Boolean)
Back to top Copyright © 2006-2018 Agnicore Inc
Generated by DocFX