public TcpOutputChannel(string host, int port, bool reconnectEnabled = true, int retryAttempts = 3)
 {
     _host = host;
     _port = port;
     _reconnectEnabled = reconnectEnabled;
     _retryAttempts = retryAttempts;
     _tcpClient = new TcpClient();
     _asyncLock = new AsyncLock();
 }
 public StatsdTCP(string host, int port, bool reconnectEnabled = true, int retryAttempts = 3)
     : base(host, port, 0) // 0 means unlimited packet size (we don't want to split up our TCP stream)
 {
     _reconnectEnabled = reconnectEnabled;
     _retryAttempts = retryAttempts;
     localIp = Dns.GetHostEntry(Dns.GetHostName()).AddressList
         .FirstOrDefault(x => x.AddressFamily == AddressFamily.InterNetwork);
     clientLock = new AsyncLock();
 }
 internal Releaser(AsyncLock toRelease)
 {
     _toRelease = toRelease;
 }
Esempio n. 4
0
 internal Releaser(AsyncLock toRelease)
 {
     _toRelease = toRelease;
 }