[katello-devel] Using id from Katello instead of from CP for identifying product

Ivan Nečas inecas at redhat.com
Fri Feb 3 09:40:30 UTC 2012


On 02/02/2012 03:15 PM, Devan Goodwin wrote:
> While this isn't used today it is a possible call we would need to use
> in the future. If that situation were to arise, subscription-manager
> would only know the CP/RH product ID, and I assume it would hit the
> fallback call you mention: GET
> /organizations/organization_id/products?cp_id=69
>
> Hosted would then need to implement this path so subscription-manager
> can talk to it as well. Is organization_id here what we refer to as
> the owner 'key'?
>
> I am a little nervous about having Candlepin and Katello expose the
> same API call but using a totally different ID, but it might be ok if
> we can sort out what would happen if subscription-manager did need to
> use it.
>
> Cheers,
>
> Devan
This is good point. The problem is we expose there the same API, but 
Katello products are not identical to CP's :/ It's definitely not a good 
idea to have the same API call with different ids. Maybe it would help 
slightly renaming katello /products resource (org_products maybe), but I 
don't like this idea very much.

This argument is convincing me, that moving to 
/organizations/:org_id/products/:cp_id is clearer way to handle this. If 
rhsm needed /products path in the future, we can determine the org id 
from the consumer/provided argument.

-- Ivan




More information about the katello-devel mailing list