]> granicus.if.org Git - icinga2/commitdiff
Ensure that the legacy_id attribute for comment/downtime objects is restored on restart
authorMichael Friedrich <michael.friedrich@netways.de>
Wed, 23 Mar 2016 13:03:44 +0000 (14:03 +0100)
committerGunnar Beutner <gunnar.beutner@netways.de>
Wed, 20 Apr 2016 08:07:22 +0000 (10:07 +0200)
This has been changed when moving comments/downtimes to config objects
in 050c520b2a3df0477f2eec71ec2d874b6dd36aa5

It may cause trouble with DB IDO DELETE and UPDATE statements
depending on the old value.

refs #11382

lib/icinga/comment.ti
lib/icinga/downtime.ti

index 8e76a8b3de3ae2a072fe13eead2e8cdccdc4c19a..8ac497aac2dea2a721da0fa4cf45151208746f49 100644 (file)
@@ -88,7 +88,7 @@ class Comment : ConfigObject < CommentNameComposer
        [config, required] String author;
        [config, required] String text;
        [config] double expire_time;
-       int legacy_id;
+       [state] int legacy_id;
 };
 
 }
index 774cc1d26d0e17be881bc6e19d422dd5b92d7fca..d5a16988aafb2e005453dfef632ab4134013524b 100644 (file)
@@ -81,7 +81,7 @@ class Downtime : ConfigObject < DowntimeNameComposer
        [state] Array::Ptr triggers {
                default {{{ return new Array(); }}}
        };
-       int legacy_id;
+       [state] int legacy_id;
        [state] bool was_cancelled;
        [config] String config_owner;
 };