You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// getPodsToUpdate returns a map of Zone to Pods mapping. The map has the fault domain as key and all Pods in that fault domain will be present as a slice of *corev1.Pod.
podMissingError=fmt.Errorf("ProcessGroup: %s is missing the associated Pod for %s will be blocking until the Pod is missing for at least 90 seconds", processGroup.ProcessGroupID, missingPodDuration.String())
225
+
}
187
226
188
-
// Check when the Pod went missing. If the condition is unset the current timestamp will be used, in that case
189
-
// the fdbv1beta2.MissingPod duration will be smaller than the 90 seconds buffer. The 90 seconds buffer
190
-
// was chosen as per default the failure detection in FDB takes 60 seconds to detect a failing fdbserver
191
-
// process (or actually to mark it failed). Without this check there could be a race condition where the
192
-
// Pod is already removed, so the process group would be skipped here but the fdbserver process is not yet
193
-
// marked as failed in FDB, which causes FDB to return full replication in the cluster status.
194
-
//
195
-
// With the unified image there is support for delaying the shutdown to reduce this risk even further.
podMissingError=fmt.Errorf("ProcessGroup: %s is missing the associated Pod for %s will be blocking until the Pod is missing for at least 90 seconds", processGroup.ProcessGroupID, missingPodDuration.String())
returnnil, fmt.Errorf("%s was recently created but the process uptime reports old uptime, time since pod was created: %f.2 seconds and process up time: %f.2", pod.Name, timeSincePodCreation.Seconds(), process.UptimeSeconds)
It("should return an error and an empty map", func() {
481
+
Expect(updates).To(HaveLen(0))
482
+
Expect(updateErr).To(MatchError(And(ContainSubstring("was recently created and the processes are not yet running"), ContainSubstring(string(picked.ProcessGroupID)))))
483
+
})
484
+
})
485
+
486
+
When("the process is running but the uptime seconds is greater than the pod uptime ", func() {
487
+
It("should return an error and an empty map", func() {
488
+
Expect(updates).To(HaveLen(0))
489
+
Expect(updateErr).To(MatchError(And(ContainSubstring("was recently created but the process uptime reports old uptime"), ContainSubstring(string(picked.ProcessGroupID)))))
490
+
})
491
+
})
492
+
493
+
When("the process is running and the uptime seconds is less than the pod uptime ", func() {
0 commit comments