async Task <Uri> IMessageDataRepository.Put(Stream stream, TimeSpan?timeToLive, CancellationToken cancellationToken)
        {
            var options = BuildGridFsUploadOptions(timeToLive);

            var filename = _fileNameGenerator.GenerateFileName();

            var id = await _bucket.UploadFromStreamAsync(filename, stream, options, cancellationToken)
                     .ConfigureAwait(false);

            LogContext.Debug?.Log("MessageData:Put {Id} {FileName}", id, filename);

            return(_resolver.GetAddress(id));
        }
        async Task <Uri> IMessageDataRepository.Put(Stream stream, TimeSpan?timeToLive, CancellationToken cancellationToken)
        {
            var options = BuildGridFsUploadOptions(timeToLive);

            var filename = _fileNameGenerator.GenerateFileName();

            var id = await _bucket.UploadFromStreamAsync(filename, stream, options, cancellationToken)
                     .ConfigureAwait(false);

            if (_log.IsDebugEnabled)
            {
                _log.DebugFormat("MessageData:Put {0} - {1}", id, filename);
            }

            return(_resolver.GetAddress(id));
        }