Show / Hide Table of Contents

Class Transport

Transports are thread-safe and are intended for use by multiple threads from ClientCallReactor and ServerProcessor when bindings operate in OperationFlow.Asynchronous mode. Transports are acquired by the thread that creates them

Inheritance
System.Object
DisposableObject
ApplicationComponent
Service
Service<Binding>
Transport
ClientTransport
ServerTransport
Implements
IApplicationComponent
System.IDisposable
IService
INamed
IConfigurable
ILocalizedTimeProvider
Inherited Members
Service<Binding>.ComponentDirector
Service.CONFIG_NAME_ATTR
Service.ApplicationDontAutoStartService
Service.Status
Service.Running
Service.Name
Service.TimeLocation
Service.LocalizedTime
Service.Configure(IConfigSectionNode)
Service.Start()
Service.SignalStop()
Service.CheckForCompleteStop()
Service.WaitForCompleteStop()
Service.AcceptManagerVisit(Object, DateTime)
Service.UniversalTimeToLocalizedTime(DateTime)
Service.LocalizedTimeToUniversalTime(DateTime)
Service.AbortStart()
Service.DoSignalStop()
Service.DoCheckForCompleteStop()
Service.DoWaitForCompleteStop()
Service.DoConfigure(IConfigSectionNode)
Service.CheckServiceInactive()
Service.CheckServiceActive()
Service.CheckServiceActiveOrStarting()
Service.DoAcceptManagerVisit(Object, DateTime)
Service.____ObtainPrivateServiceStatusLockObject()
ApplicationComponent.AllComponents
ApplicationComponent.GetAppComponentBySID(UInt64)
ApplicationComponent.GetAppComponentByCommonName(String)
ApplicationComponent.ComponentSID
ApplicationComponent.ComponentStartTime
ApplicationComponent.ComponentCommonName
DisposableObject.DisposeAndNull<T>(T)
DisposableObject.DisposeStarted
DisposableObject.Disposed
DisposableObject.EnsureObjectNotDisposed()
DisposableObject.Dispose()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: NFX.Glue
Assembly: NFX.dll
Syntax
public abstract class Transport : Service<Binding>, IApplicationComponent, IDisposable, IService, INamed, IConfigurable, ILocalizedTimeProvider

Constructors

Transport(Binding, TransportKind)

Declaration
protected Transport(Binding binding, TransportKind kind)
Parameters
Type Name Description
Binding binding
TransportKind kind

Fields

m_TransportKind

Declaration
protected TransportKind m_TransportKind
Field Value
Type Description
TransportKind

Properties

Acquired

Returns true when this transport instance has been acquired by some operation and is busy

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

Binding

Returns a binding that this transport operates under

Declaration
public Binding Binding { get; }
Property Value
Type Description
Binding

ExpirationStart

Returns timestamp when manager touched the instance for last time and no traffic went through it since

Declaration
public DateTime? ExpirationStart { get; }
Property Value
Type Description
System.Nullable<System.DateTime>

Glue

Returns glue implementation that this transport is under

Declaration
public IGlueImplementation Glue { get; }
Property Value
Type Description
IGlueImplementation

IdleAgeMs

Returns the duration of transport idle period in ms.

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

Node

Returns node that this transport services

Declaration
public Node Node { get; protected set; }
Property Value
Type Description
Node

StatBytesReceived

Returns how many bytes were received since .ctor or last ResetStats() call

Declaration
public long StatBytesReceived { get; }
Property Value
Type Description
System.Int64

StatBytesSent

Returns how many bytes were sent since .ctor or last ResetStats() call

Declaration
public long StatBytesSent { get; }
Property Value
Type Description
System.Int64

StatErrors

Returns how many message processing errors happened since .ctor or last ResetStats() call

Declaration
public long StatErrors { get; }
Property Value
Type Description
System.Int64

StatMsgReceived

Returns how many messages were received since .ctor or last ResetStats() call

Declaration
public long StatMsgReceived { get; }
Property Value
Type Description
System.Int64

StatMsgSent

Returns how many messages were sent since .ctor or last ResetStats() call

Declaration
public long StatMsgSent { get; }
Property Value
Type Description
System.Int64

StatTimes

Returns enumerable of named times measured in double second fractions. The returned times are EMA-filtered from supplied individual measurement samples

Declaration
public IEnumerable<KeyValuePair<string, double>> StatTimes { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<System.String, System.Double>>

TransportKind

Reports if this is a server or client transport

Declaration
public TransportKind TransportKind { get; }
Property Value
Type Description
TransportKind

Methods

CheckRunningState()

Ensures that application and transport instance are running or throws otherwise

Declaration
public void CheckRunningState()

Destructor()

Declaration
protected override void Destructor()
Overrides
Service.Destructor()

DoDumpInstrumentationData()

Override to dump instrumentation data, dont forget to call base to dump basic metrics

Declaration
protected virtual void DoDumpInstrumentationData()

DoStart()

Declaration
protected override void DoStart()
Overrides
Service.DoStart()

DumpInstrumentationData()

Dumps instrumentation data

Declaration
public void DumpInstrumentationData()

Release()

Releases transport by setting Acquired flag to false so it can be used by other operations

Declaration
public void Release()

ResetStats()

Resets all statistical counters

Declaration
public void ResetStats()

stat_BytesReceived(Int64)

Declaration
protected void stat_BytesReceived(long val)
Parameters
Type Name Description
System.Int64 val

stat_BytesSent(Int64)

Declaration
protected void stat_BytesSent(long val)
Parameters
Type Name Description
System.Int64 val

stat_Errors()

Declaration
protected void stat_Errors()

stat_MsgReceived(Int64)

Declaration
protected void stat_MsgReceived(long count = 1L)
Parameters
Type Name Description
System.Int64 count

stat_MsgSent()

Declaration
protected void stat_MsgSent()

stat_Time(String, Int64)

Processes named time measurement statistical sample by using EMA filter

Declaration
protected void stat_Time(string key, long ticks)
Parameters
Type Name Description
System.String key

Name of time measurement key

System.Int64 ticks

Duration in ticks

TryAcquire()

A thread-safe operation that tries to acquire(reserve) this instance for exclusive use. Returns true if acqusition succeded, false is this instance is reserved by someone else

Declaration
public bool TryAcquire()
Returns
Type Description
System.Boolean

Implements

IApplicationComponent
System.IDisposable
IService
INamed
IConfigurable
ILocalizedTimeProvider

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