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

paginate api gateway resources to support more routes #357

Merged
merged 1 commit into from Aug 25, 2019

Conversation

@tongueroo
Copy link
Owner

commented Aug 25, 2019

This is a πŸ™‹β€β™‚οΈ feature or enhancement.
This is a 🧐 documentation change.

  • I've added tests (if it's a bug, feature or enhancement)
  • I've adjusted the documentation (if it's a feature or enhancement)
  • The test suite passes (run bundle exec rspec to verify this)

Summary

This allows apps to have more than 60 routes if needed.

  • Also, update route change detection to account for pagination.

Context

https://community.rubyonjets.com/t/cloudformation-outputs-limits-60/246/3

Testing Notes

Tested by creating several scaffolds:

for i in animal bottle box card car computer cup phone photo picture post shirt tag tape toy truck user ; do
  jets g scaffold $i title:string
done

Routes files looks something like this:

Jets.application.routes.draw do
  resources :animals
  resources :bottles
  resources :boxes
  resources :cards
  resources :cars
  resources :computers
  resources :cups
  resources :phones
  resources :photos
  resources :pictures
  resources :posts
  resources :shirts
  resources :tags
  resources :tapes
  resources :toys
  resources :trucks
  resources :users
  root "jets/public#show"
  any "*catchall", to: "jets/public#show"
end

This created over 100 routes:

$ bundle exec jets routes | wc -l
159
$

Over 100 functions:

lambda-functions-lots

API Gateway Resources:

api-gateway-lots

It deploys successfully.

paginate api gateway resources to support more routes
* update route change detection to account for pagination

@tongueroo tongueroo force-pushed the resources-page branch from 59b0be4 to aa13959 Aug 25, 2019

@tongueroo tongueroo merged commit 5d772ce into master Aug 25, 2019

1 check passed

ci/circleci Your tests passed on CircleCI!
Details

@tongueroo tongueroo deleted the resources-page branch Aug 25, 2019

@tongueroo

This comment has been minimized.

Copy link
Owner Author

commented Aug 25, 2019

Released in v2.1.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.