Project

Profile

Help

Story #5402

As a developer, Package content allows ORDER_BY in postgres based on EVR comparisons

Added by ggainey 3 months ago. Updated 3 months ago.

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

0%

Platform Release:
Blocks Release:
Backwards Incompatible:
No
Groomed:
No
Sprint Candidate:
No
Tags:
QA Contact:
Complexity:
Smash Test:
Verified:
No
Verification Required:
No
Sprint:

Description

In order to be able to do things like ORDER BY (EVR) in postgres on the Package content unit, we need to have a type and a comparison method available. Some examples of this include:

Debian: Spacewalk: VMaaS:

We should probably adopt one of the existing methods for the Package model.

History

#1 Updated by bmbouter 3 months ago

  • Subject changed from As Pulp3, I need to be able to do ORDER_BY in postgres based on EVR comparisons to As a developer, Package content allows ORDER_BY in postgres based on EVR comparisons
  • Description updated (diff)

Is the idea that there will be a field on the model and a DB trigger would populate it?

#2 Updated by ggainey 3 months ago

bmbouter wrote:

Is the idea that there will be a field on the model and a DB trigger would populate it?

Depends on the exact approach - VMaaS, for example, creates the evr_t array and inserts it directly:

https://github.com/RedHatInsights/vmaas/blob/master/reposcan/database/package_store.py#L45

#3 Updated by bmbouter 3 months ago

ggainey wrote:

bmbouter wrote:

Is the idea that there will be a field on the model and a DB trigger would populate it?

Depends on the exact approach - VMaaS, for example, creates the evr_t array and inserts it directly:

https://github.com/RedHatInsights/vmaas/blob/master/reposcan/database/package_store.py#L45

I see thank you. So we could do it either way.

Please register to edit this issue

Also available in: Atom PDF