Using Parameter Context inheritance to combine Parameters

You can use Parameter Context inheritance to combine Parameters from different Parameter Providers within one Parameter Context.

It is good practice to create separate Parameter Providers for different sources, and then compose the Parameter Contexts through inheritance. This allows sensitive parameters to originate from a secrets manager, like HashiCorp Vault, and non-sensitive parameters to originate from other sources like Environment Variables or the file system. In the following simple example, the EnvironmentVariableParameterProvider contains non-sensitive Parameters and the FileParameterProvider contains sensitive Parameters. Both Parameter Providers are added as inherited contexts to a new Parameter Context, “Parameters”. For details on inherited Parameter Contexts, see What is Parameter Context inheritance?.

The new Parameter Context inherits Parameters from both sources: