Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upload: add TeeReader to count bytes during upload #54

Merged
merged 1 commit into from
Feb 14, 2024
Merged

Conversation

emranemran
Copy link
Contributor

We occasionally see an EOF error when attempting to upload to S3 storage. An EOF from io.ReadCloser interfaces typically indicates that no more input is available. This commit is adding a TeeReader to count the number of bytes that were read from the local input file when attempting to upload -- this should help us diagnose upload errors where segments seem to be missing from s3 buckets.

We occasionally see an EOF error when attempting to upload to S3
storage. An EOF from io.ReadCloser interfaces typically indicates that
no more input is available. This commit is adding a TeeReader to count
the number of bytes that were read from the local input file when
attempting to upload -- this should help us diagnose upload errors where
segments seem to be missing from s3 buckets.
Copy link

codecov bot commented Feb 14, 2024

Codecov Report

Attention: 8 lines in your changes are missing coverage. Please review.

Comparison is base (eecd216) 16.85393% compared to head (c16d4dd) 16.84783%.

Additional details and impacted files

Impacted file tree graph

@@                 Coverage Diff                 @@
##                main         #54         +/-   ##
===================================================
- Coverage   16.85393%   16.84783%   -0.00610%     
===================================================
  Files              2           2                 
  Lines            178         184          +6     
===================================================
+ Hits              30          31          +1     
- Misses           140         145          +5     
  Partials           8           8                 
Files Coverage Δ
core/uploader.go 23.30827% <11.11111%> (-0.31378%) ⬇️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update eecd216...c16d4dd. Read the comment docs.

Files Coverage Δ
core/uploader.go 23.30827% <11.11111%> (-0.31378%) ⬇️

@mjh1 mjh1 merged commit 567aec3 into main Feb 14, 2024
10 checks passed
@mjh1 mjh1 deleted the emran/upload-log branch February 14, 2024 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants