From 73680546a8c43a20d76671372163eca07412f2cb Mon Sep 17 00:00:00 2001 From: James Bardin Date: Wed, 4 Nov 2020 13:02:04 -0500 Subject: [PATCH] udpate PrepareProviderConfig docs Indicate that the PreparedConfig is not used by core. --- providers/provider.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/providers/provider.go b/providers/provider.go index 2d9db44bb..24f06a6cb 100644 --- a/providers/provider.go +++ b/providers/provider.go @@ -14,8 +14,10 @@ type Interface interface { // GetSchema returns the complete schema for the provider. GetSchema() GetSchemaResponse - // PrepareProviderConfig allows the provider to validate the configuration - // values, and set or override any values with defaults. + // PrepareProviderConfig allows the provider to validate the configuration. + // The PrepareProviderConfigResponse.PreparedConfig field is unused. The + // final configuration is not stored in the state, and any modifications + // that need to be made must be made during the Configure method call. PrepareProviderConfig(PrepareProviderConfigRequest) PrepareProviderConfigResponse // ValidateResourceTypeConfig allows the provider to validate the resource @@ -99,7 +101,7 @@ type PrepareProviderConfigRequest struct { } type PrepareProviderConfigResponse struct { - // PreparedConfig is the configuration as prepared by the provider. + // PreparedConfig is unused. PreparedConfig cty.Value // Diagnostics contains any warnings or errors from the method call. Diagnostics tfdiags.Diagnostics