Details
-
Fix
-
Status: Released (View Workflow)
-
Minor
-
Resolution: Fixed
-
1.12
-
None
Description
Current Situation
- The following cleanup script to purge the reporting database is provided with the JobScheduler Master's ./bin directory:
- cleanup_reporting_tables.cmd | .sh
- The script can be parameterized for
- an execution range (all, reporting, dailyplan, yade) and
- the number of days for which the logs and history of tasks and orders should be retained, earlier entries are removed from the database.
- When the cleanup script is parameterized for the execution range all or yade then the script execution ends with an SQL exception (MySQL sample: java.lang.Exception: sos.connection.SOSConnection.execute(1678):Invalid object name 'JADE_FILES') and the cleanup operation will not be performed.
- The script tries to cleanup YADE tables that do not exist any longer in the reporting database.
Desired Behaviour
- The cleanup of the reporting tables should work correctly and delete entries from existing tables only.
Test Instruction
- Test Configuration
- Verify that none of the following tables exist and drop them should they exist:
- JADE_FILES
- JADE_FILES_HISTORY
- JADE_FILES_POSITIONS
- Verify that none of the following tables exist and drop them should they exist:
- Test Execution
- Negative Test
- Running cleanup_reporting_tables script from a 1.12.5 release raises the above mentioned error.
- Positive Test
- Running cleanup_reporting_tables script from a 1.12.5 release does not raise an error.
- Verify from the following tables that no entries exist that are younger (see CREATED column) then the date suggested by the purge:
- REPORTING_TRIGGERS
- REPORTING_EXECUTIONS
- REPORTING_TASKS
- REPORTING_EXECUTION_DATES
- DAILY_PLAN
- YADE_FILES
- YADE_PROTOCOLS
- YADE_TRANSFERS
- Negative Test