terraform/helper/resource
Martin Atkins 549aede792 Remove terraform.ResourceProvider, use providercache.Installer instead
Back when we first introduced provider versioning in Terraform 0.10, we
did the provider version resolution in terraform.NewContext because we
weren't sure yet how exactly our versioning model was going to play out
(whether different versions could be selected per provider configuration,
for example) and because we were building around the limitations of our
existing filesystem-based plugin discovery model.

However, the new installer codepath is new able to do all of the
selections up front during installation, so we don't need such a heavy
inversion of control abstraction to get this done: the command package can
select the exact provider versions and pass their factories directly
to terraform.NewContext as a simple static map.

The result of this commit is that CLI commands other than "init" are now
able to consume the local cache directory and selections produced by the
installation process in "terraform init", passing all of the selected
providers down to the terraform.NewContext function for use in
implementing the main operations.

This commit is just enough to get the providers passing into the
terraform.Context. There's still plenty more to do here, including to
repair all of the tests this change has additionally broken.
2020-04-06 09:24:23 -07:00
..
error.go helper/resource: Add retries to err message 2017-01-20 11:09:04 -08:00
grpc_test_provider.go Stop grpc server when running ACC tests 2019-04-29 14:14:04 -04:00
id.go Export a const for validation methods 2018-03-10 12:40:37 -05:00
id_test.go Make failure message more explicit 2018-03-10 21:53:54 -05:00
map.go ResourceDiff => InstanceDiff 2014-09-17 16:33:24 -07:00
map_test.go prune NewResourceConfig and update tests 2019-08-05 22:08:03 -04:00
resource.go ResourceDiff => InstanceDiff 2014-09-17 16:33:24 -07:00
state.go grammatical updates to comments and docs (#20195) 2019-03-21 14:05:41 -07:00
state_shim.go fixup states.Resource change throughout packages 2020-03-16 16:50:48 -04:00
state_shim_test.go finish provider ModuleInstance replacement 2020-03-11 14:19:52 -04:00
state_test.go add test for proper cancelation 2017-04-19 18:07:00 -04:00
testing.go Remove terraform.ResourceProvider, use providercache.Installer instead 2020-04-06 09:24:23 -07:00
testing_config.go move hcl2shim package to configs 2019-08-06 19:58:58 -04:00
testing_import_state.go Mildwonkey/ps import (#24412) 2020-03-20 08:15:29 -04:00
testing_import_state_test.go skip resource tests for now 2018-10-31 14:17:23 -04:00
testing_test.go providers: use addrs.Provider as map keys for provider.Factory (#23548) 2019-12-04 11:30:20 -05:00
wait.go Fixing small typo in resource/wait.go 2018-03-14 17:33:03 +01:00
wait_test.go fix tests affected by refreshGracePeriod 2017-04-19 18:07:00 -04:00