Skip to content
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

Rate limiting #14

Merged
merged 2 commits into from
Aug 13, 2020
Merged

Rate limiting #14

merged 2 commits into from
Aug 13, 2020

Conversation

incompl
Copy link
Member

@incompl incompl commented Aug 6, 2020

Feature

Screenshots

Not much to look at!

Test Plan (Steps to test):

  1. Create a project with the Shape Portfolio template. Create an API key and save it for later.
  2. Clone takeshape-samples if you don't already have it locally
  3. Navigate to the shape-portfolio-gatsbyjs folder
  4. Install the prerelease that was published from this branch npm install gatsby-source-takeshape@0.0.3-1
  5. Edit gatsby-config.js
    1. Under plugins, change gatsby-source-graphql to gatsby-source-takeshape
    2. Remove all the existing plugin options
    3. Add apiKey and projectId options with the API key and project ID that you created earlier.
  6. npm run start
  7. Navigate to http://localhost:8000/ (or wherever it says you can view your site) and make sure it looks right
  8. Test it again with a huge site
    1. In your gatsby-source-takeshape config, set refetchInterval to 0 to make this simpler
    2. In src/pages, make 1000 copies of index.html
    3. npm run start again
    4. Verify that although it takes much longer, it'll still build
    5. Test the site built correctly at a few of the random pages you made, eg http://localhost:8000/index%20copy%20300
  9. Review the README and try all the options to make sure none of them break

Checklist:

@incompl incompl force-pushed the ratelimiting branch 2 times, most recently from 803af61 to 93cdafc Compare August 10, 2020 22:10
@incompl incompl marked this pull request as ready for review August 10, 2020 22:10
@incompl incompl linked an issue Aug 11, 2020 that may be closed by this pull request
2 tasks
@mcat mcat requested a review from mshick August 11, 2020 15:50
@mshick
Copy link
Member

mshick commented Aug 12, 2020

looks good!

@incompl incompl merged commit 3d7b71c into trunk Aug 13, 2020
@incompl incompl deleted the ratelimiting branch August 13, 2020 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Requests to GraphQL API Should Follow rate limit headers
2 participants