pulumi/pkg/resource/custom_timeouts.go
Paul Stack 2c0510a23e
Update the JSON representation of customTimeouts in state (#3101)
Omit them when empty and change the casing of Create, Update and
Delete
2019-08-21 01:01:27 +03:00

12 lines
351 B
Go

package resource
type CustomTimeouts struct {
Create float64 `json:"create,omitempty" yaml:"create,omitempty"`
Update float64 `json:"update,omitempty" yaml:"update,omitempty"`
Delete float64 `json:"delete,omitempty" yaml:"delete,omitempty"`
}
func (c *CustomTimeouts) IsNotEmpty() bool {
return c.Delete != 0 || c.Update != 0 || c.Create != 0
}