This is awesome. Middleware has always been a fuzzy subject for me but this is helping to make more sense of things. Looking forward to the rest of this series!
Very clear explanation. Building up from doing this directly in the program then moving it to a middleware class made it easy to follow and understand.
Not enough tutorials on middleware related to making your own. Thanks a ton! I've been mulling through many MS docs on the topic w/a blank stare for quite some time with the goal of creating custom middleware that detects IPaddress and other client info from bad actors and wanting to terminate the request when visits (unauthenticated) appear to be coming from spambots and hackerbots (to eliminate the extreme wastefulness of resources when my site(s) are attacked or deluged with bad traffic). I like to log extreme attacks into a queue outside of the web server, asynchronously, for future parsing and hacker profiling - (had a system I wrote years ago that did this from an IIS extension & it worked extremely well and wanted to make it more portable).
Just Woow this the best explanation I've seen so far, I really struggled learning about how middleware works so thank you so much , hope you tell us how we learn how to learn this kinds on concepts , keep going :)
thanks for posting Shawn. Looks to me like middleware is technically a node in a linked list, passing request http context to the next node and back recursively.
Looking forward to the next video in the middleware series! Question. Why do you abbreviate context as ctx? I always thought writing "context" made it clearer what it was when browsing over code
AddTransient is for stateless objects, where as a singleton is shared by everyone who requests it. I tend to want more Transient (smaller) than Singletons. I only use Singletons if I really have to have shared state (IConfiguration is static as an example).
I thank you for your time and efforts for that tutorial. I usually like your tutorials and I know you by name from many tutorial's series. But this one was about some chaotic useless examples. You did not mention one example that might be really useful about that middleware.
yes, it was a useless example to show the simplicity of the middleware. But you could imaging logging and performance in a middleware. I've used it to support caching or early execution of code (e.g. calculate the connection string based on authentication).
awesome content, don’t listen your wife XD… quick question is there an easy/feasible way to time measure all middlewares? yeah, I’m looking at you telemetry….
I don't think there is any way to do that out of the box, but I've done this with a small middleware that I plug into different places to see where bottlenecks are, but I'd not use them in production.
@@swildermuth That's what I thought, but thanks for answering back =) To make it even complicated, it's happening with a legacy .net framework system, oh boy ...
Beautifully explained. I was too confused about middleware and how it works. Now I got a clear picture.
This is awesome. Middleware has always been a fuzzy subject for me but this is helping to make more sense of things. Looking forward to the rest of this series!
Very welcome!
Thank you Shawn, saved to my "Watch Later" for mandatory viewing.
Very clear explanation. Building up from doing this directly in the program then moving it to a middleware class made it easy to follow and understand.
Awesome, glad you liked it.
You've earned yourself another sub. Can't wait to go through the rest of your content in my spare time.
Thanks for subscribing! I'll have a new video about once a week.
Not enough tutorials on middleware related to making your own. Thanks a ton! I've been mulling through many MS docs on the topic w/a blank stare for quite some time with the goal of creating custom middleware that detects IPaddress and other client info from bad actors and wanting to terminate the request when visits (unauthenticated) appear to be coming from spambots and hackerbots (to eliminate the extreme wastefulness of resources when my site(s) are attacked or deluged with bad traffic). I like to log extreme attacks into a queue outside of the web server, asynchronously, for future parsing and hacker profiling - (had a system I wrote years ago that did this from an IIS extension & it worked extremely well and wanted to make it more portable).
always clean and simple explanations
Glad you like them!
That was calm and cool. Appreciate the way you explain
I appreciate that!
You make everything simple like charm, very useful , thank you so much
Happy to help!
You are a legend mate. Really well explained
Just Woow this the best explanation I've seen so far, I really struggled learning about how middleware works so thank you so much , hope you tell us how we learn how to learn this kinds on concepts , keep going :)
Great to hear!
As always, great content. Your courses, content, and newsletter have helped me a lot.
Glad you like them!
i like this dude he is a good teacher
Very Good, Shawn. Keep up the good work.
Thanks, you too!
thanks for posting Shawn. Looks to me like middleware is technically a node in a linked list, passing request http context to the next node and back recursively.
Awesome video. Definitely helped me understand this subject. Thank you very much!
Incredible explanation! Thank you for sharing this with us.
Glad to help!
Always amazing content. Very will explained!!! Thanks!
My pleasure!
This was an amazing video! Great explanation. Thank you!
You're very welcome!
Very nice and easy understandable explanation! I enjoyed it alot, thank you!
Amazing explanation Thanks Shawn !
Glad you liked it!
Nicely explained!
First time watcher this was a great video, just subscribed. Are you planning on making videos on identity server, authentication or authorization?
Auth, yes. But Identity Server is being replaced by a MSFT tool that won't have runtime license needs.
Thanks a bunch for the awesome video!
You bet!
Great video! Thank you so much.
You're very welcome!
Thank you so much for such a great video. Nice explanation! 👍
You're very welcome!
Thank you for the clear explanation! :)
Glad it was helpful!
Thank you!
This is awesome. Nice job!
Thank you! Cheers!
Very good and informative explanation.
Glad you liked it
Great Vid. Awesome explanation! 👍
Thank you! 👍
Thank you this was great!
Looking forward to the next video in the middleware series!
Question. Why do you abbreviate context as ctx? I always thought writing "context" made it clearer what it was when browsing over code
Old habit, probably not a best practice. I use these common shorter variables:
- context: ctx
- builder: bldr
- options: opt
>coding "shorts"
>20 minutes
Excelente video, muy bien explicado👍
This is really nice
Thanks!
Very good!
Thanks!
thanks sean, good video man :)
You're welcome - no matter how you spell my name ; )
sorry Shawn wont happend again@@swildermuth
Middleware and Microservices!!!!
Thank you very much for the explanation! @swildermuth Why we need AddTransient here and not Singleton?
AddTransient is for stateless objects, where as a singleton is shared by everyone who requests it. I tend to want more Transient (smaller) than Singletons. I only use Singletons if I really have to have shared state (IConfiguration is static as an example).
What was the next lesson in the middleware series called?
Not sure I had a 2nd part, did I promise one? (been a while since I made this).
@@swildermuth Yes you had mentioned at the start of the video it was going to be multi-part I believe.
In the TimingMiddleware class how to invoke automatically Invoke method it is not working
Can you share your code?
@@swildermuth I did not have code . I am watching your video. Can you share Github link
I thank you for your time and efforts for that tutorial. I usually like your tutorials and I know you by name from many tutorial's series. But this one was about some chaotic useless examples. You did not mention one example that might be really useful about that middleware.
yes, it was a useless example to show the simplicity of the middleware. But you could imaging logging and performance in a middleware. I've used it to support caching or early execution of code (e.g. calculate the connection string based on authentication).
can you share code
awesome content, don’t listen your wife XD… quick question is there an easy/feasible way to time measure all middlewares? yeah, I’m looking at you telemetry….
I don't think there is any way to do that out of the box, but I've done this with a small middleware that I plug into different places to see where bottlenecks are, but I'd not use them in production.
@@swildermuth That's what I thought, but thanks for answering back =) To make it even complicated, it's happening with a legacy .net framework system, oh boy ...
Thank you so much! This is the middleware I have created
ruclips.net/video/ltwTzyTOnKY/видео.html