Bug 679835 - Drop version-release from task rpm names received from Scheduler
Summary: Drop version-release from task rpm names received from Scheduler
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Beaker
Classification: Retired
Component: scheduler
Version: 0.7
Hardware: Unspecified
OS: Unspecified
medium
medium vote
Target Milestone: ---
Assignee: Bill Peck
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-02-23 16:35 UTC by Marian Csontos
Modified: 2019-05-22 13:38 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-03-10 05:21:25 UTC


Attachments (Terms of Use)

Description Marian Csontos 2011-02-23 16:35:20 UTC
To prevent from discrepancies between what's in the recipe and what's in the repository used to install tasks.

Comment 1 Marian Csontos 2011-02-28 10:59:57 UTC
I thought it would be easy to query rpm what's its name. But I do not have the rpm at the time I want to query it.

Bill, would not this be better handled by scheduler?
- It is scheduler sending out the data in form which is not safe to use
- Scheduler has access to the RPMs and could query them (I have heard claims it is likely to get N-V-R parsing wrong especially with regard top Epoch. However epoch is not used by our tests.)

This will still not catch the name changes due to the repo-prefix part not constant. Fortunately this does happen rarely enough to ignore.

Here my naive attempt to handle on harness side. Not that difficult but not sure if correct:

Let's get rid of epoch first:

  s/^\d\+://
  s/-\(\d\+\):/-/
  s/:\d\+//

Let's remove -V-R part of N-V-R:

  s/-[0-9.]\+-[^-]\+$//

Testing:

  for each rpm-package in rpms repo (e.g. `bkr task-list`):
  - get the N-V-R
  - get the N part
  - query the package by N (e.g. `yum info`)
  - if it can not be queried:
    - the parsing is wrong

Comment 2 Bill Peck 2011-02-28 15:02:15 UTC
I agree the server should provide the correct name for you. 

Currently the node looks like this:

<rpm name="rh-tests-distribution-install-ext4-lvm-1.0-2.noarch.rpm" path="/mnt/tests/distribution/install/ext4-lvm"/>

Should I just drop the VR.rpm part?

<rpm name="rh-tests-distribution-install-ext4-lvm" path="/mnt/tests/distribution/install/ext4-lvm"/>

Comment 3 Marian Csontos 2011-02-28 15:18:49 UTC
(In reply to comment #2)

> Should I just drop the VR.rpm part?

Yes, please. Getting the name part only would be fine.

Comment 4 Bill Peck 2011-03-03 02:18:31 UTC
pushed to gerrit for review


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