mirror of
https://github.com/Icinga/icingadb.git
synced 2026-05-28 04:35:54 -04:00
Merge pull request #344 from Icinga/feature/downtime-column-comments
Schema: Add description to downtime columns 'triggered_by_id' and 'parent_id'
This commit is contained in:
commit
af61846114
2 changed files with 10 additions and 6 deletions
|
|
@ -573,8 +573,8 @@ CREATE TABLE downtime (
|
|||
id binary(20) NOT NULL COMMENT 'sha1(environment.name + name)',
|
||||
environment_id binary(20) NOT NULL COMMENT 'environment.id',
|
||||
|
||||
triggered_by_id binary(20) DEFAULT NULL COMMENT 'downtime.id',
|
||||
parent_id binary(20) DEFAULT NULL COMMENT 'downtime.id',
|
||||
triggered_by_id binary(20) DEFAULT NULL COMMENT 'The ID of the downtime that triggered this downtime. This is set when creating downtimes on a host or service higher up in the dependency chain using the "child_option" "DowntimeTriggeredChildren" and can also be set manually via the API.',
|
||||
parent_id binary(20) DEFAULT NULL COMMENT 'For service downtimes, the ID of the host downtime that created this downtime by using the "all_services" flag of the schedule-downtime API.',
|
||||
object_type enum('host', 'service') NOT NULL,
|
||||
host_id binary(20) NOT NULL COMMENT 'host.id',
|
||||
service_id binary(20) DEFAULT NULL COMMENT 'service.id',
|
||||
|
|
@ -943,8 +943,8 @@ CREATE TABLE downtime_history (
|
|||
downtime_id binary(20) NOT NULL COMMENT 'downtime.id',
|
||||
environment_id binary(20) NOT NULL COMMENT 'environment.id',
|
||||
endpoint_id binary(20) DEFAULT NULL COMMENT 'endpoint.id',
|
||||
triggered_by_id binary(20) DEFAULT NULL COMMENT 'downtime.id',
|
||||
parent_id binary(20) DEFAULT NULL COMMENT 'downtime.id',
|
||||
triggered_by_id binary(20) DEFAULT NULL COMMENT 'The ID of the downtime that triggered this downtime. This is set when creating downtimes on a host or service higher up in the dependency chain using the "child_option" "DowntimeTriggeredChildren" and can also be set manually via the API.',
|
||||
parent_id binary(20) DEFAULT NULL COMMENT 'For service downtimes, the ID of the host downtime that created this downtime by using the "all_services" flag of the schedule-downtime API.',
|
||||
object_type enum('host', 'service') NOT NULL,
|
||||
host_id binary(20) NOT NULL COMMENT 'host.id',
|
||||
service_id binary(20) DEFAULT NULL COMMENT 'service.id',
|
||||
|
|
|
|||
|
|
@ -16,8 +16,12 @@ UPDATE service_state SET properties_checksum = 0;
|
|||
ALTER TABLE service_state MODIFY COLUMN properties_checksum binary(20) COMMENT 'sha1(all properties)' NOT NULL;
|
||||
ALTER TABLE service_state ADD UNIQUE INDEX idx_service_state_service_id (service_id);
|
||||
|
||||
ALTER TABLE downtime ADD COLUMN parent_id binary(20) AFTER triggered_by_id;
|
||||
ALTER TABLE downtime_history ADD COLUMN parent_id binary(20) AFTER triggered_by_id;
|
||||
ALTER TABLE downtime
|
||||
ADD COLUMN parent_id binary(20) COMMENT 'For service downtimes, the ID of the host downtime that created this downtime by using the "all_services" flag of the schedule-downtime API.' AFTER triggered_by_id,
|
||||
MODIFY COLUMN triggered_by_id binary(20) COMMENT 'The ID of the downtime that triggered this downtime. This is set when creating downtimes on a host or service higher up in the dependency chain using the "child_option" "DowntimeTriggeredChildren" and can also be set manually via the API.';
|
||||
ALTER TABLE downtime_history
|
||||
ADD COLUMN parent_id binary(20) COMMENT 'For service downtimes, the ID of the host downtime that created this downtime by using the "all_services" flag of the schedule-downtime API.' AFTER triggered_by_id,
|
||||
MODIFY COLUMN triggered_by_id binary(20) COMMENT 'The ID of the downtime that triggered this downtime. This is set when creating downtimes on a host or service higher up in the dependency chain using the "child_option" "DowntimeTriggeredChildren" and can also be set manually via the API.';
|
||||
|
||||
ALTER TABLE checkcommand_argument MODIFY COLUMN argument_order smallint DEFAULT NULL;
|
||||
ALTER TABLE eventcommand_argument MODIFY COLUMN argument_order smallint DEFAULT NULL;
|
||||
|
|
|
|||
Loading…
Reference in a new issue