mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-25 18:45:20 -06:00
helper/resource: wait 2 seconds between each
This commit is contained in:
parent
5ad8d418f2
commit
fa3e9fab42
@ -36,7 +36,7 @@ type waitResult struct {
|
|||||||
// specified in the configuration using the specified Refresh() func,
|
// specified in the configuration using the specified Refresh() func,
|
||||||
// waiting the number of seconds specified in the timeout configuration.
|
// waiting the number of seconds specified in the timeout configuration.
|
||||||
func (conf *StateChangeConf) WaitForState() (i interface{}, err error) {
|
func (conf *StateChangeConf) WaitForState() (i interface{}, err error) {
|
||||||
log.Printf("Waiting for state to become: %s", conf.Target)
|
log.Printf("[DEBUG] Waiting for state to become: %s", conf.Target)
|
||||||
|
|
||||||
notfoundTick := 0
|
notfoundTick := 0
|
||||||
|
|
||||||
@ -87,10 +87,10 @@ func (conf *StateChangeConf) WaitForState() (i interface{}, err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// Wait between refreshes
|
// Wait between refreshes
|
||||||
time.Sleep(2 * time.Second)
|
time.Sleep(2 * time.Second)
|
||||||
|
}
|
||||||
}()
|
}()
|
||||||
|
|
||||||
select {
|
select {
|
||||||
|
Loading…
Reference in New Issue
Block a user