#651 Merge custom JSON properties across multiple ocelot.X.json configuration files using Newtonsoft's JToken merge functionality#1183
Conversation
4eb4482 to
9ec4b8d
Compare
|
Congrats, @jlukawska ! 🎉 We can go with code review now... |
|
@RaynaldM @wast |
There was a problem hiding this comment.
@jlukawska
Could you fix the issues please?
How to read CustomStrategyProperty value of the route in run-time?
|
|
||
| fileConfiguration.Aggregates.AddRange(config.Aggregates); | ||
| fileConfiguration.Routes.AddRange(config.Routes); | ||
| MergeConfig(fileConfiguration, config, isGlobal); |
There was a problem hiding this comment.
🆗 Merged config JSON goes to primaryConfigFile. And it will be serialized to ocelot.json file.
And the primary config will be attached to IConfigurationBuilder object by AddJsonFile method.
Could you show me a case how can I read this custom property inside of extension-methods for IConfigurationBuilder interface?
|
@nurhat @jlukawska User case 1Change behavior of PollyQoSProviderGiven, I wish to override behavior of the Quality of Service feature by changes in PollyQoSProvider and/or AddPolly and/or PollyCircuitBreakingDelegatingHandler classes. Question:
|
04debe6 to
7f61d01
Compare
8c3ec5a to
1b2198c
Compare
|
@jlukawska commented on May 16, 2024
I've rebased the feature branch today and addressed the failed tests. The entire code appears to be in good shape. I will provide my final code review later, after receiving feedback from the team. However, the current acceptance test confirms the successful merging of JSON. More tests are necessary, and it seems they will be essential for the upcoming C# helpers that will be reused in the actual code of middlewares, similar to how the Metadata-helpers function.
Indeed, the question of whether this PR would be beneficial to anyone is quite pertinent, especially after the introduction of the Route Metadata feature (aka Metadata). While some developers may not favor storing additional route data in the
Mr. @nurhat didn't even reply to me, which suggests he might have used a work account linked to a corporate email. Developers often change jobs and employers, along with their work emails. Regardless, I'll assume the role of the author. 😉 |
ocelot.X.json configuration files using Newtonsoft's JToken merge functionality
SuccessorsThis PR must be merged first❗ |
c216cdf to
b458f0f
Compare
Ready for code review ✔️
|
Closes #651
Proposed Changes