Project

Profile

Help

Task #3923

closed

Remove the GroupDownloader

Added by bmbouter over 6 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Sprint:
Sprint 42
Quarter:

Description

The GroupDownloader should be deleted.

What it did

The idea with GroupDownloader is that you can create a group of files that belong to content unit and have all the downloads of all the content units happen in parallel.

Why delete it?

asyncio.gather(...) provides the same facility in the standard library: https://docs.python.org/3/library/asyncio-task.html#asyncio.gather

Take your N artifacts for your single content type and wrap them with gather() creating a single co-routine to track them. Then for M content units do the same thing, resulting in M co-routines returned by gather(...). You can schedule these M coroutines which will schedule all downloads conncurrently. Also you can wake up with each of the M coroutines finishing, each representing a completed content unit. This is exactly the same feature set as GroupDownloader.

See it in action

The ArtifactDownloader stage implements the exact alternate pattern described ^ here: https://github.com/pulp/pulp/blob/master/plugin/pulpcore/plugin/stages/artifact_stages.py#L194

Also remove attach_url_to_exception

The attach_url_to_exception decorator only serves the GroupDownloader. It's akward anyway and should also be removed. https://github.com/pulp/pulp/blob/master/plugin/pulpcore/plugin/download/base.py#L29-L55 gather handles exception better than our custom solution did anyway.

Actions #1

Updated by dkliban@redhat.com over 6 years ago

  • Groomed changed from No to Yes
  • Sprint Candidate changed from No to Yes
Actions #2

Updated by daviddavis about 6 years ago

  • Sprint set to Sprint 42
Actions #3

Updated by bmbouter about 6 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to bmbouter

Added by bmbouter about 6 years ago

Revision d9eb035d | View on GitHub

Remove the GroupDownloader

The GroupDownloader is not needed. See the ticket description for more info.

Also the 'attach_url_to_exception' was only here to serve the GroupDownloader so that is also being removed.

https://pulp.plan.io/issues/3923 closes #3923

Added by bmbouter about 6 years ago

Revision d9eb035d | View on GitHub

Remove the GroupDownloader

The GroupDownloader is not needed. See the ticket description for more info.

Also the 'attach_url_to_exception' was only here to serve the GroupDownloader so that is also being removed.

https://pulp.plan.io/issues/3923 closes #3923

Actions #4

Updated by bmbouter about 6 years ago

  • Status changed from ASSIGNED to POST
Actions #5

Updated by bmbouter about 6 years ago

  • Status changed from POST to MODIFIED
  • % Done changed from 0 to 100
Actions #6

Updated by daviddavis over 5 years ago

  • Sprint/Milestone set to 3.0.0
Actions #7

Updated by bmbouter over 5 years ago

  • Tags deleted (Pulp 3)
Actions #8

Updated by bmbouter almost 5 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF