Class SyncServerTransport
Provides server-side functionality for synchronous communication pattern based on TCP blocking sockets and Slim serializer for maximum serialization performance and lowest latency. The SyncBinding is usable for interconnection between Azos-native components on LANs (i.e. server clusters) in scenarios when low latency is more important than total call invocation throughput. SyncServerTransport uses dedicated thread for request processing and is not scalable beyond a few hundred connections by design, however it provides low latency benefit
Inheritance
System.Object
SyncServerTransport
Implements
System.IDisposable
Inherited Members
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)
Namespace: Azos.Glue.Native
Assembly: Azos.dll
Syntax
public class SyncServerTransport : ServerTransport<SyncBinding>, IDisposable, IDaemon, IDaemonView, IApplicationComponent, INamed, IConfigurable, ILocalizedTimeProvider
Constructors
SyncServerTransport(SyncBinding, ServerEndPoint, IPAddress, Int32)
Allocates a listener transport
Declaration
public SyncServerTransport(SyncBinding binding, ServerEndPoint serverEndpoint, IPAddress localAddr, int port)
Parameters
Type | Name | Description |
---|---|---|
SyncBinding | binding | |
ServerEndPoint | serverEndpoint | |
System.Net.IPAddress | localAddr | |
System.Int32 | port |
Fields
THREAD_NAME
Declaration
public const string THREAD_NAME = "SyncServerTransport.Listener"
Field Value
Type | Description |
---|---|
System.String |
Methods
DoDecodeRequest(WireFrame, MemoryStream, ISerializer)
Decode the ResponseMsg per fame.Format, ms.Position is set after frame
Declaration
protected virtual RequestMsg DoDecodeRequest(WireFrame frame, MemoryStream ms, ISerializer serializer)
Parameters
Type | Name | Description |
---|---|---|
WireFrame | frame | |
System.IO.MemoryStream | ms | |
ISerializer | serializer |
Returns
Type | Description |
---|---|
RequestMsg |
DoDumpInstrumentationData()
Declaration
protected override void DoDumpInstrumentationData()
Overrides
DoEncodeResponse(MemoryStream, ResponseMsg, ISerializer)
Encode the ResponseMsg per FrameFormat, ms.Position is set after frame
Declaration
protected virtual void DoEncodeResponse(MemoryStream ms, ResponseMsg msg, ISerializer serializer)
Parameters
Type | Name | Description |
---|---|---|
System.IO.MemoryStream | ms | |
ResponseMsg | msg | |
ISerializer | serializer |
DoSendResponse(ResponseMsg)
Declaration
protected override bool DoSendResponse(ResponseMsg response)
Parameters
Type | Name | Description |
---|---|---|
ResponseMsg | response |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
DoSignalStop()
Declaration
protected override void DoSignalStop()
Overrides
DoStart()
Declaration
protected override void DoStart()
Overrides
DoWaitForCompleteStop()
Declaration
protected override void DoWaitForCompleteStop()
Overrides
Implements
System.IDisposable