---
title: "Discussion on \"How to Use cron Jobs to Schedule Your Lambda Functions with AWS CDK\" | Hashnode"
description: "Discussion on \"How to Use cron Jobs to Schedule Your Lambda Functions with AWS CDK\". When building projects with AWS, there will come a time when you need to run things on a consistent and regular basis. A common example of this would be running a Lambda function once per day to perform some checks against a database. But, how do we ..."
url: "https://hashnode.com/posts/how-to-use-cron-jobs-to-schedule-your-lambda-functions-with-aws-cdk/6439b6693522871750d783d3"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [How to Use cron Jobs to Schedule Your Lambda Functions with AWS CDK](https://conermurphy.hashnode.dev/how-to-use-cron-jobs-to-schedule-your-lambda-functions-with-aws-cdk?utm_source=hashnode&utm_medium=feed)

When building projects with AWS, there will come a time when you need to run things on a consistent and regular basis. A common example of this would be running a Lambda function once per day to perform some checks against a database. But, how do we ...

Apr 14, 2023 · 5 min read · conermurphy.hashnode.dev  
Read the article

-   [#aws](https://hashnode.com/tag/aws)
-   [#aws-cdk](https://hashnode.com/tag/aws-cdk)
-   [#typescript](https://hashnode.com/tag/typescript)
-   [#aws-lambda](https://hashnode.com/tag/aws-lambda)

## Written by

[Coner Murphy](https://hashnode.com/@conermurphy)

@conermurphy · Norwich, UK

  
[View profile](https://hashnode.com/@conermurphy)

Web Developer, Content Creator & Tech Entrepreneur

Fullstack Developer | Technical Writer | Freelancer 👩‍💻 Posts about Web Dev, Tech, and Entrepreneurship 📈

## Responses 1

Markdown supported · ⌘↵ to post

[Rakesh](https://hashnode.com/@awsmantra)

[Apr 17, 2023](https://hashnode.com/posts/how-to-use-cron-jobs-to-schedule-your-lambda-functions-with-aws-cdk/6439b6693522871750d783d3/comment/643cb750da81bbd26819885a)

did you tried to use EventBridge scheduler for job ? It's more flexible

[Coner Murphy](https://hashnode.com/@conermurphy)

[Apr 17, 2023](https://hashnode.com/posts/how-to-use-cron-jobs-to-schedule-your-lambda-functions-with-aws-cdk/6439b6693522871750d783d3/comment/643cb750da81bbd26819885a#reply-643ce7d2f6c4d2d2989950e6)

I have done it previously with the EventBridge Scheduler and am planning on writing a separate blog post on using the scheduler for some more advanced use cases.

However, for something like scheduling a Lambda to run once per day at the same time or a recurring timeframe, I felt EventBridge Rules was a better fit because it's simpler to implement and also there are some restraints on the Scheduler still I believe:

1.  It's not fully implemented in the CDK so you'd need to use the SDK inside a Lambda function adding to the complexity
2.  It's only available in a small subset of regions where Rules are available in every region I believe.

Saying this I am still planning on doing a Scheduler post in the future, so keep an eye out for that. 😃

[Rakesh](https://hashnode.com/@awsmantra)

[Apr 17, 2023](https://hashnode.com/posts/how-to-use-cron-jobs-to-schedule-your-lambda-functions-with-aws-cdk/6439b6693522871750d783d3/comment/643cb750da81bbd26819885a#reply-643d50ff2fbf48da589e7194)

[Coner Murphy](https://hashnode.com/@conermurphy) Cool, thanks for your reply. check it out this blog post for EventBridge scheduler and CDK. I am not sure any specific constraint but this post may help you..

[awsmantra.com/eventbridge-schedule-to-step-functi…](https://awsmantra.com/eventbridge-schedule-to-step-functions-no-codeno-lambda)
