Bug 765849 - RFE: Include repo ids in errata & package objects
Summary: RFE: Include repo ids in errata & package objects
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Pulp
Classification: Retired
Component: user-experience
Version: 1.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Pradeep Kilambi
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-12-09 14:54 UTC by Justin Sherrill
Modified: 2013-09-09 16:38 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description Justin Sherrill 2011-12-09 14:54:41 UTC
Description of problem:

When requesting packages from pulp's api the list of repos the package is in is included in the package json object returned.  For errata this is not the case.  By adding it, it would help us do searching much more easily.


Package example:

{
 "epoch"=>"0", 
 "name"=>"spacewalk-admin", 
 "arch"=>"noarch", 
 "_id"=>"7a236dfe-907c-4825-bac2-ea63dd9b10a2", 
 "repos"=>["ACME_Corporation-TestProduct-Spacewalk"], 
 "id"=>"7a236dfe-907c-4825-bac2-ea63dd9b10a2", 
 "checksum"=>{"sha"=>"47330723658eb7c440ec444436e64bf6da67fd02"},  
 "version"=>"1.4.2", 
 "filename"=>"spacewalk-admin-1.4.2-1.el6.noarch.rpm", "release"=>"1.el6"}


Errata example:
{"title"=>"Empty errata", "_id"=>"RHEA-2010:0001", "id"=>"RHEA-2010:0001", "type"=>"security", "severity"=>""}

Ideally the errata would be something like:
{"title"=>"Empty errata", "_id"=>"RHEA-2010:0001", "id"=>"RHEA-2010:0001", "type"=>"security", "severity"=>"",  "repos"=> ["repo1", "repo2"]}

Comment 1 Justin Sherrill 2011-12-09 20:18:25 UTC
Actually,  even Packages don't have the repos  entry unless we're searching.  Could we make sure that we get the "repos"   for packages and errata no matter how we're finding them?


I.e.  it shouldn't matter if its via:

- All Packages(/packages/)
- Repository Packages (/repositories/<id>/packages/ )

- All Errata 
- Repository Errata (/repositories/<id>/errata/)


Although for us, Repository Package & repository Errata are most important.

Thanks

Comment 3 Jeff Ortel 2012-01-04 21:48:46 UTC
build: 0.256

Comment 4 Preethi Thomas 2012-01-05 15:15:00 UTC
[][root@preethi ~]# rpm -q pulp
pulp-0.0.256-1.fc15.noarch
[root@preethi ~]# 


[root@preethi ~]# curl -k -u admin:admin -X GET https://localhost/pulp/api/repositories/f15/packages/ |json_reformat |more
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0[
  {
    "license": "GPLv2",
    "vendor": "Fedora Project",
    "name": "git",
    "repo_defined": true,
    "checksum": {
      "sha256": "bab42afa6adbc564421d8004c824ec64478dffdd6a7e9c96441648bd5b08151
e"
    },
    "description": "Git is a fast, scalable, distributed revision control system
 with an\nunusually rich command set that provides both high-level operations\na
nd full access to internals.\n\nThe git rpm installs the core tools with minimal
 dependencies.  To\ninstall all git packages, including tools for integrating wi
th other\nSCMs, install the git-all meta-package.",
    "filename": "git-1.7.5.1-1.fc15.x86_64.rpm",
    "download_url": "https://preethi.usersys.redhat.com//pulp/repos/released/F-1
5/GOLD/Fedora/x86_64/os/git-1.7.5.1-1.fc15.x86_64.rpm",
    "buildhost": "x86-17.phx2.fedoraproject.org",
    "repoids": [
      "f15",
      "abc"
    ],
    "epoch": "0",
    "version": "1.7.5.1",
--More--



[root@preethi ~]# curl -k -u admin:admin -X GET https://localhost/pulp/api/repositories/f15/errata/
[][root@preethi ~]#

Comment 5 Preethi Thomas 2012-02-24 20:19:03 UTC
Pulp v1.0 is released
Closed Current Release.

Comment 6 Preethi Thomas 2012-02-24 20:19:46 UTC
Pulp v1.0 is released.


Note You need to log in before you can comment on or make changes to this bug.