This repository was archived by the owner on Feb 18, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathtimings.go
44 lines (34 loc) · 1.8 KB
/
timings.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
Copyright IBM Corporation 2023.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package controller
import (
"time"
)
// This file defines all the time constants used in mcad
const (
// Timeouts
requeuingTimeout = 2 * time.Minute // minimum wait before aborting Requeuing
dispatchingTimeout = 2 * time.Minute // minimum wait before aborting Dispatching
runningTimeout = 5 * time.Minute // minimum wait before aborting Running
cacheConflictTimeout = 5 * time.Minute // minimum wait before invalidating the cache
clusterCapacityTimeout = time.Minute // how long to cache cluster capacity
// Cluster capacity is only refreshed when trying to dispatch AppWrappers and only after
// the previous measurement has timed out, so it is necessary to call dispatchNext on
// a regular basis (we do) to ensure we detect new capacity (such as new schedulable nodes)
// RequeueAfter delays
runDelay = time.Minute // maximum delay before next reconciliation of a Running AppWrapper
dispatchDelay = time.Minute // maximum delay before next "*/*" reconciliation (dispatchNext)
// The RequeueAfter delay is the maximum delay before the next reconciliation event.
// Reconciliation may be triggered earlier due for instance to pod phase changes.
// Reconciliation may be delayed due to the on-going reconciliation of other events.
)