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

Added JWT.Extensions.DependencyInjection #346

Merged
merged 6 commits into from
Nov 18, 2021
Merged

Added JWT.Extensions.DependencyInjection #346

merged 6 commits into from
Nov 18, 2021

Conversation

abatishchev
Copy link
Member

Resolves #336

@abatishchev
Copy link
Member Author

@frankely can you please also help testing version 7.4.0?

the difference is that 7.3.1 contains all extension methods but 7.4.0 depends on the new Jwt.Extensions.DependencyInjection which contains generic DI container extension methods and Jwt.Extensions.AspNetCore contains only for authentication.

Makes sense?

@frankely
Copy link
Contributor

You bet I got you @abatishchev

@abatishchev
Copy link
Member Author

@frankely gentle ping, please. your help is greatly appreciated.

@frankely
Copy link
Contributor

I'll get into it! Somehow I had troubles trying to find the new version. I'll try again today!

@frankely
Copy link
Contributor

Done @abatishchev

@abatishchev
Copy link
Member Author

You got it from here, correct? Looks good? Ship it?

@frankely
Copy link
Contributor

Actually, after upgrading them I'm getting errors because there is no AddJwt extension method anymore and the JwtAuthenticationDefaults and JwtAuthenticationOptions classes don't exist anymore. @abatishchev

@abatishchev
Copy link
Member Author

@frankely wait, how come? can you post a snippet of your code? i haven't changed the extension method's signature:

namespace JWT
{
    public static class AuthenticationBuilderExtensions
    {
        public static AuthenticationBuilder AddJwt(this AuthenticationBuilder builder) { ... }

        public static AuthenticationBuilder AddJwt<TFactory>(this AuthenticationBuilder builder)
            where TFactory : class, IAlgorithmFactory { ... }

@frankely
Copy link
Contributor

frankely commented Sep 28, 2021

Sorry that I haven't looked into this, but I have been swamped with other stuff. Can you provide an example of how to use the newer version? Do you have available as a NuGet prerelease version somewhere with some docs? @abatishchev

@abatishchev
Copy link
Member Author

abatishchev commented Oct 6, 2021

@frankely sorry for the delay in response! and thanks for helping me to test the new functionality.

I think the easiest way to test would be to download the packages into a folder and setup is as a local feed, if you haven't done that already.

However the problem is that the package version hasn't changed so the previous version has been cached by NuGet in few places locally. So what I did is I appended both packages with `-beta1 and will increment it every time I make a change in the PR. Will drop it once we're done.

Please try out the latest version from this build.

@abatishchev
Copy link
Member Author

Ping, please let me know if you had a chance to try the latest build.

@abatishchev
Copy link
Member Author

@frankely, ping please.

@frankely
Copy link
Contributor

Hey! I'll look into this!

@frankely
Copy link
Contributor

I upgraded to JWT to Version="8.4.2" and it works great!

@abatishchev abatishchev merged commit b071d3a into main Nov 18, 2021
@abatishchev abatishchev deleted the alex/ms-di-1 branch November 18, 2021 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Add NuGet package for integration with Microsoft.Extensions.DependencyInjection
2 participants