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

feat(cognito): user pool resource server #11118

Merged
merged 14 commits into from
Nov 9, 2020
Merged

feat(cognito): user pool resource server #11118

merged 14 commits into from
Nov 9, 2020

Conversation

iRoachie
Copy link
Contributor

@iRoachie iRoachie commented Oct 26, 2020

Also allow adding resource server via userPool.addResourceServer


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

Also allow adding resource server via userPool.addResourceServer
@gitpod-io
Copy link

gitpod-io bot commented Oct 26, 2020

@SomayaB SomayaB changed the title feat(aws-cognito): Add L2 for UserPoolResourceServer feat(cognito): Add L2 for UserPoolResourceServer Oct 26, 2020
@iRoachie
Copy link
Contributor Author

@nija-at All good here?

Copy link
Contributor

@nija-at nija-at left a comment

Choose a reason for hiding this comment

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

Some comments below.

iRoachie and others added 3 commits October 29, 2020 10:34
Co-authored-by: Niranjan Jayakar <nija@amazon.com>
Co-authored-by: Niranjan Jayakar <nija@amazon.com>
@mergify mergify bot dismissed nija-at’s stale review October 29, 2020 14:35

Pull request has been modified.

@iRoachie
Copy link
Contributor Author

@nija-at Updated. Need your feedback on the dependency pattern though. When pairing with an app client, the resource server and its scopes need to be created first before the client can reference it. I realized this when I was doing the integ test that sometimes the client will be created before the resource server, which will result in the stack failing since the scope can't be found.

We need to create a dependency to ensure it happens in the right order. I did

client.node.addDependency(resourceServer);
.

Is this the best way or should we do this internally in UserPoolClient, and accept a resourceServers prop?

packages/@aws-cdk/aws-cognito/README.md Outdated Show resolved Hide resolved
@nija-at nija-at changed the title feat(cognito): Add L2 for UserPoolResourceServer feat(cognito): user pool resource server Oct 30, 2020
iRoachie and others added 2 commits October 30, 2020 11:48
Co-authored-by: Niranjan Jayakar <nija@amazon.com>
…rver.ts

Co-authored-by: Niranjan Jayakar <nija@amazon.com>
@mergify mergify bot dismissed nija-at’s stale review October 30, 2020 15:49

Pull request has been modified.

@iRoachie
Copy link
Contributor Author

iRoachie commented Nov 8, 2020

@nija-at Suggested changes made.

@iRoachie iRoachie requested a review from nija-at November 8, 2020 05:14
@nija-at
Copy link
Contributor

nija-at commented Nov 9, 2020

Hey @iRoachie - I made a small adjustment to the API in this PR - 2715726#diff-c27648629074407952dc3ab03cdf2ec0193f1eb61372913b8c92265051cc553a.

Let me know if you think if it's better.

@iRoachie
Copy link
Contributor Author

iRoachie commented Nov 9, 2020

@nija-at Definitely better. Removes the possibility for misspelling scope name between server and client 👍

@mergify
Copy link
Contributor

mergify bot commented Nov 9, 2020

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-qxepHUsryhcu
  • Commit ID: 06039bf
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify
Copy link
Contributor

mergify bot commented Nov 9, 2020

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit 474f6c6 into aws:master Nov 9, 2020
@iRoachie iRoachie deleted the cognito-resource-server branch November 9, 2020 17:29
@iRoachie
Copy link
Contributor Author

iRoachie commented Nov 9, 2020

Thanks again for your patience @nija-at 🥇

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.

3 participants