Skip to content
This repository was archived by the owner on Mar 3, 2026. It is now read-only.

feat: add crc32c validation option to chunked download, cleanup naming#2110

Merged
ddelgrosso1 merged 2 commits intogoogleapis:transfer-managerfrom
ddelgrosso1:validation-tm
Dec 6, 2022
Merged

feat: add crc32c validation option to chunked download, cleanup naming#2110
ddelgrosso1 merged 2 commits intogoogleapis:transfer-managerfrom
ddelgrosso1:validation-tm

Conversation

@ddelgrosso1
Copy link
Copy Markdown
Contributor

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes #<issue_number_goes_here> 🦕

@ddelgrosso1 ddelgrosso1 requested review from a team December 5, 2022 22:47
@product-auto-label product-auto-label Bot added size: m Pull request size is medium. api: storage Issues related to the googleapis/nodejs-storage API. labels Dec 5, 2022
Copy link
Copy Markdown
Contributor

@shaffeeullah shaffeeullah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good! pls double check that docs check failure is expected before merging.

Copy link
Copy Markdown
Contributor

@frankyn frankyn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just had one question; otherwise LGTM

Comment thread src/transfer-manager.ts
.then(data => {
results = data.map(result => result.buffer) as DownloadResponse;
if (options.validation === 'crc32c') {
return CRC32C.fromFile(filePath);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a post processing hash validation step once for both single download and multi-chunk download?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a post-file download CRC32C validation (if enabled). It will occur if the user opts in and the file is downloaded as a single chunk or mutichunks

@ddelgrosso1
Copy link
Copy Markdown
Contributor Author

@shaffeeullah docs failure is because of 404 for the new samples I added.

@ddelgrosso1 ddelgrosso1 merged commit f8b6819 into googleapis:transfer-manager Dec 6, 2022
@ddelgrosso1 ddelgrosso1 deleted the validation-tm branch December 6, 2022 20:34
ddelgrosso1 added a commit that referenced this pull request Dec 7, 2022
* feat: implement parallel operations (#2067)

* feat: implement parallel operations

* add more parallel operations

* add header to test file

* update import of fs/promises

* fix pathing on windows, fix mocking of fs promises

* add jsdoc headers to class and uploadMulti

* add jsdoc comments to remaining functions

* update comment wording

* add experimental jsdoc tags

* feat: add directory generator to performance test framework

* clarify variable names and comments

* capitalization

* wip: transfer manager performance tests

* feat: merged in application performance tests (#2100)

* fix: fixed many bugs (#2102)

* fix: cleaning up bugs

* fix: fixed many bugs

* fix: more work on transfer manager perf metrics (#2103)

* fix: more work on transfer manager perf metrics

* fix unit tests for tm

* fix: performance test refactoring, comments (#2104)

* refactor: refactor constants (#2105)

* refactor: refactor constants

* bug fixes

* bug fixes

* bug fixes

* linter fixes, download to disk for performance test

* rename transfer manager functions

* remove callbacks from transfer manager

* add more experimental tags, update comments

* change signature of downloadManyFiles to accept array of strings or a folder name

* linter fix

* add transfer manager samples and samples tests

Co-authored-by: Sameena Shaffeeullah <shaffeeullah@google.com>

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* feat: add crc32c validation option to chunked download, cleanup naming (#2110)

* feat: add crc32c validation option to chunked download, cleanup naming in perf tests

* close file in finally block

Co-authored-by: Sameena Shaffeeullah <shaffeeullah@google.com>
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: storage Issues related to the googleapis/nodejs-storage API. size: m Pull request size is medium.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants