Description of problem: API call packages.listFiles() would not return package objects which have (by definition) no checksum (directories, symbolic links). Version-Release number of selected component (if applicable): spacewalk-java-1.2.39-29 / stock Satellite 5.4 How reproducible: Always Steps to Reproduce: 1. Satellite 5.4, some content imported 2. Find a package id of a package which is known to contain directory in its file list 3. Use following script to see whether or not are the package directories contained in the file list returned by packages.listFiles(): ... #!/usr/bin/perl use strict; use warnings; use Frontier::Client; use Data::Dumper; my $HOST = 'satellite.domain.com'; my $user = 'user'; my $pass = 'password'; my $pid = 0; my $client = new Frontier::Client(url => "https://$HOST/rpc/api"); my $session = $client->call('auth.login',$user, $pass); my $pkglist = $client->call('packages.list_files', $session, $pid); print Dumper($pkglist); $client->call('auth.logout', $session); ... Actual results: packages.listFiles() does not return package objects without checksums. Expected results: packages.listFiles() will return package objects without checksums. Additional info: From com/redhat/rhn/common/db/datasource/xml/Package_queries.xml: <mode name="package_files"> <query params="pid"> SELECT C.name, F.file_size, CS.checksum, CS.checksum_type checksumtype, F.file_mode, F.linkto, TO_CHAR(F.mtime, 'YYYY-MM-DD HH24:MI:SS') AS MTIME FROM rhnPackageFile F, rhnPackageCapability C, rhnChecksumView CS WHERE F.package_id = :pid AND F.capability_id = C.id AND F.checksum_id = CS.id ORDER BY UPPER(C.name) </query> </mode> Use of the inner join in the above statement is incorrect.
spacewalk.git master: 2ae1c1a73d332736e652cb9e2927d3d35aaa6f92
Changing to VERIFIED: Testing procedure: Automated script. Verified against: spacewalk-java-1.2.39-33.el5sat
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2010-0991.html
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: The API call packages.listFiles() did not list package objects which have by definition no checksums (directories, symbolic links). This update ensures all package objects are returned, including those without checksums.