]> granicus.if.org Git - icinga2/commitdiff
Don't update scheduleddowntime table w/ trigger_time column when only adding a downtime
authorMichael Friedrich <michael.friedrich@netways.de>
Wed, 8 Apr 2015 15:06:53 +0000 (17:06 +0200)
committerGunnar Beutner <gunnar@beutner.name>
Mon, 20 Apr 2015 06:55:59 +0000 (08:55 +0200)
fixes #9014

lib/db_ido/dbevents.cpp

index 4248d0bbffdadc54c8625b536ca3dcc452234938..1c0f59e145e4e9c749a962e6fada9bb6cf63c1ec 100644 (file)
@@ -528,11 +528,8 @@ void DbEvents::AddDowntimeByType(const Checkable::Ptr& checkable, const Downtime
        fields1->Set("duration", downtime->GetDuration());
        fields1->Set("scheduled_start_time", DbValue::FromTimestamp(downtime->GetStartTime()));
        fields1->Set("scheduled_end_time", DbValue::FromTimestamp(downtime->GetEndTime()));
-       fields1->Set("was_started", Empty);
-       fields1->Set("actual_start_time", Empty);
-       fields1->Set("actual_start_time_usec", Empty);
-       fields1->Set("is_in_effect", Empty);
-       fields1->Set("trigger_time", DbValue::FromTimestamp(downtime->GetTriggerTime()));
+       fields1->Set("was_started", 0);
+       fields1->Set("is_in_effect", 0);
        fields1->Set("instance_id", 0); /* DbConnection class fills in real ID */
 
        String node = IcingaApplication::GetInstance()->GetNodeName();