SlideShare uma empresa Scribd logo
1 de 25
Baixar para ler offline
.NET Core: Configuration
Fundamentals
David Dieruf - Pivotal
July, 2019
Let's Talk About...
Cloud-native environment and goals
Why we are here
Designing config and environment variables
Different patterns
About .NET Core configuration
Building config providers in WebHost and its hierarchy of values
The options pattern
Extending basic config with objects
External configuration servers
How they work and why you choose them
Putting the pieces together
Using Steeltoe and Spring Config to reach cloud-native goals
Environment: Local
Network
Services: DB, Cache, SMB
Environment: Stage Environment: Prod
Team Foundation Server (CI/CD): Git, Build, Release
My-App
Network
Services: DB, Cache, SMB
Network
Services: DB, Cache, SMB
My-App My-App
- One build
- Test once (for all environments)
- Parity between environments
- Automation
My-App My-App
public void ConfigureServices(IServiceCollection services) {
String connString = Environment.GetEnvironmentVariable("conn_string");
services.AddDbContext<MyContext>(options => options.UseSqlServer(connString));
}
Environment variables in the cloud
How is the value set?
Do you have to manually update the value per
instance, or script the action?
How easy is promotion?
Do you have to recompile to move between
environments? Does your build pipeline manipulate
settings?
Do you have a history of changes?
Do you know when a value was set and by who?
Atomic value in the
cloud
Per app instance
App can not run without
a value
Agnostic to its platform
or IaaS (portable)
Appsettings.json
● [Good] External to the
compiled application
● [Good] No recompilation
needed
● [Challenge] Have to change
at every instance
Internal Class Command Line
● [Good] Secure information
in compiled bits
● [Challenge] Hard coded
values in app
● [Challenge] Can not change
without recompiling
● [Good] External to the
compiled application
● [Challenge] Have to change
at every instance
● [Challenge] Lost values
because no source check-in
(Manual)
Environment Variables
Popular Configuration Design
● [Good] External to the
compiled application
● [Good] Application
compiled once and
promoted through
environment
● [Challenge] Have to change
at every host
class MyClass {
string connString = "xxxx"
}
{
"ConnectionStrings": {
"a-database": "xxxxx"
}
}
C: dotnet run my-app `
--conn "xxxx" `
--something "yyyyy"
string connString =
Environment.GetEnvironmentVari
able("my-conn")
https://docs.microsoft.com/en-us/aspnet/core/fundamentals/configuration
.NET Core Configuration
Using Default
WebHost
Loading configuration into your app
public static IWebHostBuilder CreateWebHostBuilder(string[] args) =>
WebHost.CreateDefaultBuilder(args)
.UseStartup<Startup>();
- use Kestrel as the web server and configure it using the
application's configuration providers
- set the ContentRootPath to the result of GetCurrentDirectory()
- load IConfiguration from 'appsettings.json' and
'appsettings.[EnvironmentName].json'
- load IConfiguration from User Secrets when EnvironmentName
is 'Development' using the entry assembly
- load IConfiguration from environment variables
- load IConfiguration from supplied command line args
- configure the ILoggerFactory to log to the console and debug
output
- enable IIS integration
program.cs
WebHost.CreateDefaultBuilder(args)
Build your own
WebHost
Loading configuration into your app
public static IWebHost BuildWebHost(string[] args) {
var builder = new WebHostBuilder()
.UseKestrel()
.UseContentRoot(Directory.GetCurrentDirectory())
.ConfigureAppConfiguration((hostingContext, config) => {
var env = hostingContext.HostingEnvironment;
config.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json",
optional: true);
config.AddEnvironmentVariables();
config.AddCommandLine(args);
})
.UseIISIntegration()
.UseStartup<Startup>();
return builder.Build();
}
program.cs
- Options manipulate how configuration values are overwritten
- Options to [not] include other configuration providers, like
custom external config server provider
var builder = new WebHostBuilder()
Config value
hierarchy
Overwrite values based on
environment
public static IWebHost BuildWebHost(string[] args) {
var builder = new WebHostBuilder()
...
.ConfigureAppConfiguration((hostingContext, config) => {
var env = hostingContext.HostingEnvironment;
config.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json");
config.AddEnvironmentVariables();
config.AddCommandLine(args);
})
...
1. Load values from appsettings.json
2. (if provided) Load values from environment
specific appsettings.{env}.json
3. (if present) Load values from environment
variables
4. (if present) Load values provided when app
was started
config.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json");
config.AddEnvironmentVariables();
config.AddCommandLine(args);
{
"my_val": "something"
}
Example Value Overwriting
1. config.AddJsonFile("appsettings.json")
{
"my_val": "another"
}
2. .AddJsonFile("appsettings.staging.json")
PS c: $env:my_val = "yet another"
3. config.AddEnvironmentVariables()
PS c: dotnet run my-app --my_val "again another"
4. config.AddCommandLine(args)
my_val == “again another”
Configuration
Providers
Supported providers for
configuration of ASP.NET core app
Provider
Provides configuration
from…
Azure Key Vault Configuration Provider (Security topics) Azure Key Vault
Azure App Configuration Provider (Azure documentation) Azure App Configuration
Command-line Configuration Provider Command-line parameters
Custom configuration provider Custom source
Environment Variables Configuration Provider Environment variables
File Configuration Provider Files (INI, JSON, XML)
Key-per-file Configuration Provider Directory files
Memory Configuration Provider In-memory collections
User secrets (Secret Manager) (Security topics) File in the user profile directory
Consuming
Values
Using
Microsoft.Extensions.Configuration
public class ValuesController : Controller{
private readonly IConfiguration _config;
public ValuesController(IConfiguration config){
_config = config;
}
[HttpGet]
public ActionResult<string> Get(){
string val = _config.GetValue<string>("my_val");
return val;
}
}
- No consideration for handler type(s)
- Simple key:value store
- Can be complex type
ValuesController.cs
https://docs.microsoft.com/en-us/aspnet/core/fundamentals/configuration/options
Options Pattern
Options Pattern Using Microsoft.Extensions.Configuration.Options
{
"section0": {
"key0": "value",
"key1": "value"
},
"section1": {
"key0": "value",
"key1": "value"
}
}
public void ConfigureServices(IServiceCollection services) {
services.AddOptions();
services.Configure<SectionZeroOptions>(Configuration.GetSection("section0"));
...
}
public class SectionZeroOptions {
public string key0 {get;set;}
public string key1 { get; set; }
}
public class MyService : IMyService {
private IOptions<SectionZeroOptions> _SectionZeroOptions;
public MyService(IOptions<SectionZeroOptions> sectionZeroOptions) {
_SectionZeroOptions = sectionZeroOptions;
}
public string DoSomething(){
string key0 = _SectionZeroOptions.Value.key0;
string key1 = _SectionZeroOptions.Value.key1;
return key0;
}
}
1. appsettings.json values
2. Matching class to json
3. Enable the Options configuration
4. Consume values
{
"section0": {
"key0": "value",
"key1": "value"
},
"section1": {
"key0": "value",
"key1": "value"
}
}
public class SectionZeroOptions {
public string key0 {get;set;}
public string key1 { get; set; }
}
public void ConfigureServices(IServiceCollection services) {
services.AddOptions();
services.Configure<SectionZeroOptions>(Configuration.GetSection("section0"));
...
}
public class MyService : IMyService {
private IOptions<SectionZeroOptions> _SectionZeroOptions;
public MyService(IOptions<SectionZeroOptions> sectionZeroOptions) {
_SectionZeroOptions = sectionZeroOptions;
}
public string DoSomething(){
string key0 = _SectionZeroOptions.Value.key0;
string key1 = _SectionZeroOptions.Value.key1;
return key0;
}
}
Business Case using options pattern
You have an api that is responsible for approving loans. There are
business rules within the app that need to be applied, to decide
approval. One of those rules compares the loan amount being asked
for, to a max loan amount the business is willing to approve. The max
amount changes throughout the year based on other events.
Place the max approval amount (integer) in an external config and give
yourself the flexibility to change values at any moment, with no
downtime.
External Configuration Server
Custom configuration provider
About Config
Server
At boot time…
➔ Platform puts values in environment variables
➔ Client looks for server
➔ Client gets config by NAME
➔ Config organised by PROFILE
At runtime...
➔ Config can be refreshed live
➔ Call /actuator/refresh
➔ Values get reloaded
➔ No need for restart!
Environment: Stage Environment: ProdEnvironment: Local
Network
Services: DB, Cache, SMB
Team Foundation Server (CI/CD): Git, Build, Release
Network
Services: DB, Cache, SMB
Network
Services: DB, Cache, SMB
Config Server: development.yml, staging.yml, production.yml
string connString = Environment.GetEnvironmentVariable("conn_string");
string configUri = Environment.GetEnvironmentVariable("config_uri");
Simplicity vs Flexibility
External configuration can be challenging in itself It offers so much
design options that things can get out of hand quickly. Use the domain
around you to decide how far to go.
Config First Approach
Don’t hold anything in your appsettings.json, only a pointer to the
config server. Everything is filled from there.
Steeltoe and Spring Config
Putting the pieces together
2. Set the application Name (in appsettings.json)...
Setup Configuration Client: .NET / Steeltoe / Spring Config
4. Include the custom config provider...
1: Add the dependencies...
(Steeltoe for Pivotal Spring Cloud Config Client)
3. Add your external configuration (in Git)...
"spring": {
"application": { "name": "loan-application-service" },
"cloud": {
"config": {
"uri": "http://10.0.7.254:8888",
"validate_certificates": false,
"fail_fast": true
...
<PackageReference
Include="Steeltoe.Extensions.Configuration.ConfigServerCore" ... />
public void ConfigureServices(IServiceCollection services){
services.AddOptions();
services.Configure<Services.SomeValuesOptions>
(Configuration.GetSection("SomeValues"));
services.AddMvc();
...
}
WebHost.CreateDefaultBuilder(args)
.ConfigureAppConfiguration((hostingContext, config) =>{
ILoggerFactory fac = GetLoggerFactory(hostingContext.HostingEnvironment);
var env = hostingContext.HostingEnvironment;
config.AddConfigServer(env, fac);
})
...
public class SomeValuesOptions {
public string scheme { get; set; }
public string address { get; set; }
}
program.cs
startup.cs
config options pattern
Logging:
IncludeScopes: false
Debug:
LogLevel:
Default: Information
SomeValues:
scheme: https
address: www.pivotal.io
5. Retrieve values and map to class...
<PackageReference
Include="Steeltoe.Extensions.Configuration.ConfigServerCore" ... />
"spring": {
"application": { "name": "loan-application-service" },
"cloud": {
"config": {
"uri": "http://127.0.0.1:8888",
"validate_certificates": false,
"fail_fast": true
...
Logging:
IncludeScopes: false
Debug:
LogLevel:
Default: Information
SomeValues:
scheme: https
address: www.pivotal.io
WebHost.CreateDefaultBuilder(args)
.ConfigureAppConfiguration((hostingContext, config) =>{
ILoggerFactory fac = GetLoggerFactory(hostingContext.HostingEnvironment);
var env = hostingContext.HostingEnvironment;
config.AddConfigServer(env, fac);
})
...
public void ConfigureServices(IServiceCollection services){
services.AddOptions();
services.Configure<Services.SomeValuesOptions>
(Configuration.GetSection("SomeValues"));
services.AddMvc();
...
}
public class SomeValuesOptions {
public string scheme { get; set; }
public string address { get; set; }
}
"name": "loan-application-service"
config.AddConfigServer(env, fac);
"uri": "http://127.0.0.1:8888"
© Copyright 2019 Pivotal Software, Inc. All rights Reserved.
Learn More.
Become a cloud-native .NET rock star
https://springoneplatform.io/2019/training
Pivotal Platform Acceleration Lab for Developers (.NET)
Experience best practices building cloud-native applications in
a hands-on setting with Pivotal educators and consultants. The
program is focused on enabling customers and partners
through “doing it” rather than “talking about it”.
https://pivotal.io/platform-acceleration-lab
© Copyright 2019 Pivotal Software, Inc. All rights Reserved.
Questions?
Thank you
Refreshing
Values
- Optionally provide an environment specific
json config
Startup.cs
public static IWebHost BuildWebHost(string[] args) {
var builder = new WebHostBuilder()
...
.ConfigureAppConfiguration((hostingContext, config) => {
var env = hostingContext.HostingEnvironment;
config.AddJsonFile("appsettings.json",
reloadOnChange: true)
.AddJsonFile($"appsettings.{env.EnvironmentName}.json",
optional: true, reloadOnChange: true);
config.AddEnvironmentVariables();
config.AddCommandLine(args);
})
...
Optional
providers
- Optionally provide an environment specific
json config
Startup.cs
public static IWebHost BuildWebHost(string[] args) {
var builder = new WebHostBuilder()
...
.ConfigureAppConfiguration((hostingContext, config) => {
var env = hostingContext.HostingEnvironment;
config.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json",
optional: true);
config.AddEnvironmentVariables();
config.AddCommandLine(args);
})
...

Mais conteúdo relacionado

Mais procurados

JPA and Hibernate Performance Tips
JPA and Hibernate Performance TipsJPA and Hibernate Performance Tips
JPA and Hibernate Performance TipsVlad Mihalcea
 
Developing For The Windows Azure Platform
Developing For The Windows Azure PlatformDeveloping For The Windows Azure Platform
Developing For The Windows Azure Platformdrmarcustillett
 
CloudStack Meetup London - Primary Storage Presentation by SolidFire
CloudStack Meetup London - Primary Storage Presentation by SolidFire CloudStack Meetup London - Primary Storage Presentation by SolidFire
CloudStack Meetup London - Primary Storage Presentation by SolidFire NetApp
 
BeJUG Meetup - What's coming in the OSGi R7 Specification
BeJUG Meetup - What's coming in the OSGi R7 SpecificationBeJUG Meetup - What's coming in the OSGi R7 Specification
BeJUG Meetup - What's coming in the OSGi R7 SpecificationStijn Van Den Enden
 
Play + scala + reactive mongo
Play + scala + reactive mongoPlay + scala + reactive mongo
Play + scala + reactive mongoMax Kremer
 
Couchbase Performance Benchmarking
Couchbase Performance BenchmarkingCouchbase Performance Benchmarking
Couchbase Performance BenchmarkingRenat Khasanshyn
 
Kåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesKåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesNordic Infrastructure Conference
 
Practicing Continuous Deployment
Practicing Continuous DeploymentPracticing Continuous Deployment
Practicing Continuous Deploymentzeeg
 
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...MongoDB
 
High-Performance Hibernate Devoxx France 2016
High-Performance Hibernate Devoxx France 2016High-Performance Hibernate Devoxx France 2016
High-Performance Hibernate Devoxx France 2016Vlad Mihalcea
 
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)Sirar Salih
 
CUBRID Inside - Architecture, Source & Management Components
CUBRID Inside - Architecture, Source & Management ComponentsCUBRID Inside - Architecture, Source & Management Components
CUBRID Inside - Architecture, Source & Management ComponentsCUBRID
 
BASTA 2013: Custom OData Provider
BASTA 2013: Custom OData ProviderBASTA 2013: Custom OData Provider
BASTA 2013: Custom OData ProviderRainer Stropek
 
Multi-tenancy with Rails
Multi-tenancy with RailsMulti-tenancy with Rails
Multi-tenancy with RailsPaul Gallagher
 
Language enhancements in cold fusion 11
Language enhancements in cold fusion 11Language enhancements in cold fusion 11
Language enhancements in cold fusion 11ColdFusionConference
 
Windows Azure HDInsight Service
Windows Azure HDInsight ServiceWindows Azure HDInsight Service
Windows Azure HDInsight ServiceNeil Mackenzie
 
Growing in the Wild. The story by CUBRID Database Developers.
Growing in the Wild. The story by CUBRID Database Developers.Growing in the Wild. The story by CUBRID Database Developers.
Growing in the Wild. The story by CUBRID Database Developers.CUBRID
 
Keystone deep dive 1
Keystone deep dive 1Keystone deep dive 1
Keystone deep dive 1Jsonr4
 
Cassandra 3.0 Data Modeling
Cassandra 3.0 Data ModelingCassandra 3.0 Data Modeling
Cassandra 3.0 Data ModelingDataStax Academy
 

Mais procurados (20)

JPA and Hibernate Performance Tips
JPA and Hibernate Performance TipsJPA and Hibernate Performance Tips
JPA and Hibernate Performance Tips
 
Developing For The Windows Azure Platform
Developing For The Windows Azure PlatformDeveloping For The Windows Azure Platform
Developing For The Windows Azure Platform
 
CloudStack Meetup London - Primary Storage Presentation by SolidFire
CloudStack Meetup London - Primary Storage Presentation by SolidFire CloudStack Meetup London - Primary Storage Presentation by SolidFire
CloudStack Meetup London - Primary Storage Presentation by SolidFire
 
BeJUG Meetup - What's coming in the OSGi R7 Specification
BeJUG Meetup - What's coming in the OSGi R7 SpecificationBeJUG Meetup - What's coming in the OSGi R7 Specification
BeJUG Meetup - What's coming in the OSGi R7 Specification
 
Play + scala + reactive mongo
Play + scala + reactive mongoPlay + scala + reactive mongo
Play + scala + reactive mongo
 
Couchbase Performance Benchmarking
Couchbase Performance BenchmarkingCouchbase Performance Benchmarking
Couchbase Performance Benchmarking
 
Kåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your servicesKåre Rude Andersen - Be a hero – optimize scom and present your services
Kåre Rude Andersen - Be a hero – optimize scom and present your services
 
Practicing Continuous Deployment
Practicing Continuous DeploymentPracticing Continuous Deployment
Practicing Continuous Deployment
 
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
 
High-Performance Hibernate Devoxx France 2016
High-Performance Hibernate Devoxx France 2016High-Performance Hibernate Devoxx France 2016
High-Performance Hibernate Devoxx France 2016
 
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)
Azure Table Storage: The Good, the Bad, the Ugly (15 min. lightning talk)
 
CUBRID Inside - Architecture, Source & Management Components
CUBRID Inside - Architecture, Source & Management ComponentsCUBRID Inside - Architecture, Source & Management Components
CUBRID Inside - Architecture, Source & Management Components
 
BASTA 2013: Custom OData Provider
BASTA 2013: Custom OData ProviderBASTA 2013: Custom OData Provider
BASTA 2013: Custom OData Provider
 
Multi-tenancy with Rails
Multi-tenancy with RailsMulti-tenancy with Rails
Multi-tenancy with Rails
 
Language enhancements in cold fusion 11
Language enhancements in cold fusion 11Language enhancements in cold fusion 11
Language enhancements in cold fusion 11
 
Windows Azure HDInsight Service
Windows Azure HDInsight ServiceWindows Azure HDInsight Service
Windows Azure HDInsight Service
 
Growing in the Wild. The story by CUBRID Database Developers.
Growing in the Wild. The story by CUBRID Database Developers.Growing in the Wild. The story by CUBRID Database Developers.
Growing in the Wild. The story by CUBRID Database Developers.
 
Keystone deep dive 1
Keystone deep dive 1Keystone deep dive 1
Keystone deep dive 1
 
Azure Data Storage
Azure Data StorageAzure Data Storage
Azure Data Storage
 
Cassandra 3.0 Data Modeling
Cassandra 3.0 Data ModelingCassandra 3.0 Data Modeling
Cassandra 3.0 Data Modeling
 

Semelhante a Learn Cloud-Native .NET: Core Configuration Fundamentals with Steeltoe

quickguide-einnovator-8-spring-cloud
quickguide-einnovator-8-spring-cloudquickguide-einnovator-8-spring-cloud
quickguide-einnovator-8-spring-cloudjorgesimao71
 
.NET Core, ASP.NET Core Course, Session 8
.NET Core, ASP.NET Core Course, Session 8.NET Core, ASP.NET Core Course, Session 8
.NET Core, ASP.NET Core Course, Session 8aminmesbahi
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetesBen Hall
 
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...Amazon Web Services
 
Dive into DevOps | March, Building with Terraform, Volodymyr Tsap
Dive into DevOps | March, Building with Terraform, Volodymyr TsapDive into DevOps | March, Building with Terraform, Volodymyr Tsap
Dive into DevOps | March, Building with Terraform, Volodymyr TsapProvectus
 
Automating Security in your IaC Pipeline
Automating Security in your IaC PipelineAutomating Security in your IaC Pipeline
Automating Security in your IaC PipelineAmazon Web Services
 
Go (con)figure - Making sense of .NET configuration
Go (con)figure - Making sense of .NET configurationGo (con)figure - Making sense of .NET configuration
Go (con)figure - Making sense of .NET configurationAlex Thissen
 
Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...
 Automating your Infrastructure Deployment with CloudFormation and OpsWorks –... Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...
Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...Amazon Web Services
 
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...Amazon Web Services
 
Spring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenSpring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenJoshua Long
 
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...DataStax Academy
 
How to build a Citrix infrastructure on AWS
How to build a Citrix infrastructure on AWSHow to build a Citrix infrastructure on AWS
How to build a Citrix infrastructure on AWSDenis Gundarev
 
Easy integration of Bluemix services with your applications
Easy integration of Bluemix services with your applicationsEasy integration of Bluemix services with your applications
Easy integration of Bluemix services with your applicationsJack-Junjie Cai
 
Born in the Cloud, Built like a Startup
Born in the Cloud, Built like a StartupBorn in the Cloud, Built like a Startup
Born in the Cloud, Built like a StartupAmazon Web Services
 
Priming Your Teams For Microservice Deployment to the Cloud
Priming Your Teams For Microservice Deployment to the CloudPriming Your Teams For Microservice Deployment to the Cloud
Priming Your Teams For Microservice Deployment to the CloudMatt Callanan
 
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdf
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdfdokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdf
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdfAppster1
 
dokumen.tips_rediscovering-spring-with-spring-boot1.pdf
dokumen.tips_rediscovering-spring-with-spring-boot1.pdfdokumen.tips_rediscovering-spring-with-spring-boot1.pdf
dokumen.tips_rediscovering-spring-with-spring-boot1.pdfAppster1
 
Decomposing the Monolith using modern-day .NET and a touch of microservices
Decomposing the Monolith using modern-day .NET and a touch of microservicesDecomposing the Monolith using modern-day .NET and a touch of microservices
Decomposing the Monolith using modern-day .NET and a touch of microservicesDennis Doomen
 

Semelhante a Learn Cloud-Native .NET: Core Configuration Fundamentals with Steeltoe (20)

Spring cloud config
Spring cloud configSpring cloud config
Spring cloud config
 
quickguide-einnovator-8-spring-cloud
quickguide-einnovator-8-spring-cloudquickguide-einnovator-8-spring-cloud
quickguide-einnovator-8-spring-cloud
 
.NET Core, ASP.NET Core Course, Session 8
.NET Core, ASP.NET Core Course, Session 8.NET Core, ASP.NET Core Course, Session 8
.NET Core, ASP.NET Core Course, Session 8
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetes
 
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...
Automating your Infrastructure Deployment with AWS CloudFormation and AWS Ops...
 
Dive into DevOps | March, Building with Terraform, Volodymyr Tsap
Dive into DevOps | March, Building with Terraform, Volodymyr TsapDive into DevOps | March, Building with Terraform, Volodymyr Tsap
Dive into DevOps | March, Building with Terraform, Volodymyr Tsap
 
Automating Security in your IaC Pipeline
Automating Security in your IaC PipelineAutomating Security in your IaC Pipeline
Automating Security in your IaC Pipeline
 
Go (con)figure - Making sense of .NET configuration
Go (con)figure - Making sense of .NET configurationGo (con)figure - Making sense of .NET configuration
Go (con)figure - Making sense of .NET configuration
 
Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...
 Automating your Infrastructure Deployment with CloudFormation and OpsWorks –... Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...
Automating your Infrastructure Deployment with CloudFormation and OpsWorks –...
 
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...
Integrating Infrastructure as Code into a Continuous Delivery Pipeline | AWS ...
 
What Is Happening At The Edge
What Is Happening At The EdgeWhat Is Happening At The Edge
What Is Happening At The Edge
 
Spring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenSpring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in Heaven
 
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...
Cassandra Summit 2014: Highly Scalable Web Application in the Cloud with Cass...
 
How to build a Citrix infrastructure on AWS
How to build a Citrix infrastructure on AWSHow to build a Citrix infrastructure on AWS
How to build a Citrix infrastructure on AWS
 
Easy integration of Bluemix services with your applications
Easy integration of Bluemix services with your applicationsEasy integration of Bluemix services with your applications
Easy integration of Bluemix services with your applications
 
Born in the Cloud, Built like a Startup
Born in the Cloud, Built like a StartupBorn in the Cloud, Built like a Startup
Born in the Cloud, Built like a Startup
 
Priming Your Teams For Microservice Deployment to the Cloud
Priming Your Teams For Microservice Deployment to the CloudPriming Your Teams For Microservice Deployment to the Cloud
Priming Your Teams For Microservice Deployment to the Cloud
 
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdf
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdfdokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdf
dokumen.tips_rediscovering-spring-with-spring-boot1 (1).pdf
 
dokumen.tips_rediscovering-spring-with-spring-boot1.pdf
dokumen.tips_rediscovering-spring-with-spring-boot1.pdfdokumen.tips_rediscovering-spring-with-spring-boot1.pdf
dokumen.tips_rediscovering-spring-with-spring-boot1.pdf
 
Decomposing the Monolith using modern-day .NET and a touch of microservices
Decomposing the Monolith using modern-day .NET and a touch of microservicesDecomposing the Monolith using modern-day .NET and a touch of microservices
Decomposing the Monolith using modern-day .NET and a touch of microservices
 

Mais de VMware Tanzu

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItVMware Tanzu
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023VMware Tanzu
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleVMware Tanzu
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023VMware Tanzu
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductVMware Tanzu
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready AppsVMware Tanzu
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And BeyondVMware Tanzu
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023VMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023VMware Tanzu
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptxVMware Tanzu
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchVMware Tanzu
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishVMware Tanzu
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVMware Tanzu
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - FrenchVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023VMware Tanzu
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootVMware Tanzu
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerVMware Tanzu
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeVMware Tanzu
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsVMware Tanzu
 

Mais de VMware Tanzu (20)

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About It
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at Scale
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a Product
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready Apps
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And Beyond
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptx
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - French
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - English
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - English
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - French
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software Engineer
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs Practice
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
 

Último

Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 

Último (20)

Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 

Learn Cloud-Native .NET: Core Configuration Fundamentals with Steeltoe

  • 1. .NET Core: Configuration Fundamentals David Dieruf - Pivotal July, 2019
  • 2. Let's Talk About... Cloud-native environment and goals Why we are here Designing config and environment variables Different patterns About .NET Core configuration Building config providers in WebHost and its hierarchy of values The options pattern Extending basic config with objects External configuration servers How they work and why you choose them Putting the pieces together Using Steeltoe and Spring Config to reach cloud-native goals
  • 3. Environment: Local Network Services: DB, Cache, SMB Environment: Stage Environment: Prod Team Foundation Server (CI/CD): Git, Build, Release My-App Network Services: DB, Cache, SMB Network Services: DB, Cache, SMB My-App My-App - One build - Test once (for all environments) - Parity between environments - Automation My-App My-App public void ConfigureServices(IServiceCollection services) { String connString = Environment.GetEnvironmentVariable("conn_string"); services.AddDbContext<MyContext>(options => options.UseSqlServer(connString)); }
  • 4. Environment variables in the cloud How is the value set? Do you have to manually update the value per instance, or script the action? How easy is promotion? Do you have to recompile to move between environments? Does your build pipeline manipulate settings? Do you have a history of changes? Do you know when a value was set and by who? Atomic value in the cloud Per app instance App can not run without a value Agnostic to its platform or IaaS (portable)
  • 5. Appsettings.json ● [Good] External to the compiled application ● [Good] No recompilation needed ● [Challenge] Have to change at every instance Internal Class Command Line ● [Good] Secure information in compiled bits ● [Challenge] Hard coded values in app ● [Challenge] Can not change without recompiling ● [Good] External to the compiled application ● [Challenge] Have to change at every instance ● [Challenge] Lost values because no source check-in (Manual) Environment Variables Popular Configuration Design ● [Good] External to the compiled application ● [Good] Application compiled once and promoted through environment ● [Challenge] Have to change at every host class MyClass { string connString = "xxxx" } { "ConnectionStrings": { "a-database": "xxxxx" } } C: dotnet run my-app ` --conn "xxxx" ` --something "yyyyy" string connString = Environment.GetEnvironmentVari able("my-conn")
  • 7. Using Default WebHost Loading configuration into your app public static IWebHostBuilder CreateWebHostBuilder(string[] args) => WebHost.CreateDefaultBuilder(args) .UseStartup<Startup>(); - use Kestrel as the web server and configure it using the application's configuration providers - set the ContentRootPath to the result of GetCurrentDirectory() - load IConfiguration from 'appsettings.json' and 'appsettings.[EnvironmentName].json' - load IConfiguration from User Secrets when EnvironmentName is 'Development' using the entry assembly - load IConfiguration from environment variables - load IConfiguration from supplied command line args - configure the ILoggerFactory to log to the console and debug output - enable IIS integration program.cs WebHost.CreateDefaultBuilder(args)
  • 8. Build your own WebHost Loading configuration into your app public static IWebHost BuildWebHost(string[] args) { var builder = new WebHostBuilder() .UseKestrel() .UseContentRoot(Directory.GetCurrentDirectory()) .ConfigureAppConfiguration((hostingContext, config) => { var env = hostingContext.HostingEnvironment; config.AddJsonFile("appsettings.json") .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); config.AddEnvironmentVariables(); config.AddCommandLine(args); }) .UseIISIntegration() .UseStartup<Startup>(); return builder.Build(); } program.cs - Options manipulate how configuration values are overwritten - Options to [not] include other configuration providers, like custom external config server provider var builder = new WebHostBuilder()
  • 9. Config value hierarchy Overwrite values based on environment public static IWebHost BuildWebHost(string[] args) { var builder = new WebHostBuilder() ... .ConfigureAppConfiguration((hostingContext, config) => { var env = hostingContext.HostingEnvironment; config.AddJsonFile("appsettings.json") .AddJsonFile($"appsettings.{env.EnvironmentName}.json"); config.AddEnvironmentVariables(); config.AddCommandLine(args); }) ... 1. Load values from appsettings.json 2. (if provided) Load values from environment specific appsettings.{env}.json 3. (if present) Load values from environment variables 4. (if present) Load values provided when app was started config.AddJsonFile("appsettings.json") .AddJsonFile($"appsettings.{env.EnvironmentName}.json"); config.AddEnvironmentVariables(); config.AddCommandLine(args);
  • 10. { "my_val": "something" } Example Value Overwriting 1. config.AddJsonFile("appsettings.json") { "my_val": "another" } 2. .AddJsonFile("appsettings.staging.json") PS c: $env:my_val = "yet another" 3. config.AddEnvironmentVariables() PS c: dotnet run my-app --my_val "again another" 4. config.AddCommandLine(args) my_val == “again another”
  • 11. Configuration Providers Supported providers for configuration of ASP.NET core app Provider Provides configuration from… Azure Key Vault Configuration Provider (Security topics) Azure Key Vault Azure App Configuration Provider (Azure documentation) Azure App Configuration Command-line Configuration Provider Command-line parameters Custom configuration provider Custom source Environment Variables Configuration Provider Environment variables File Configuration Provider Files (INI, JSON, XML) Key-per-file Configuration Provider Directory files Memory Configuration Provider In-memory collections User secrets (Secret Manager) (Security topics) File in the user profile directory
  • 12. Consuming Values Using Microsoft.Extensions.Configuration public class ValuesController : Controller{ private readonly IConfiguration _config; public ValuesController(IConfiguration config){ _config = config; } [HttpGet] public ActionResult<string> Get(){ string val = _config.GetValue<string>("my_val"); return val; } } - No consideration for handler type(s) - Simple key:value store - Can be complex type ValuesController.cs
  • 14. Options Pattern Using Microsoft.Extensions.Configuration.Options { "section0": { "key0": "value", "key1": "value" }, "section1": { "key0": "value", "key1": "value" } } public void ConfigureServices(IServiceCollection services) { services.AddOptions(); services.Configure<SectionZeroOptions>(Configuration.GetSection("section0")); ... } public class SectionZeroOptions { public string key0 {get;set;} public string key1 { get; set; } } public class MyService : IMyService { private IOptions<SectionZeroOptions> _SectionZeroOptions; public MyService(IOptions<SectionZeroOptions> sectionZeroOptions) { _SectionZeroOptions = sectionZeroOptions; } public string DoSomething(){ string key0 = _SectionZeroOptions.Value.key0; string key1 = _SectionZeroOptions.Value.key1; return key0; } } 1. appsettings.json values 2. Matching class to json 3. Enable the Options configuration 4. Consume values { "section0": { "key0": "value", "key1": "value" }, "section1": { "key0": "value", "key1": "value" } } public class SectionZeroOptions { public string key0 {get;set;} public string key1 { get; set; } } public void ConfigureServices(IServiceCollection services) { services.AddOptions(); services.Configure<SectionZeroOptions>(Configuration.GetSection("section0")); ... } public class MyService : IMyService { private IOptions<SectionZeroOptions> _SectionZeroOptions; public MyService(IOptions<SectionZeroOptions> sectionZeroOptions) { _SectionZeroOptions = sectionZeroOptions; } public string DoSomething(){ string key0 = _SectionZeroOptions.Value.key0; string key1 = _SectionZeroOptions.Value.key1; return key0; } }
  • 15. Business Case using options pattern You have an api that is responsible for approving loans. There are business rules within the app that need to be applied, to decide approval. One of those rules compares the loan amount being asked for, to a max loan amount the business is willing to approve. The max amount changes throughout the year based on other events. Place the max approval amount (integer) in an external config and give yourself the flexibility to change values at any moment, with no downtime.
  • 16. External Configuration Server Custom configuration provider
  • 17. About Config Server At boot time… ➔ Platform puts values in environment variables ➔ Client looks for server ➔ Client gets config by NAME ➔ Config organised by PROFILE At runtime... ➔ Config can be refreshed live ➔ Call /actuator/refresh ➔ Values get reloaded ➔ No need for restart!
  • 18. Environment: Stage Environment: ProdEnvironment: Local Network Services: DB, Cache, SMB Team Foundation Server (CI/CD): Git, Build, Release Network Services: DB, Cache, SMB Network Services: DB, Cache, SMB Config Server: development.yml, staging.yml, production.yml string connString = Environment.GetEnvironmentVariable("conn_string"); string configUri = Environment.GetEnvironmentVariable("config_uri");
  • 19. Simplicity vs Flexibility External configuration can be challenging in itself It offers so much design options that things can get out of hand quickly. Use the domain around you to decide how far to go. Config First Approach Don’t hold anything in your appsettings.json, only a pointer to the config server. Everything is filled from there.
  • 20. Steeltoe and Spring Config Putting the pieces together
  • 21. 2. Set the application Name (in appsettings.json)... Setup Configuration Client: .NET / Steeltoe / Spring Config 4. Include the custom config provider... 1: Add the dependencies... (Steeltoe for Pivotal Spring Cloud Config Client) 3. Add your external configuration (in Git)... "spring": { "application": { "name": "loan-application-service" }, "cloud": { "config": { "uri": "http://10.0.7.254:8888", "validate_certificates": false, "fail_fast": true ... <PackageReference Include="Steeltoe.Extensions.Configuration.ConfigServerCore" ... /> public void ConfigureServices(IServiceCollection services){ services.AddOptions(); services.Configure<Services.SomeValuesOptions> (Configuration.GetSection("SomeValues")); services.AddMvc(); ... } WebHost.CreateDefaultBuilder(args) .ConfigureAppConfiguration((hostingContext, config) =>{ ILoggerFactory fac = GetLoggerFactory(hostingContext.HostingEnvironment); var env = hostingContext.HostingEnvironment; config.AddConfigServer(env, fac); }) ... public class SomeValuesOptions { public string scheme { get; set; } public string address { get; set; } } program.cs startup.cs config options pattern Logging: IncludeScopes: false Debug: LogLevel: Default: Information SomeValues: scheme: https address: www.pivotal.io 5. Retrieve values and map to class... <PackageReference Include="Steeltoe.Extensions.Configuration.ConfigServerCore" ... /> "spring": { "application": { "name": "loan-application-service" }, "cloud": { "config": { "uri": "http://127.0.0.1:8888", "validate_certificates": false, "fail_fast": true ... Logging: IncludeScopes: false Debug: LogLevel: Default: Information SomeValues: scheme: https address: www.pivotal.io WebHost.CreateDefaultBuilder(args) .ConfigureAppConfiguration((hostingContext, config) =>{ ILoggerFactory fac = GetLoggerFactory(hostingContext.HostingEnvironment); var env = hostingContext.HostingEnvironment; config.AddConfigServer(env, fac); }) ... public void ConfigureServices(IServiceCollection services){ services.AddOptions(); services.Configure<Services.SomeValuesOptions> (Configuration.GetSection("SomeValues")); services.AddMvc(); ... } public class SomeValuesOptions { public string scheme { get; set; } public string address { get; set; } } "name": "loan-application-service" config.AddConfigServer(env, fac); "uri": "http://127.0.0.1:8888"
  • 22. © Copyright 2019 Pivotal Software, Inc. All rights Reserved. Learn More. Become a cloud-native .NET rock star https://springoneplatform.io/2019/training Pivotal Platform Acceleration Lab for Developers (.NET) Experience best practices building cloud-native applications in a hands-on setting with Pivotal educators and consultants. The program is focused on enabling customers and partners through “doing it” rather than “talking about it”. https://pivotal.io/platform-acceleration-lab
  • 23. © Copyright 2019 Pivotal Software, Inc. All rights Reserved. Questions? Thank you
  • 24. Refreshing Values - Optionally provide an environment specific json config Startup.cs public static IWebHost BuildWebHost(string[] args) { var builder = new WebHostBuilder() ... .ConfigureAppConfiguration((hostingContext, config) => { var env = hostingContext.HostingEnvironment; config.AddJsonFile("appsettings.json", reloadOnChange: true) .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true, reloadOnChange: true); config.AddEnvironmentVariables(); config.AddCommandLine(args); }) ...
  • 25. Optional providers - Optionally provide an environment specific json config Startup.cs public static IWebHost BuildWebHost(string[] args) { var builder = new WebHostBuilder() ... .ConfigureAppConfiguration((hostingContext, config) => { var env = hostingContext.HostingEnvironment; config.AddJsonFile("appsettings.json") .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); config.AddEnvironmentVariables(); config.AddCommandLine(args); }) ...