Excellent timing - I just completed the Authentication section of your Pragmatic Clean Architecture course and wanted to learn more about this point specifically. Thanks!
@MilanJovanovicTech Жыл бұрын
Awesome, glad this was helpful to add more details 🔥
@MilanJovanovicTech Жыл бұрын
Want to master Clean Architecture? Go here: bit.ly/3PupkOJ Want to unlock Modular Monoliths? Go here: bit.ly/3SXlzSt
@johnnyirish9852 Жыл бұрын
Very nice video on an interesting topic. Ideas for continuing on this: write unit tests for this, write a handler that manages redirects (I think that would need to be the lowest handler, and be a different type than DelegatingHandler)
@MilanJovanovicTech Жыл бұрын
Where would we be redirecting? 🤔
@johnnyirish9852 Жыл бұрын
@@MilanJovanovicTech It would be for example a handler that just logs redirect links. in the case you navigate to a link provided by the user and you want to log potential redirects, when you try to download from the user provided link.
@nove1398 Жыл бұрын
Clean thumbnail, really good content.
@MilanJovanovicTech Жыл бұрын
You like the thumbnail? I started working with an editor
@kodindoyannick532810 ай бұрын
Thank so much Milan. I understand better this concept with your explanation.
@MilanJovanovicTech10 ай бұрын
Glad it was helpful :)
@quocboy159 Жыл бұрын
this is brilliant. I was wondering if you could help me explain when we should use transient, scope, and singleton in DI for the practical case?
@MilanJovanovicTech Жыл бұрын
Transient - stateless and lightweight services Scoped - one instance per scope (an HTTP request is a scope) Singleton - one instance per app
@10Totti Жыл бұрын
Best tutorial!
@MilanJovanovicTech Жыл бұрын
Thank you!
@jaans3712 Жыл бұрын
Do you have a video about Keycloak? Interesting topic
@MilanJovanovicTech Жыл бұрын
No, I don't have a Keycloak video on the channel. However, I did cover Keycloak in the Auth section of my course. But it's not free 😅
@jaans3712 Жыл бұрын
@@MilanJovanovicTech you salesman!
@TopBabymonkeys Жыл бұрын
how to solve this : Bearer error="invalid_token", error_description="The signature key was not found" when using http client in blazor
@MilanJovanovicTech Жыл бұрын
No idea
@pigrebanto11 ай бұрын
Maybe it is more naive apporach but there is also a way to nest Http Handlers within constructors; something like: var client = new HttpClient( new myHttpMsgHanlder_1( new myHttpMsgHanlder_2( new HttpClientHandler() ) )); how do you see it?
@MilanJovanovicTech11 ай бұрын
Still prefer using the recommended approach
@microtech2448 Жыл бұрын
Let's say there are 3 external APIs meaning their base address, authentication process would be different and only one of them would be called based on user input. In that case how would you register them in the startup with message handlers without duplicating code? Thank you.
@MilanJovanovicTech Жыл бұрын
Create an extension method that will apply the specific message handlers. But you will still have to call that method for each HttpClient.
@pp-studio Жыл бұрын
Thank you for your content.
@MilanJovanovicTech Жыл бұрын
Don't mention it, glad it was valuable!
@DivljaVoda Жыл бұрын
I have a problem with this approach, i am logging the request and response that go trough httpClient. I need a scoped Service that logs the data. The problem is that the Scoped service contains properties that are same for the httpRequest comming trough api, controllers, services and httpClients that are called within. The problem is that the scoped logging service is somehow out of scope in the DelegateHandler, i tried HttpContextAccessor, it works when the requests come from API, but the problem comes up when the httpClient is called from a background task, scoped logging service is out of scope - therefore the properties that i have are lost when called within delegation handler. How do i solve that problem, do you have an idea?
@MilanJovanovicTech Жыл бұрын
That's a design smell to me. Can this be re-implemented to consider that there is no HttpContext in the background task?
@mentalmadness97832 ай бұрын
Why is this better than doing all the steps for example inside of my Function in Azure Function App? What is the upside of doing it before anything?
@MilanJovanovicTech2 ай бұрын
Reusability. Why don't we place all the ASP .NET middleware in the controller endpoint?
@TheRealBenSanders Жыл бұрын
This helped me so much. What Theme are you running with?
@MilanJovanovicTech Жыл бұрын
ReSharper syntax highlighting
@pigrebanto11 ай бұрын
did it fail after 2 times? shouldn't have been 3 times the retry instead? tks
@MilanJovanovicTech11 ай бұрын
Yes - I might've sped it up for the presentation :)
@Th3MoL3 Жыл бұрын
Hmmmm......i was getting a bit of déjà vu as i was thinking i had seen this in a video already very recently. Nick Chapsas literally had a video talking about this 4 days ago....maybe its a coincidence 👀
@MilanJovanovicTech Жыл бұрын
It is, I schedule my videos 2-4 weeks in front 📆📆
@clashclan4739 Жыл бұрын
Title misleading where decorator pattern?
@MilanJovanovicTech Жыл бұрын
Fixed it 😁
@techpc5453 Жыл бұрын
@MilanJovanovicTech Жыл бұрын
👋
@ronaldabellano5643 Жыл бұрын
Why cant save?
@MilanJovanovicTech Жыл бұрын
What do you mean?
@altkev Жыл бұрын
I hope one day videos with goofy faces on thumbnails attract less clicks so that trend can go away. This is a programming channel, do these types of viewer's even click more from that?
@MilanJovanovicTech Жыл бұрын
Then you're hoping for human psychology to go away, and well... that isn't really happening. 😅 What does it matter anyway? The content is what's important. If you like it, you'll watch it. If not, you'll stop watching.
@altkev Жыл бұрын
@@MilanJovanovicTech Well my comment is a sign that its resulted in me thinking about and focusing on your thumbnail enough to comment about it, so if that's a positive thing for the channel due to the additional engagement, then I suppose there is no incentive for change. But I will say cringe titles/thumbnails can be polarizing.
@MilanJovanovicTech Жыл бұрын
@@altkev Okay, but does the content deliver on the value? Because if it doesn't, I'm doing something wrong. My other option is doing "normal" thumbnails and getting 30-50% less views. :( KZbin is saturated. Right now, there isn't any other way to stand out. P.S. You may want to skip next Friday's video. Quite an awesome thumbnail if I may say so myself, but probably not to your taste. 😅
@altkev Жыл бұрын
@@MilanJovanovicTech 30-50% less views just by not putting your face on there is extreme. Well regardless of my personal tastes and desire to comment on it, you should certainly do what you need to for your channel's success. My comment was more of a commentary that it is unfortunate that such strategies have to be used in the first place.