Can someone provide a better explanation for the purgeOutageAlerts Toolbox command? The documentation describes this as: "Purges alert that is generated during outages". How is an outage defined? What gets Purged?
Also needing more explanation are
let me try to explain the options, which were all implemented based on my previous post about columns that don't get cleaned (see Tech Tip: Additional Cleanup in the SOI Database - there you can also see the individual SQL queries).
SOI keeps a record for CIs, if they are in good shape or have a problem - that is done in the CIQuality, CIRisk and CIHealth tables. Every such timeframe is called a period and gets a PeriodID.
The corresponding Alerts are listed in the tables OutageQualityAlerts, OutageRiskAlerts and OutageAlerts, mentioning only the PeriodID and the AlertID.
All this is used mainly by reporting to show Quality, Risk and Health statistics.
When old Alerts are purged, these tables are not cleared, and thus there can be leftovers.
The option PurgeOutageAlerts deletes such orphans, e.g. references to AlertIDs which don't exist anymore.
When removing a Connector, all Alerts are still kept in the DB for reporting purposes.
Normally they get purged during the regular Database Maintenance task of purging old Alerts.
But you might want to delete them immediately (especially on Test-Systems where you "play" with Connectors) to reduce the amount of data in the DB.
Thus, the option cleanAlertsFromRemovedConnectors was added, to let the system search through the Alerts table (including the AlertHistory, AlertImpact, AlertAnnotation tables), to remove Alerts from Connectors where the ConnectorID is no longer present.
Alert Queue Assignment
When you delete Alert Queues, the references still stay in the tables.
The option purgeAlertQueueAssignment does only purge the assignment of an Alert to a specific Alert Queue which does not exist anymore. It does not purge the Alerts.
The AlertQueueAssignment table is recreated on every startup of the SOI Manager.
I hope this helps.
If you have further questions, please let me know.
If a cleared alert is purged from the database via soitoolbox, does it also removes the corrosponding entries in the alert queue assignments? In my opinition this is the main use case for the purgeAlertQueueAssignment command.
I did some tests on my system and can confirm:
The entries in the AlertQueueAssignments tables are removed when making use of the --purgeClearedAlerts option of soitoolbox.