| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- // THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
- package emr
- import (
- "github.com/aws/aws-sdk-go/private/waiter"
- )
- func (c *EMR) WaitUntilClusterRunning(input *DescribeClusterInput) error {
- waiterCfg := waiter.Config{
- Operation: "DescribeCluster",
- Delay: 30,
- MaxAttempts: 60,
- Acceptors: []waiter.WaitAcceptor{
- {
- State: "success",
- Matcher: "path",
- Argument: "Cluster.Status.State",
- Expected: "RUNNING",
- },
- {
- State: "success",
- Matcher: "path",
- Argument: "Cluster.Status.State",
- Expected: "WAITING",
- },
- {
- State: "failure",
- Matcher: "path",
- Argument: "Cluster.Status.State",
- Expected: "TERMINATING",
- },
- {
- State: "failure",
- Matcher: "path",
- Argument: "Cluster.Status.State",
- Expected: "TERMINATED",
- },
- {
- State: "failure",
- Matcher: "path",
- Argument: "Cluster.Status.State",
- Expected: "TERMINATED_WITH_ERRORS",
- },
- },
- }
- w := waiter.Waiter{
- Client: c,
- Input: input,
- Config: waiterCfg,
- }
- return w.Wait()
- }
- func (c *EMR) WaitUntilStepComplete(input *DescribeStepInput) error {
- waiterCfg := waiter.Config{
- Operation: "DescribeStep",
- Delay: 30,
- MaxAttempts: 60,
- Acceptors: []waiter.WaitAcceptor{
- {
- State: "success",
- Matcher: "path",
- Argument: "Step.Status.State",
- Expected: "COMPLETED",
- },
- {
- State: "failure",
- Matcher: "path",
- Argument: "Step.Status.State",
- Expected: "FAILED",
- },
- {
- State: "failure",
- Matcher: "path",
- Argument: "Step.Status.State",
- Expected: "CANCELLED",
- },
- },
- }
- w := waiter.Waiter{
- Client: c,
- Input: input,
- Config: waiterCfg,
- }
- return w.Wait()
- }
|