Can common config be written in "GlobalConfiguration"
See original GitHub issueExpected Behavior / New Feature
The documentation states: The Global configuration is a bit hacky and allows overrides of Route specific settings. It’s useful if you don’t want to manage lots of Route specific settings.
Based on this, my understanding is that if the following few configurations are common for all the entries in ReRoutes
, then the following way of putting it together should work:
"GlobalConfiguration": {
"DownstreamScheme": "https",
"DangerousAcceptAnyServerCertificateValidator": true,
"QoSOptions": {
"TimeoutValue": 60000
}
}
Actual Behavior / Motivation for New Feature
It is not working at my end. Looks like one of the possibilities:
- My understanding is wrong: Then documentation should be made more explanatory.
- My understanding is right: Ocelot may have some problem. Since this configuration otherwise (if I repeat these in each entry in
ReRoutes
) has been working for 20 services that my Ocelot instance is serving.
In either case, please help!
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:5
Top Results From Across the Web
Proper implementation of global configuration - c++
The way I used solve this is to put the variables in a separate global namespace, which is in a header file named...
Read more >Using the Global Configuration Object
Setting global configuration with AWS.Config is often easier to get started, but service-level configuration can provide more control over individual services.
Read more >Configuration in ASP.NET Core
Learn how to use the Configuration API to configure AppSettings in an ASP.NET Core app.
Read more >Configuration — IDAES v2.0.0
A global configuration file won't exist unless a user creates one. The default configuration above can be used as a start.
Read more >Configuring Jest
It is recommended to define the configuration in a dedicated JavaScript, TypeScript or JSON file. The file will be discovered automatically, if it...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Looks like
GlobalConfiguration
section is limited for specific scenarios. Check this file to see what can be configured viaGlobalConfiguration
. But you can extend it withPostConfigure
trick. Check my answer on SO for example.Any updates on this? This would be a very nice feature to have…