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

Have pelican plugin move files in parallel #674

Conversation

joereuss12
Copy link
Contributor

Now the plugin can move files just like handle_http does, starts up many workers and has a producer/consumer setup to download files in parallel.

@joereuss12
Copy link
Contributor Author

This is still a work in progress so setting as a draft.

@joereuss12 joereuss12 linked an issue Jan 19, 2024 that may be closed by this pull request
@joereuss12 joereuss12 marked this pull request as ready for review January 19, 2024 19:40
@joereuss12
Copy link
Contributor Author

Smoke tests seem to show that this is working how it should, ready for review.

@joereuss12 joereuss12 requested a review from bbockelm January 22, 2024 15:05
@bbockelm
Copy link
Collaborator

Haven't had time for a full review but to provide some early feedback:

https://github.com/PelicanPlatform/pelican/pull/674/files#diff-417e18b3b05bac37d2ebbc44d3be121f6026e5e4ab13e6400d0eb879027c5160R232-R240

This is approximately the design of the current parallel download when moving a directory. I want to improve things, however, by having the result of individual transfers be returned on a channel. That means there's a single for-loop that's both writing new tasks and reading results.

For example of what this would give us: right now, there's a hard synchronization -- all transfers must complete before the overall process can fail. We know that we instead will want to fail all of them after the first transfer fails in the case of inputs.

Now the plugin can move files just like handle_http does, starts up many
workers and has a producer/consumer setup to download files in parallel.
Allows us to bail early if we encounter a failure on downloads
Now just has 1 for loop for sending work and interpreting results as
soon as we get them. The plugin should bail early if a download/any
error happens.
@joereuss12 joereuss12 requested review from jhiemstrawisc and removed request for bbockelm January 30, 2024 15:19
Copy link
Member

@jhiemstrawisc jhiemstrawisc left a comment

Choose a reason for hiding this comment

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

LGTM

@jhiemstrawisc jhiemstrawisc merged commit 199fb7c into PelicanPlatform:main Jan 30, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants