Skip to content

[D1] Update e-commerce tutorial #21589

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 13, 2025
Merged

[D1] Update e-commerce tutorial #21589

merged 3 commits into from
May 13, 2025

Conversation

harshil1712
Copy link
Contributor

Summary

Adds retry logic to the tutorial

Copy link
Contributor

hyperlint-ai bot commented Apr 10, 2025

Howdy and thanks for contributing to our repo. The Cloudflare team reviews new, external PRs within two (2) weeks. If it's been two weeks or longer without any movement, please tag the PR Assignees in a comment.

We review internal PRs within 1 week. If it's something urgent or has been sitting without a comment, start a thread in the Developer Docs space internally.


PR Change Summary

Enhanced the e-commerce tutorial by adding retry logic to improve resilience in API calls.

  • Introduced retry logic for API routes to handle transient errors.
  • Updated the tutorial to include steps for connecting to the D1 database.
  • Modified existing API routes to utilize the new retry functionality.

Modified Files

  • src/content/docs/d1/tutorials/using-read-replication-for-e-com/index.mdx

How can I customize these reviews?

Check out the Hyperlint AI Reviewer docs for more information on how to customize the review.

If you just want to ignore it on this PR, you can add the hyperlint-ignore label to the PR. Future changes won't trigger a Hyperlint review.

Note specifically for link checks, we only check the first 30 links in a file and we cache the results for several hours (for instance, if you just added a page, you might experience this). Our recommendation is to add hyperlint-ignore to the PR to ignore the link check for this PR.

@github-actions github-actions bot added the product:d1 D1: https://developers.cloudflare.com/d1/ label Apr 10, 2025
@github-actions github-actions bot added size/xl and removed size/m labels May 13, 2025
Copy link
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
/src/content/docs/d1/ @elithrar, @rozenmd, @vy-ton, @joshthoward, @oxyjun, @harshil1712, @cloudflare/pcx-technical-writing

@@ -474,17 +475,18 @@ Create a new D1 database by running the following command:

```sh
npx wrangler d1 create fast-commerce
```
````
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what does 4 closing backticks do?

(here and above)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, could have been the auto formatting on save, messing this up. Nice catch!

Copy link

@alsuren alsuren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this looks okay as long as it still renders okay and you've checked that it works.

I will let you figure out your formatting issues and check it yourself.

(I wonder if we should have formatting checked in CI to avoid having people's autoformatters fighting with each other? Not a thing for right now though)

@harshil1712 harshil1712 merged commit 14b43bd into production May 13, 2025
12 checks passed
@harshil1712 harshil1712 deleted the d1-ecom-update branch May 13, 2025 13:02
daisyfaithauma pushed a commit that referenced this pull request May 13, 2025
* add retry logic to e-commerce tutorial

* code update

* add retry caution
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
product:d1 D1: https://developers.cloudflare.com/d1/ size/xl
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants