Description of problem: For Spacewalk 1.2, we have split rhnPackageChangeLog into rhnPackageChangeLogData (the data) and rhnPackageChangeLogRec (the relation table which links the data to individual package). Whe package is deleted, so is record from rhnPackageChangeLogRec. However, the record from rhnPackageChangeLogData does not get deleted because it might be referenced from other packages, and for performance reasons we don't do that lookup right away. We need daily taskomatic task which will do something like delete from rhnPackageChangeLogData where id not in ( select changelog_data_id from rhnPackageChangeLogRec ) There is index on rhnPackageChangeLogRec(changelog_data_id) so it should be pretty fast. Version-Release number of selected component (if applicable): spacewalk-schema-1.2.46-1 How reproducible: Should be easy. Steps to Reproduce: 1. Push or sync a package. 2. Check that there are records in rhnPackageChangeLogRec and rhnPackageChangeLogData. 3. Remove that package. 4. Check that the records from rhnPackageChangeLogRec are gone but records in rhnPackageChangeLogData are still there. 5. Wait a day. Actual results: Records in rhnPackageChangeLogData are still there. Expected results: Orphaned records got purged from rhnPackageChangeLogData. Additional info:
Introducing cleanup-packagechangelog-data task this task is scheduled once a day together with another clean up task and cleans up unreferenced records from the rhnPackageChangeLogData table spacewalk.git: 6c1ee1ef54b4593b406cb111b0b86cc1a3c12949
Moving ON_QA ...
This bug has been fixed in Spacewalk 1.3.