Skip to content

Refactor provider config related code

Pea Nut requested to merge refactor-config into main

This is just a refactoring MR. No changes in logic are intened. For me the code is now much nice to read/understand. I came to this as I wanted to move the ProviderConfig struct to the config package, but then I had a circular dependency.

There are things I still want to improve, but we need to agree/understand before, see #803.

Changes

Rename and document structs

  • Providers -> ProvidersJson
  • InitOpts -> RuntimeParameters
  • ProviderOpts -> ProviderConfig

The ProviderConfig struct was moved to config package (required for the provider agnostic client)

functions InitOptsFromJSON -> GetProviderConfiguration ConfigureProvider was moved to config package

Sorry for the big commit. But renaming and moving to a different file makes it hard to seperate afterwards.

Merge request reports