ASP.NET 7 Enabling Client Side Caching
tutorialsEU - C# tutorialsEU - C#
19.6K subscribers
2,016 views
0

 Published On Mar 17, 2023

🔥 SPEED UP your application with CLIENT-SIDE CACHING! If this sounds complicated to you, trust me, it couldn't be EASIER!

🚀 SKYROCKET your C# skills and become a sought-after C# web developer with our C# Progress Academy: https://academy-tutorials.eu/csharp-p...

📚 Interested in Code Optimization? Then you should try out multithreading! Check our chapter 7 of the TINY C# PROJECTS BOOK!
https://www.manning.com/books/tiny-c-...

We'll make sure to turn you into a true developer in no time!

Timestamps:
00:00 Introduction
00:16 What is client side caching?
00:30 Enabling client side caching
02:35 Check this out!
02:58 Enabling response caching
05:11 Thanks for watching!

ASP.NET 7 Enabling Client Side Caching

So, what is C#?
C# (pronounced "See Sharp") is a modern, object-oriented, and type-safe programming language. C# enables developers to build many types of secure and robust applications that run in .NET. C# has its roots in the C family of languages and will be immediately familiar to C, C++, Java, and JavaScript programmers. This tour provides an overview of the major components of the language in C# 8 and earlier. If you want to explore the language through interactive examples, try the introduction to C# tutorials.
C# is an object-oriented, component-oriented programming language. C# provides language constructs to directly support these concepts, making C# a natural language in which to create and use software components. Since its origin, C# has added features to support new workloads and emerging software design practices. At its core, C# is an object-oriented language. You define types and their behavior.

And what is ASP?
ASP.NET is an open-source, server-side web-application framework designed for web development to produce dynamic web pages. It was developed by Microsoft to allow programmers to build dynamic web sites, applications and services. The name stands for Active Server Pages Network Enabled Technologies.

And what is client side caching?
Response caching reduces the number of requests a client or proxy makes to a web server. Response caching also reduces the amount of work the web server performs to generate a response. Response caching is set in headers.

The ResponseCache attribute sets response caching headers. Clients and intermediate proxies should honor the headers for caching responses under RFC 9111: HTTP Caching.

For server-side caching that follows the HTTP 1.1 Caching specification, use Response Caching Middleware. The middleware can use the ResponseCacheAttribute properties to influence server-side caching behavior.

The Response caching middleware:

Enables caching server responses based on HTTP cache headers. Implements the standard HTTP caching semantics. Caches based on HTTP cache headers like proxies do.
Is typically not beneficial for UI apps such as Razor Pages because browsers generally set request headers that prevent caching. Output caching, which is available in ASP.NET Core 7.0 and later, benefits UI apps. With output caching, configuration decides what should be cached independently of HTTP headers.
May be beneficial for public GET or HEAD API requests from clients where the Conditions for caching are met.
To test response caching, use Fiddler, Postman, or another tool that can explicitly set request headers. Setting headers explicitly is preferred for testing caching.

To learn more, make sure to watch the video, and we promise you that you'll become a better developer by the end of the video! Have fun!

And thank you LAKEY INSPIRED for these amazing songs that we use in all our videos! @LAKEYINSPIRED

#csharp #coding #tutorial #learn #microsoft #net #caching #optimization

TAGS
c#,.net,c-sharp,csharp,programming,visual studio,c sharp,learn c#,c# programming,c# tutorial,c# for beginners,learn c# programming,c# course,development,how to code,cache,dotnet,caching,dot net,distributed caching,asp.net caching,asp.net core scalability,asp.net 7 enabling client side caching,in-memory distributed cache,.net core,asp.net core,caching in asp.net,distributed cache,asp.net,response caching c#,core,coding,software engineering,code,web api

TutorialsEU offers you free video tutorials about programming and development for complete beginners up to experienced programmers.
This includes C#, Unity, Python, Android, Kotlin, Machine Learning, etc.
Stay tuned and subscribe to tutorialsEU: https://goo.gl/rBFh3x

C#:    / @tutorialseuc  
Facebook:   / tutorialseu-109380204093233  
LinkedIn:   / tutorialseu  
Discord:   / discord  

show more

Share/Embed