Configuration is one of the core fundamentals of any .NET application. Whether it's a web application, an API,
a desktop application or anything in between, every application has settings and options that make it configurable,
flexible and functional. From simple numbers and booleans to connection strings that need to be stored and loaded
securely, everything needs to be handled with care and a complete understanding of how they work and what is
happening under the hood. In this course, Microsoft Senior Content Developer David Pine will teach you everything you
need to know to get up to speed with Configuration and Options in .NET.
Course Curriculum
3h 28m 10 sections
Welcome
01:13Free preview
What will you learn in this course?
01:45Free preview
Who is the course for and prerequisites
00:34Free preview
Introduction
00:49
What is Configuration?
01:45
Why configuration is important?
01:38
Configuration in .NET
01:28
Configuration sources & providers
01:11
First Configuration NuGet package
02:47
Explore the IConfiguration and related APIs
07:34
Section Recap
01:21
Introduction
01:07
Standalone vs. Host
04:04
What’s a ConfigurationManager?
01:21
Exploring the Worker Service default configuration
01:30
Running the Worker Service with template behavior
00:34
Learning the JSON configuration provider capabilities
01:45
Environment specific configuration
02:56
Configuring and manually parsing custom values
01:43
Benefiting from the Binder package
01:40
Section Recap
01:31
Introduction to Configuration Providers
00:37
Base File Providers
00:47
Discussing the empty application builder sample app
01:12
JSON configuration provider
03:00
XML configuration provider
01:51
INI configuration provider
01:48
User Secrets configuration provider
01:36
Managing user secrets
06:36
Environment Variables configuration provider
02:31
Command-line configuration provider
03:31
Key-per file configuration provider
02:25
Azure Key Vault configuration provider
04:10
Azure App Configuration provider with Key Vault secrets
03:36
Section Recap
00:59
Introduction to Implementing a Custom Configuration Provider
01:31
Create the implementation class library
01:35
Implement the IConfigurationSource
01:23
Implement the IConfigurationProvider
02:27
Extend IConfigurationBuilder and expose AddYamlFile APIs
02:22
Implementing the YAML parser
09:35
Review and Finalize implementation details
02:11
Consuming YAML configuration with custom provider
04:29
Section Recap
01:07
Introduction to the Options Pattern
02:09
Modeling the Logging Options
02:09
Bind Logging Options to Configuration
01:50
Consuming Logging Options through DI
02:41
Adding another options-modeled object
01:02
Binding additional named-options
01:48
Configuring and editing named-options
01:30
Resolving named-options by name
01:30
Verifying configuration bindings and DI hydration
01:13
Considering alternative APIs for registering options
01:40
Overriding configurations with post configure APIs
02:15
Overriding all config-bound instances
01:52
Avoid implementing IOptions
01:58
Understanding reflection-based binding
02:14
Enabling source-generated configuration binding
02:05
Section Recap
01:01
Introduction to Validating Options
01:42
Implementing the IValidateOptions interface
05:07
Registering options with validation
03:02
Using data-annotations for declarative validation
04:45
Handling validation errors
04:36
Expressing simple delegate-based validation with fluent APIs
03:21
Controlling when validation errors occur
02:24
Compile-time validation with source-generators
04:07
Section Recap
01:36
Introduction to Options Monitoring
01:13
Differentiating Options interfaces
02:10
Visualizing an Alerting App Scenario
01:07
Exploring the Alerting Implementation
07:47
Post Code-walk: Options and Settings
03:08
Changing Config Data & Monitoring Alerts
02:04
Being Mindful of Monitoring Limitations
01:32
Section Recap
01:13
Introduction to Consumer-Centric (Empathy-based) Authoring
David Pine works in Developer Relations at Microsoft, focusing on .NET and Azure developer content. He is recognized as a Google Developer Expert in Web Technologies. David is the O'Reilly Media author of "Learning Blazor: Build Single-Page Apps with WebAssembly and C#". David focuses on the developer community, actively seeking opportunities to share knowledge through speaking engagements around the world. David advocates for open-source, the .NET Foundation, C#, TypeScript, SignalR, Reactive Extensions, Azure and .NET. He's a co-host of the On .NET Live stream, part of the .NET Live TV family of streaming shows.