func (p RetryPolicy) Validate() error {
	if p.Attempts < 1 {
		return errors.Errorf("expected at least one attempt")
	}
	if p.MaxDelay < 1 {
		return errors.Errorf("expected max delay to be a valid time")
	}
	return nil
}
// Validate validates the RetryPolicy for any issues.
Validate validates the RetryPolicy for any issues.
// Validate validates the RetryPolicy for any issues .
func (p RetryPolicy) Validate() error {
	if p.Attempts < 1 {
		return errors.Errorf("expected at least one attempt")
	}
	if p.MaxDelay < 1 {
		return errors.Errorf("expected max delay to be a valid time")
	}
	return nil
}
func ( p RetryPolicy ) Validate ( ) error { if p . Attempts < 1 { return errors . Errorf ( " " ) } if p . MaxDelay < 1 { return errors . Errorf ( " " ) } return nil }
Validate validates the RetryPolicy for any issues.
Validate validates the RetryPolicy for any issues .