private void HandleTransferError(ITftpTransfer transfer, TftpTransferError error) { _logger.LogWarning( "Transfer {0} has failed with an error: {1}.", _transferId, error.ToString()); var evt = new TftpDownloadFailedEvent( _clientInfo, _clock.GetOffsetNow(), _transferId, transfer.Filename, error.ToString()); _logService.LogEvent(evt); }
public SlidingExpirationItem(TItem item, TimeSpan slidingExpiration, IClock clock) { _slidingExpiration = slidingExpiration; _clock = clock; Item = item; _lastAccessed = _clock.GetOffsetNow(); }
public void ResetExpirationWindow() { _lastAccessed = _clock.GetOffsetNow(); }