Repository navigation
Commit daa6a68
feat(cli): support custom CDK resource migration in gen2-migration generate (#14863)
* feat: support custom resources
* chore: update snapshots
* chore: update finance tracker snapshot
* chore: update snapshots
* fix(cli-internal): custom resource codegen returns instance and uses Backend type
Update the custom resource generator to:
- Return the construct instance from defineXxx() wrapper functions
- Use Backend type annotation instead of any for the backend parameter
- Rename cdk-stack.ts to construct.ts (not resource.ts)
- Use _prefixed variable name in post-generate to avoid shadowing
- Fix post-generate to look in construct.ts for table name pattern
- Update snapshots and tests to match
* Update custom.generator.ts
---------
Co-authored-by: Eli Polonsky <epolon@amazon.com>1 parent 8c623db commit daa6a68
558 files changed
Lines changed: 68131 additions & 163 deletions
File tree
- .vscode
- amplify-migration-apps
- finance-tracker
- _snapshot.post.generate
- amplify
- auth
- custom
- customfinance
- customresolver
- data
- function/financetracker
- storage
- types
- _snapshot.pre.generate
- amplify
- #current-cloud-backend
- api/financetracker
- build
- resolvers
- stacks
- resolvers
- stacks
- auth/financetracker331811e6
- build
- awscloudformation/build
- api/financetracker/build
- auth/financetracker331811e6/build
- awscloudformation/build
- custom
- customfinance/build
- customresolver/build
- function/financetracker
- storage/s320279658/build
- custom
- customfinance
- build
- customresolver
- build
- function/financetracker
- src
- storage/s320279658
- build
- .config
- backend
- api/financetracker
- build
- resolvers
- stacks
- resolvers
- stacks
- auth/financetracker331811e6
- build
- awscloudformation/build
- api/financetracker/build
- auth/financetracker331811e6/build
- awscloudformation/build
- custom
- customfinance/build
- customresolver/build
- function/financetracker
- storage/s320279658/build
- custom
- customfinance
- build
- customresolver
- build
- function/financetracker
- src
- storage/s320279658
- build
- types
- hooks
- _snapshot.pre.refactor
- backend
- images
- migration
- public
- src
- assets
- graphql
- tests
- fitness-tracker/_snapshot.post.generate
- media-vault/_snapshot.post.generate
- product-catalog/_snapshot.post.generate
- store-locator/_snapshot.post.generate
- packages
- amplify-cli-npm
- amplify-cli/src
- __tests__/commands/gen2-migration
- generate/amplify/custom-resources
- commands/gen2-migration
- _common
- assess/custom
- generate
- amplify/custom-resources
- amplify-e2e-gen2-migration/src/core
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
| 25 | + | |
25 | 26 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
Lines changed: 19 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
0 commit comments