Click or drag to resize
Akka.NETTcpExtBind Method
Creates a TcpServerBinding instance which represents a prospective TCP server binding on the given host and port/>.

Please note that the startup of the server is asynchronous, i.e. after materializing the enclosing RunnableGraphTMat the server is not immediately available. Only after the materialized future completes is the server ready to accept client connections.

Namespace:  Akka.Streams.Dsl
Assembly:  Akka.Streams (in Akka.Streams.dll) Version: 1.2.3.129 (1.2.3.129)
Syntax
public Source<TcpIncomingConnection, Task<TcpServerBinding>> Bind(
	string host,
	int port,
	int backlog = 100,
	IImmutableList<InetSocketOption> options = null,
	bool halfClose = false,
	Nullable<TimeSpan> idleTimeout = null
)

Parameters

host
Type: SystemString
The host to listen on
port
Type: SystemInt32
The port to listen on
backlog (Optional)
Type: SystemInt32
Controls the size of the connection backlog
options (Optional)
Type: IImmutableListInetSocketOption
TCP options for the connections, see Tcp for details
halfClose (Optional)
Type: SystemBoolean
Controls whether the connection is kept open even after writing has been completed to the accepted TCP connections. If set to true, the connection will implement the TCP half-close mechanism, allowing the client to write to the connection even after the server has finished writing. The TCP socket is only closed after both the client and server finished writing. If set to false, the connection will immediately closed once the server closes its write side, independently whether the client is still attempting to write. This setting is recommended for servers, and therefore it is the default setting.
idleTimeout (Optional)
Type: SystemNullableTimeSpan
TBD

Return Value

Type: SourceTcpIncomingConnection, TaskTcpServerBinding
TBD
Exceptions
ExceptionCondition
ArgumentExceptionTBD
See Also