Project

Profile

Help

Refactor #862

closed

Refactor #765: Convert Pulp to use MongoEngine

Add unit association and querying support to the Repository model

Added by bcourt over 9 years ago. Updated over 5 years ago.

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

100%

Estimated time:
Platform Release:
2.8.0
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Pulp 2
Sprint:
May 2015
Quarter:

Description

Add the ability to query units via the Repository model

  • Add method find_units(association_q, unit_q, limit, skip) that returns an iterable. This iterable yields repo_content_units with a 'unit' attribute on each item that is filled in by the find_units iterator(), if limit is unspecified all units will be returned, if skip is unspecified then the first batch will be returned
  • Add method add_unit(model) that creates/updates the repo_content_unit collection entry for the unit
  • Add method add_units(model_iterable) that creates/updates the repo_content_unit collection entry for every model in the iterable.
  • content_unit_counts should be updated automatically whenever units are added or removed from the repository
  • Add a method to remove_unit(unit_model) remove a unit by passing in the unit object.
  • Add a method to remove_units(association_qs, unit_qs) to remove units matching a filter.

Related issues

Blocked by Pulp - Refactor #785: Convert the 'repos' collection to a mongoengine modelCLOSED - CURRENTRELEASEamacdona@redhat.com

Actions
Blocks Docker Support - Refactor #863: Convert pulp_docker to use MongoEngine models for unitsCLOSED - CURRENTRELEASErbarlow

Actions
Actions #1

Updated by bcourt over 9 years ago

  • Blocked by Refactor #785: Convert the 'repos' collection to a mongoengine model added
Actions #2

Updated by bcourt over 9 years ago

  • Blocked by Refactor #863: Convert pulp_docker to use MongoEngine models for units added
Actions #3

Updated by bcourt over 9 years ago

  • Blocked by deleted (Refactor #863: Convert pulp_docker to use MongoEngine models for units)
Actions #4

Updated by bcourt over 9 years ago

  • Blocks Refactor #863: Convert pulp_docker to use MongoEngine models for units added
Actions #5

Updated by bcourt over 9 years ago

  • Priority changed from Normal to High
Actions #6

Updated by bcourt over 9 years ago

  • Sprint Candidate set to Yes
Actions #7

Updated by bmbouter over 9 years ago

  • Groomed set to No
Actions #8

Updated by mhrivnak over 9 years ago

  • Subject changed from Add unit querying support to the Repository model to Add unit association and querying support to the Repository model
Actions #9

Updated by mhrivnak over 9 years ago

  • Groomed changed from No to Yes
Actions #10

Updated by bcourt over 9 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to bcourt
Actions #11

Updated by bcourt over 9 years ago

  • Status changed from ASSIGNED to POST
  • Sprint/Milestone set to 16
  • % Done changed from 0 to 100
Actions #12

Updated by bcourt over 9 years ago

  • Platform Release set to 2.8.0

Added by bcourt over 9 years ago

Revision 60d8aa14 | View on GitHub

Add unit querying & association support required for plugin conversion to mongoengine

fixes #862

Added by bcourt over 9 years ago

Revision 60d8aa14 | View on GitHub

Add unit querying & association support required for plugin conversion to mongoengine

fixes #862

Actions #13

Updated by bcourt over 9 years ago

  • Status changed from POST to MODIFIED

Added by bmbouter over 9 years ago

Revision e0df741c | View on GitHub

Set storage path in ContentUnit.pre_save handler correctly.

The pre-save handler did not save the full path to the file_path set with set_content in the case where file_path is a file.

re #862

Added by bmbouter over 9 years ago

Revision e0df741c | View on GitHub

Set storage path in ContentUnit.pre_save handler correctly.

The pre-save handler did not save the full path to the file_path set with set_content in the case where file_path is a file.

re #862

Actions #14

Updated by dkliban@redhat.com over 8 years ago

  • Status changed from MODIFIED to 5
Actions #15

Updated by dkliban@redhat.com over 8 years ago

  • Status changed from 5 to CLOSED - CURRENTRELEASE
Actions #16

Updated by bmbouter over 6 years ago

  • Sprint set to May 2015
Actions #17

Updated by bmbouter over 6 years ago

  • Sprint/Milestone deleted (16)
Actions #18

Updated by bmbouter over 5 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF