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

replacing gcs.Object with gcs.MinObject in gcs.Listing #2657

Merged
merged 5 commits into from
Nov 8, 2024

Conversation

anushka567
Copy link
Member

Description

We are fetching only MinObject attributes for reducing list API payload in this PR , creating a gcs.Object using the attributes fetched, converting this gcs.Object to gcs.MinObject , and ultimately , storing minObject in cache for serving listobject requests, the conversion from gcs.Object to gcs.MinObject is redundant.

Hence, in this PR, the gcs.Listing struct is modified to store gcs.MinObject instead of gcs.Object so that attributes fetched can be used to directly populate the minObject and stored in cache.

Link to the issue in case of a bug fix.

NA

Testing details

  1. Manual - NA
  2. Unit tests - NA
  3. Integration tests - NA

@anushka567 anushka567 added the execute-integration-tests Run only integration tests label Nov 6, 2024
Copy link

codecov bot commented Nov 6, 2024

Codecov Report

Attention: Patch coverage is 95.00000% with 11 lines in your changes missing coverage. Please review.

Project coverage is 77.44%. Comparing base (ede87e1) to head (dedc240).
Report is 9 commits behind head on master.

Files with missing lines Patch % Lines
internal/gcsx/garbage_collect.go 0.00% 4 Missing ⚠️
internal/storage/bucket_handle.go 42.85% 3 Missing and 1 partial ⚠️
internal/storage/storageutil/object_attrs.go 82.35% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2657      +/-   ##
==========================================
- Coverage   77.56%   77.44%   -0.12%     
==========================================
  Files         109      110       +1     
  Lines       15576    15676     +100     
==========================================
+ Hits        12081    12141      +60     
- Misses       2979     3014      +35     
- Partials      516      521       +5     
Flag Coverage Δ
unittests 77.44% <95.00%> (-0.12%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@anushka567 anushka567 changed the title replacing gcs.Object with gcs.MinObject in gcs.Listing [Don't review]replacing gcs.Object with gcs.MinObject in gcs.Listing Nov 6, 2024
@anushka567 anushka567 marked this pull request as ready for review November 6, 2024 05:24
@anushka567 anushka567 requested a review from a team as a code owner November 6, 2024 05:24
@anushka567 anushka567 changed the base branch from reduce-list-api-payload to master November 6, 2024 05:24
@anushka567 anushka567 changed the base branch from master to reduce-list-api-payload November 6, 2024 05:25
@anushka567 anushka567 changed the title [Don't review]replacing gcs.Object with gcs.MinObject in gcs.Listing replacing gcs.Object with gcs.MinObject in gcs.Listing Nov 7, 2024
@anushka567 anushka567 changed the base branch from reduce-list-api-payload to master November 7, 2024 08:43
@anushka567 anushka567 merged commit d46cd46 into master Nov 8, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
execute-integration-tests Run only integration tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants