anchor.diff:      end.
   
   now_to_msec({Mega,Sec,_}) -> (Mega*1000000 + Sec)*1000.
  +
  +default_buf_size() -> logplex_app:config(tcp_drain_buffer_size, 1024).
  
positive.code:                 false ->
                      Buf
              end;
          false ->
              Buf
      end,
      %% We hibernate only when we need to reconnect with a timer. The timer
  
negative.code:                 port :: inet:port_number(),
                  sock = undefined :: 'undefined' | inet:socket(),
                  %% Buffer for messages while disconnected
                  buf = logplex_msg_buffer:new(default_buf_size()) :: logplex_msg_buffer:buf(),
                  %% Last time we connected or successfully sent data
                  last_good_time :: 'undefined' | erlang:timestamp(),
                  %% TCP failures since last_good_time
  