opentofu/internal/tofu
Christian Mesh 326ae112f2 Introduce plugin managers
Provider and Provisioner Managers encapsulate all of
the logic nessesary to start, manage, and stop plugins.

They also have the advantage of sharing a schema cache between
managers started in different parts of the application.

Signed-off-by: Christian Mesh <christianmesh1@gmail.com>
2026-01-15 10:50:29 -05:00
..
testdata Retain resource instances with a new lifecycle argument - destroy (#3409) 2025-12-04 18:49:57 +04:00
bench_many_instances_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
context_apply.go Retaining resources during destruction - New flag -suppress-forget-errors (#3588) 2025-12-16 15:41:03 +04:00
context_apply2_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_apply_checks_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_apply_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
context_eval.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
context_eval_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_fixtures_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_functions.go lang: Data methods now take context.Context 2025-06-18 07:26:17 -07:00
context_functions_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_import.go Use root context when evaluating import.id expressions (#3567) 2025-12-10 17:54:18 +02:00
context_import_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_input.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
context_input_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_plan.go tracing: Centralize our OpenTelemetry package imports 2025-10-30 13:27:10 -07:00
context_plan2_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_plan_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_plugins.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
context_plugins_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_refresh.go tofu: Context.Refresh now takes a context.Context 2024-11-19 10:15:21 -08:00
context_refresh_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_validate.go Import block ID validation (#2973) 2025-07-17 22:54:34 +04:00
context_validate_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
context_walk.go tofu: context.Context plumbed into the graph walk driver 2024-11-19 10:15:21 -08:00
deprecation_level.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
deprecation_level_test.go Add new CLI arg to control what warnings should be shown for deprecated outputs/variables (#2705) 2025-05-08 17:01:40 +03:00
deprecationwarninglevel_string.go go.mod: Upgrade various golang.org/x/* dependencies 2025-10-10 08:23:54 -07:00
eval_conditions.go Address ephemeralasnull comments/TODOs (#3169) 2025-09-10 07:45:23 -04:00
eval_context.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
eval_context_builtin.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
eval_context_builtin_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
eval_context_mock.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
eval_count_test.go lang: Data methods now take context.Context 2025-06-18 07:26:17 -07:00
eval_expansion.go Add conditional enabled field on managed and data resources (#3042) 2025-09-26 08:44:39 -03:00
eval_import.go Fix import validation with resource reference (unknown value) (#3513) 2025-11-19 09:58:35 -05:00
eval_import_test.go Ephemeral variables (#3108) 2025-09-10 07:45:23 -04:00
eval_provider.go Directly link provider instances via ResovedProvider 2025-12-19 09:20:08 -05:00
eval_provider_test.go lang: Data methods now take context.Context 2025-06-18 07:26:17 -07:00
eval_variable.go Address ephemeralasnull comments/TODOs (#3169) 2025-09-10 07:45:23 -04:00
eval_variable_test.go Address ephemeralasnull comments/TODOs (#3169) 2025-09-10 07:45:23 -04:00
evaluate.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
evaluate_test.go bug fix for Instance module without resources/outputs was not reporting correct length. (#3469) 2025-12-01 09:15:10 -05:00
evaluate_triggers.go Another batch of minor typos (#1953) 2024-09-09 07:51:39 -04:00
evaluate_triggers_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
evaluate_valid.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
evaluate_valid_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
execute.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
features.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
graph.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
graph_builder.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
graph_builder_apply.go feat: allow calling functions from unconfigured providers when no resources are referenced (#3118) 2025-08-22 14:50:17 -03:00
graph_builder_apply_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
graph_builder_eval.go feat: allow calling functions from unconfigured providers when no resources are referenced (#3118) 2025-08-22 14:50:17 -03:00
graph_builder_plan.go feat: allow calling functions from unconfigured providers when no resources are referenced (#3118) 2025-08-22 14:50:17 -03:00
graph_builder_plan_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
graph_builder_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
graph_dot.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
graph_dot_test.go Error handling fixes (#1816) 2024-07-15 11:58:43 +02:00
graph_interface_subgraph.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
graph_test.go Another batch of minor typos (#1953) 2024-09-09 07:51:39 -04:00
graph_walk.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
graph_walk_context.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
graph_walk_operation.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
graph_walk_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
hook.go Reduce calls to state DeepCopy() by half during apply (#3011) 2025-08-26 14:36:01 -04:00
hook_mock.go Reduce calls to state DeepCopy() by half during apply (#3011) 2025-08-26 14:36:01 -04:00
hook_stop.go Reduce calls to state DeepCopy() by half during apply (#3011) 2025-08-26 14:36:01 -04:00
hook_stop_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
hook_test.go Reduce calls to state DeepCopy() by half during apply (#3011) 2025-08-26 14:36:01 -04:00
instance_expanders.go Rename the interface graphNodeExpandsInstances (#3237) 2025-09-04 20:19:20 +04:00
marks.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
marks_test.go refactor a few more places for proper sensitive marks treatment (#2673) 2025-04-18 17:35:06 +03:00
node_check.go lang: Data methods now take context.Context 2025-06-18 07:26:17 -07:00
node_data_destroy.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_data_destroy_test.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_external_reference.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
node_local.go Rename the interface graphNodeExpandsInstances (#3237) 2025-09-04 20:19:20 +04:00
node_local_test.go hcl2shim: Split out legacy subset 2025-07-10 08:13:25 -07:00
node_module_expand.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_module_expand_test.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_module_variable.go lint: Include more source context in unused attribute diagnostics 2025-09-26 09:08:31 -07:00
node_module_variable_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
node_output.go Ephemeral outputs (#3123) 2025-09-10 07:45:23 -04:00
node_output_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
node_provider.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_provider_abstract.go Update comments and panics -> errors 2026-01-26 07:44:52 -05:00
node_provider_eval.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_provider_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_abstract.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
node_resource_abstract_instance.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_abstract_instance_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_abstract_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_apply.go Rename the interface graphNodeExpandsInstances (#3237) 2025-09-04 20:19:20 +04:00
node_resource_apply_instance.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
node_resource_apply_test.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_resource_closeable.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
node_resource_deposed.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
node_resource_deposed_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_destroy.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
node_resource_forget.go Reduce calls to state DeepCopy() by half during apply (#3011) 2025-08-26 14:36:01 -04:00
node_resource_import.go Allow provider nodes to return errors when fetching instances 2026-01-23 11:41:54 -05:00
node_resource_plan.go Rename the interface graphNodeExpandsInstances (#3237) 2025-09-04 20:19:20 +04:00
node_resource_plan_destroy.go Retaining resource during destruction - action and reason marshalling extension (#3569) 2025-12-12 15:16:54 +04:00
node_resource_plan_instance.go providers: Remove explicit handling of "deferred" signal from providers 2025-12-16 13:09:32 -08:00
node_resource_plan_orphan.go Retaining resource during destruction - action and reason marshalling extension (#3569) 2025-12-12 15:16:54 +04:00
node_resource_plan_orphan_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_validate.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_resource_validate_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
node_root_variable.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_root_variable_test.go tofu: GraphNodeExecutable interface takes context.Context 2025-05-02 08:46:47 -07:00
node_value.go Validations should only be run during non-destroy operations (#3131) 2025-08-19 07:31:34 -04:00
node_variable_reference.go Ephemeral variables (#3108) 2025-09-10 07:45:23 -04:00
opentf_test.go Add helper for building ResolvedProvider{} in test 2026-01-26 08:08:25 -05:00
phasestate_string.go go.mod: Upgrade various golang.org/x/* dependencies 2025-10-10 08:23:54 -07:00
provider_for_test_framework.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
provider_for_test_framework_test.go Consolidate provider resource mocking and overrides (#3547) 2025-12-15 08:52:10 -05:00
provider_mock.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
provisioner_mock.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
provisioner_mock_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
reduce_plan.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
reduce_plan_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
resource_provider_mock_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
schemas.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
schemas_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
skip_destroy_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
test_context.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
test_context_test.go Introduce plugins.Library 2026-01-26 09:20:04 -05:00
transform.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_attach_config_provider.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
transform_attach_config_provider_meta.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
transform_attach_config_resource.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_attach_config_resource_test.go Fix lint issues in internal/tofu (#2790) 2025-05-12 07:28:35 -04:00
transform_attach_schema.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
transform_attach_state.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_check.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_check_starter.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_closeable_resource.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_config.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_config_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_destroy_cbd.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_destroy_cbd_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_destroy_edge.go tofu: GraphNodeDestroyer can now have references 2025-11-18 06:59:35 -08:00
transform_destroy_edge_test.go Validations should only be run during non-destroy operations (#3131) 2025-08-19 07:31:34 -04:00
transform_diff.go Retain resource instances with a new lifecycle argument - destroy (#3409) 2025-12-04 18:49:57 +04:00
transform_diff_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_expand.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
transform_external_reference.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_import_state_test.go Introduce plugin managers 2026-01-15 10:50:29 -05:00
transform_local.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_module_expansion.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_module_expansion_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_module_variable.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_module_variable_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_orphan_count.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_orphan_count_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_orphan_output.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_orphan_resource.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_orphan_resource_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_output.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_provider.go Update comments and panics -> errors 2026-01-26 07:44:52 -05:00
transform_provider_test.go Directly link provider instances via ResovedProvider 2025-12-19 09:20:08 -05:00
transform_provisioner.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
transform_reference.go tofu: GraphNodeDestroyer can now have references 2025-11-18 06:59:35 -08:00
transform_reference_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
transform_removed_modules.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_resource_count.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_root.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_root_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_state.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_targets.go Validations should only be run during non-destroy operations (#3131) 2025-08-19 07:31:34 -04:00
transform_targets_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_transitive_reduction.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_transitive_reduction_test.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
transform_variable.go tofu: GraphTransformer.Transform takes context.Context 2025-05-08 07:16:09 -07:00
ui_input.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_input_mock.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_input_prefix.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_input_prefix_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_input_suffix.go Ephemeral variables (#3108) 2025-09-10 07:45:23 -04:00
ui_input_suffix_test.go Ephemeral variables (#3108) 2025-09-10 07:45:23 -04:00
ui_output.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_output_callback.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_output_callback_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_output_provisioner.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
ui_output_provisioner_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
update_state_hook.go Fix nil entry in state resource instance map from state hook (#3478) 2025-11-06 16:28:36 -05:00
update_state_hook_test.go Fix nil entry in state resource instance map from state hook (#3478) 2025-11-06 16:28:36 -05:00
upgrade_resource_state.go providers: Remove explicit handling of "deferred" signal from providers 2025-12-16 13:09:32 -08:00
upgrade_resource_state_test.go Moved for different types (#2370) 2025-02-05 15:14:19 +04:00
util.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
util_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
validate_selfref.go Fix typos (#1905) 2024-08-29 13:20:33 -04:00
validate_selfref_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
valuesourcetype_string.go Rename opentf package to tofu (#466) 2023-09-20 15:16:53 +03:00
variables.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
variables_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
version_required.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
walkoperation_string.go go.mod: Upgrade various golang.org/x/* dependencies 2025-10-10 08:23:54 -07:00