Skip to content

[Question] IdentityUser<string> and default Idsrv4 DbContexts #154

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

Closed
lurumad opened this issue Jan 26, 2019 · 8 comments
Closed

[Question] IdentityUser<string> and default Idsrv4 DbContexts #154

lurumad opened this issue Jan 26, 2019 · 8 comments
Assignees
Labels
question Further information is requested

Comments

@lurumad
Copy link

lurumad commented Jan 26, 2019

Hi folks,

First, thank you for your awesome project and all your efforts to bring the community a free AdminUI for IdentityServer4.

I have a couple of questions about the Skoruba internals architecture:

¿Why don't use the generic base for ASP.NET Identity Core IdentityUser?
¿Why don't use Idsrv4 DbContexts instead of creating interfaces like IAdminConfigurationDbContext and IAdminPersistedGrantDbContext?
¿Why to force to implement IAdminLogDbContext in order to use Skoruba?

In my case, these two things are stoppers to use Skoruba in our existing projects, because works with default interfaces.

Regards!

@lurumad lurumad changed the title [Question] Use of custom DbContexts [Question] IdentityUser<string> and default Idsrv4 DbContexts Jan 26, 2019
@skoruba skoruba self-assigned this Jan 26, 2019
@skoruba skoruba added the question Further information is requested label Jan 26, 2019
@skoruba
Copy link
Owner

skoruba commented Jan 26, 2019

Hi @lurumad

Why don't use the generic base for ASP.NET Identity Core IdentityUser?

  • You are right, I will change it back to the default - I get same feedback already.

Why don't use Idsrv4 DbContexts instead of creating interfaces like IAdminConfigurationDbContext and IAdminPersistedGrantDbContext

  • These intefaces are based on the default IS4 interfaces but extended with some extra stuff specific for Admin part - especially IAdminConfigurationDbContext where there is necessary to work with whole IS4 db model

Why to force to implement IAdminLogDbContext in order to use Skoruba

  • This is great question - I consider excluding it - good point.

I will contact you with the progress later.

Thank you for your feedback! :)

@lurumad
Copy link
Author

lurumad commented Jan 26, 2019

Thank you so much for your answers!

Regards!

@skoruba
Copy link
Owner

skoruba commented Jan 27, 2019

@lurumad - Here is preview - I've changed the primary key for Identity to string:
https://github.com/skoruba/IdentityServer4.Admin/tree/feature/identity-default-key

@TheEvilPenguin
Copy link

I did a little work a while back towards using generics to control the key type. It's still a little rough around the edges and based on an old revision, but it does work:

Dev branch

If it looks promising I can merge later changes back in, tidy it up a bit and do a pull request.

@skoruba
Copy link
Owner

skoruba commented Jan 31, 2019

@TheEvilPenguin - Thank you - I will check it deeper and give feedback. 👍

@Bostrong
Copy link

Bostrong commented Feb 7, 2019

@TheEvilPenguin .. excellent !! Just the ticket to convince me to start using this Ids4 addition.

.. and also thanks for the great work on this @skoruba ... will try to contribute where possible.

@skoruba
Copy link
Owner

skoruba commented Feb 7, 2019

@TheEvilPenguin - Your changes looks really good, much cleaner especially in views - where you are using the interface.
Can you please send the PR with your changes? Ideally into latest dev branch. :)
Thanks!

@skoruba skoruba mentioned this issue Apr 4, 2019
@skoruba
Copy link
Owner

skoruba commented Apr 4, 2019

Done on master. Please check new release.
Thanks!

@skoruba skoruba closed this as completed Apr 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants