On Thursday 22 of November 2012 16:54:13 Johannes Renner wrote:
> On 11/08/2012 12:18 PM, Johannes Renner wrote:
> > On 11/05/2012 12:03 PM, Tomas Lestach wrote:
> >> ...
> >> If there's a bug in the API call, we of course fix it.
> >> But we try to keep the current API interface as is. Spacewalk users have
> >> their scripts using our API calls and we do not want to break the
> >> scripts by renaming/deleting existing API calls. (Introducing of new
> >> sensefull APIs is always good. :)
> >> 
> >> So, it is important that the API behaves according to its name. It the
> >> name
> >> and behavior do not match, we fix the behavior according to the name and
> >> can introduce a new API in case the behavior of the original API was
> >> helpfull.
> >> 
> >> However, internal naming has lower priority, because the users do not
> >> come
> >> into contact with it, so it cannot be confusing for them. (But we of
> >> course
> >> try to keep the naming sensefull as well.)
> > 
> > Ok, I might come up with a patch these days, fixing the existing API call
> > so it behaves like its name is suggesting + maybe add a new call to
> > provide the previous behavior in addition to that.
> > 
> > Thanks for the explanations,
> > Johannes
> 
> Ok, here we go: The first patch should fix the query for the existing API
> call so that actually only the very latest versions of packages will be
> returned, as the name of the function suggests. (Note that the query might
> have been working for you correctly before, but only in case all of
> packages and updates are provided through one single channel, I guess).
> 
> Further, the query is internally renamed like this (in Package_queries.xml):
> 
> "system_latest_all_available_packages" -> "system_latest_available_packages"
> 
> The second patch adds a new API call to list all versions and releases of
> packages that can be installed to a given system:
> 
> system.list_all_installable_packages(key, sid)
> 
> Unfortunately the previous query could not be reused, since it didn't
> actually return all of the versions and releases of a package (as noted
> above). It rather returned only the max EVR version of each package in
> every channel the system is subscribed to. This might have lead to correct
> behavior for list_latest, but only in case all packages are provided
> through _one_ single channel. So the second patch also contains a new query
> to handle the list_all_... case.
> 
> Regards,
> Johannes

Committed as:
 d3fab0add1a147849b6f2ae20b7d491a636b94fb
 3ea1f31004e53925a6b8b661e86c4c647c1e86c3

Thank you!
-- 
Tomas Lestach
RHN Satellite Engineering, Red Hat

_______________________________________________
Spacewalk-devel mailing list
Spacewalk-devel@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-devel

Reply via email to