TcpSettings

TcpSettings class

Represents TCP network settings.

public class TcpSettings : INetworkSettings

Constructors

Name Description
TcpSettings(int, int, int, int, int) Initializes a new instance of the TcpSettings class.

Properties

Name Description
AllowedMasterAddresses { get; set; } Gets or sets the addresses from which a slave node accepts the connection of the master node: IPv4 addresses or host names, which are resolved at each connection. A connection from another address is closed at once and logged. The master node does not use the setting. The default value is null: a slave node accepts a connection from any address.
ConnectTimeout { get; } Gets the connect timeout in milliseconds. When two nodes connect, each of them waits for every message of the other in the exchange that starts the connection no longer than this time.
ListeningPort { get; } Gets the listening port.
NetworkKey { get; set; } Gets or sets the secret key of the search network. The nodes of a network with the key prove to each other that they know it when they connect, and sign every message: a computer without the key can neither give commands to a node nor answer for a node, and a changed, repeated or forged message breaks the connection. All the nodes of a network have the same key. The key is not a part of the configuration of the network and is not sent over the network; the messages themselves are not encrypted. The default value is null: the nodes have no key and carry out the commands of any computer that connects to them, and each node writes a warning to its log when it is created.
ReceiveTimeout { get; } Gets the receive timeout in milliseconds.
ResponseTimeout { get; set; } Gets or sets the time in milliseconds in which the master node waits for the answer of a node to a request. A request that is not answered in time fails: a call of the network throws SearchException, and an operation reports the document or the shard by the ErrorOccurred event. The default value is Infinite: the master node waits without a limit. In any case the requests of a node fail at once when its connection is broken or when it sends nothing for 15 seconds.
RetryTimeout { get; } Gets the retry timeout in milliseconds.
SendTimeout { get; } Gets the send timeout in milliseconds.

See Also