File tree 1 file changed +6
-3
lines changed
src/runtime/virtcontainers
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -81,6 +81,10 @@ const (
81
81
// successfully, on a single Host.
82
82
clhAPITimeoutConfidentialGuest = 300
83
83
84
+ // Minimum timout for calling CreateVM followed by BootVM. Executing these two APIs
85
+ // might take longer than the value returned by getClhAPITimeout().
86
+ clhCreateAndBootVMMinimumTimeout = 100
87
+
84
88
// Timeout for hot-plug - hotplug devices can take more time, than usual API calls
85
89
// Use longer time timeout for it.
86
90
clhHotPlugAPITimeout = 5
@@ -772,9 +776,8 @@ func (clh *cloudHypervisor) StartVM(ctx context.Context, timeout int) error {
772
776
}
773
777
774
778
bootvm_timeout := clh .getClhAPITimeout ()
775
- // TODO: review this 10 second minimum timeout value.
776
- if bootvm_timeout < 10 {
777
- bootvm_timeout = 10
779
+ if bootvm_timeout < clhCreateAndBootVMMinimumTimeout {
780
+ bootvm_timeout = clhCreateAndBootVMMinimumTimeout
778
781
}
779
782
780
783
ctx , cancel := context .WithTimeout (context .Background (), bootvm_timeout * time .Second )
You can’t perform that action at this time.
0 commit comments