Skip to content

Add in-memory implementation for OAuth2AuthorizationService #71

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

krisztian-toth
Copy link
Contributor

@krisztian-toth krisztian-toth commented Apr 26, 2020

Fixes gh-43

Haven't provided unit tests yet, I am unsure about a few things, see comments.

@krisztian-toth krisztian-toth marked this pull request as ready for review April 27, 2020 10:02
@krisztian-toth krisztian-toth force-pushed the implement-in-memory-authorization-service branch from fea0565 to 34c895d Compare April 27, 2020 10:08
Copy link
Collaborator

@jgrandja jgrandja left a comment

Choose a reason for hiding this comment

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

Thanks for the PR @watsta. Please see my review comments.

@jgrandja jgrandja self-assigned this Apr 28, 2020
@jgrandja jgrandja added the type: enhancement A general enhancement label Apr 28, 2020
@krisztian-toth
Copy link
Contributor Author

krisztian-toth commented Apr 30, 2020

@jgrandja I updated the PR, let me know if it's headed in the right direction. Thanks!

@krisztian-toth
Copy link
Contributor Author

@jgrandja I updated the PR, let me know of any shortcomings.

Copy link
Collaborator

@jgrandja jgrandja left a comment

Choose a reason for hiding this comment

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

Thanks for the updates @watsta. Please see the additional review comments.

Also, before you push the next updates, can you please rebase on master and then force push. We use the git rebase workflow instead of merging.

* Creates an {@link InMemoryOAuth2AuthorizationService}.
*/
public InMemoryOAuth2AuthorizationService() {
this(new CopyOnWriteArrayList<>());
Copy link
Collaborator

Choose a reason for hiding this comment

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

Pass Collections.emptyList() instead

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Applied, though I think this defeats the purpose of this class, you won't be able to save authorizations into this in-memory store. Is that fine?

@krisztian-toth krisztian-toth force-pushed the implement-in-memory-authorization-service branch 3 times, most recently from 437ad78 to 20529dd Compare May 7, 2020 14:15
@krisztian-toth
Copy link
Contributor Author

@jgrandja see my reply, PR is also updated

@krisztian-toth krisztian-toth force-pushed the implement-in-memory-authorization-service branch 2 times, most recently from aef346f to a243904 Compare May 7, 2020 14:19
@krisztian-toth krisztian-toth force-pushed the implement-in-memory-authorization-service branch from a243904 to 7a6a316 Compare May 7, 2020 14:42
@jgrandja jgrandja added this to the 0.0.1 milestone May 17, 2020
@jgrandja jgrandja added the status: duplicate A duplicate of another issue label May 17, 2020
jgrandja added a commit that referenced this pull request May 17, 2020
@jgrandja jgrandja merged commit 7a6a316 into spring-projects:master May 17, 2020
@jgrandja
Copy link
Collaborator

Thanks for all the updates @watsta ! FYI, I added a polish commit to get this merged. This is now in master.

@krisztian-toth krisztian-toth deleted the implement-in-memory-authorization-service branch May 18, 2020 07:12
doba16 pushed a commit to doba16/spring-authorization-server that referenced this pull request Apr 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: duplicate A duplicate of another issue type: enhancement A general enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement Authorization Model / Service
5 participants