Skip to content

Latest commit

 

History

History
45 lines (25 loc) · 1.98 KB

Module8.md

File metadata and controls

45 lines (25 loc) · 1.98 KB

Module 8: Submit AWS Batch job with automated retries

As you may have noticed in the last module, occasionally, your batch job might fail. In this module, we take advantage of the Automated job retry feature of AWS Batch to make our batch job more resilient

Instructions

  1. Create a new job by clicking on Submit job in the AWS Batch console under the Jobs tab

  2. For Job run-time:

    • Job name: use job-with-retry
    • Job definition: pick the definition you created in last module (e.g. "-monte-carlo-job")
    • Job queue: the job queue you created in last module (e.g. "-queue")
  3. For environment

    • Pick Array job type again
    • For Array size, use 4 this time to add more load
  4. To use automated retries, all you need to do is specify number of retres in the Job attempts field.

    • Use 3 for Job attempts
    • To change things up a bit, use a different stock ticker, e.g. AAPL for this simulation run
    • Up the number of iterations per run to 4000
  5. Click Submit job

  6. Watch the jobs transition between job states

  7. Look at the job details, you may notice your jobs get multiple retries if it encountered the download failure!

Next step

You have successfully built an batch job in a Docker container that can elastically scale to your needs and automatically retries upon failures!

There are a lot more things you can do, and head to the extra credit section for some ideas!

Or if you are done, go to clean up section to clean up the environment.