-
Notifications
You must be signed in to change notification settings - Fork 286
feat(auth): Add tenant operations, tenant-aware user operations, and provider config operations #395
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
Conversation
This moves parts of FirebaseAuth into an abstract class as part of adding multi-tenancy support.
This pull request adds the Tenant class (including it's create/update inner classes) as part of adding multi-tenancy support.
Add ListTenantsPage and some supporting code as part of adding multi-tenancy support. This code was very largely based off of ListUsersPage and ListUsersPageTest.
Added some things to the Tenant class and added a few unit tests. This is part of the initiative to adding multi-tenancy support (see issue #332).
This adds deleteTenant to the TenantManager class. I've added the relevant unit tests to FirebaseUserManagerTest. This is part of the initiative to adding multi-tenancy support (see issue #332).
Added getTenant to the TenantManager class. Also added the relevant unit tests to FirebaseUserManagerTest. This is part of the initiative to adding multi-tenancy support (see issue #332).
Added createTenant and updateTenant to the TenantManager class. Also added the relevant unit tests to FirebaseUserManagerTest. This is part of the initiative to adding multi-tenancy support (see issue #332).
This adds some integration testing for all of the tenant operations in TenantManager. Several bugs were uncovered after running the tests, so these have been fixed. This is part of the initiative to adding multi-tenancy support (see issue #332).
This addresses some TODOs left as part of the initiative to add multi-tenancy support (see issue #332).
This makes user operations tenant-aware. I've added some integration tests to ensure that this is working correctly. This is part of the initiative to adding multi-tenancy support (see issue #332).
Remove unused AutoValue dependency (and remove Java 8 API dependency which was accidentally introduced).
) This documentation is based off of the instructions in https://github.com/firebase/firebase-admin-node/blob/master/CONTRIBUTING.md.
This incorporates the tenant ID into the token generation and validation when using a tenant-aware client. This is part of the initiative to add multi-tenancy support (see issue #332).
@egilmorez please review the reference docs in following classes:
|
Thanks Hiranya! I'm going to try and pass this one to Kevin, who is the resident expert and owner of auth docs. Kevin, please review: AbstractFirebaseAuth |
src/main/java/com/google/firebase/auth/FirebaseTokenVerifierImpl.java
Outdated
Show resolved
Hide resolved
src/main/java/com/google/firebase/auth/FirebaseUserManager.java
Outdated
Show resolved
Hide resolved
src/main/java/com/google/firebase/auth/FirebaseUserManager.java
Outdated
Show resolved
Hide resolved
src/main/java/com/google/firebase/auth/FirebaseUserManager.java
Outdated
Show resolved
Hide resolved
src/main/java/com/google/firebase/auth/TenantAwareFirebaseAuth.java
Outdated
Show resolved
Hide resolved
src/test/java/com/google/firebase/auth/FirebaseTokenVerifierImplTest.java
Outdated
Show resolved
Hide resolved
Thanks for the review, Kevin! I've made all of the requested changes. |
I've noticed some unit testing gaps in this PR. Following classes have less than ideal unit test coverage:
We should look to get close to 100% in these classes. |
* Bump netty.version from 4.1.34.Final to 4.1.45.Final (#373) Bumps `netty.version` from 4.1.34.Final to 4.1.45.Final. Updates `netty-codec-http` from 4.1.34.Final to 4.1.45.Final - [Release notes](https://github.com/netty/netty/releases) - [Commits](netty/netty@netty-4.1.34.Final...netty-4.1.45.Final) Updates `netty-handler` from 4.1.34.Final to 4.1.45.Final - [Release notes](https://github.com/netty/netty/releases) - [Commits](netty/netty@netty-4.1.34.Final...netty-4.1.45.Final) Updates `netty-transport` from 4.1.34.Final to 4.1.45.Final - [Release notes](https://github.com/netty/netty/releases) - [Commits](netty/netty@netty-4.1.34.Final...netty-4.1.45.Final) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(auth): Add bulk get/delete methods (#365) This PR allows callers to retrieve a list of users by unique identifier (uid, email, phone, federated provider uid) as well as to delete a list of users. RELEASE NOTE: Added getUsers() and deleteUsers() APIs for retrieving and deleting user accounts in bulk. * chore: Setting the version of the Maven Javadoc plugin (#412) * [chore] Release 6.13.0 (#413) * [chore] Release 6.13.0 take 2 (#414) * Upgated the gpg keys * Added temp verify script * Disabled tty for gpg import * Removing temp verification script * Updated publish commands * [chore] Release 6.13.0 take 3 (#415) * [chore] Release 6.13.0 take 4 (#416) Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: rsgowman <rich@gowman.noip.me>
We found a Contributor License Agreement for you (the sender of this pull request), but were unable to determine that you authored the commits in this PR. Maybe you used a different email address in the git commits than was used to sign the CLA? If someone else authored these commits, then please add them to this pull request and have them confirm that they're okay with them being contributed to Google. If there are co-authors, make sure they're formatted properly. In order to pass this check, please resolve this problem and then comment ℹ️ Googlers: Go here for more info. |
@micahstairs are we expecting more changes on this branch? If not I can go ahead and merge it. |
We just spoke and decided that I are going to finish the work on the |
Adds all of the OIDC and SAML provider config operations, related to adding multi-tenancy support.
* Multi-tenancy refactor experiment * fix(auth): Completed tenant mgt refactor * Added license header to new class * Responding to code review comments: Consolidated error codes in AuthHttpClient
I've improved the unit test coverage of tenant/provider-related code, and I've also removed a number of unused imports.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Code reviewed in steps in other PRs
This adds multi-tenancy support to the Firebase client, as well as support for SAML/OIDC provider config operations. See issue #332.