Skip to content

ref: Create static & mutable Config providers so some values can be overridden in memory#263

Merged
ryan953 merged 1 commit intomainfrom
ryan953/statsful-config
Jun 16, 2025
Merged

ref: Create static & mutable Config providers so some values can be overridden in memory#263
ryan953 merged 1 commit intomainfrom
ryan953/statsful-config

Conversation

@ryan953
Copy link
Copy Markdown
Member

@ryan953 ryan953 commented Jun 16, 2025

We want to be able to override stuff like placement, but some things like sentryOrigin cannot be overridden because that would cause the whole <ApiProxyContextProvider> to re-connect and be a weird experience.

So we have the <StaticConfigProvider> which wraps the whole app and nothing inside it can be changed.
Then down below we have <MutableConfigProvider> where the fields can be changed. If something below here depends on a field then it will be updated to use the new value. This means that fields like placement can be updated without any problems, other fields like debug and sentryOrigin can be updated, but nothing lower really uses them. This is a limitation that maybe we can address in a followup iteration.

It's important is not to re-render <ApiProxyContextProvider> or the other providers.

@ryan953 ryan953 requested a review from a team as a code owner June 16, 2025 00:01
@ryan953 ryan953 merged commit 6fadf3d into main Jun 16, 2025
6 checks passed
@ryan953 ryan953 deleted the ryan953/statsful-config branch June 16, 2025 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant