opentofu/plans
Martin Atkins 88e76fa9ef configs/configschema: Introduce the NestingGroup mode for blocks
In study of existing providers we've found a pattern we werent previously
accounting for of using a nested block type to represent a group of
arguments that relate to a particular feature that is always enabled but
where it improves configuration readability to group all of its settings
together in a nested block.

The existing NestingSingle was not a good fit for this because it is
designed under the assumption that the presence or absence of the block
has some significance in enabling or disabling the relevant feature, and
so for these always-active cases we'd generate a misleading plan where
the settings for the feature appear totally absent, rather than showing
the default values that will be selected.

NestingGroup is, therefore, a slight variation of NestingSingle where
presence vs. absence of the block is not distinguishable (it's never null)
and instead its contents are treated as unset when the block is absent.
This then in turn causes any default values associated with the nested
arguments to be honored and displayed in the plan whenever the block is
not explicitly configured.

The current SDK cannot activate this mode, but that's okay because its
"legacy type system" opt-out flag allows it to force a block to be
processed in this way anyway. We're adding this now so that we can
introduce the feature in a future SDK without causing a breaking change
to the protocol, since the set of possible block nesting modes is not
extensible.
2019-04-10 14:53:52 -07:00
..
internal/planproto build: Take protoc out of the "go generate" path 2018-10-18 10:39:20 -07:00
objchange configs/configschema: Introduce the NestingGroup mode for blocks 2019-04-10 14:53:52 -07:00
planfile test for destroy plan round trip 2018-12-20 15:11:08 -05:00
action_string.go plans: Regenerate Action.String for new action values 2018-10-16 19:14:11 -07:00
action.go core: Handle forced-create_before_destroy during the plan walk 2018-10-16 19:14:11 -07:00
changes_src.go don't attempt to decode empty changes values 2018-12-20 13:06:53 -05:00
changes_state.go plans: New package for in-memory plan models 2018-10-16 18:50:29 -07:00
changes_sync.go core: Allow planned output changes to be updated during apply 2018-11-05 16:02:45 -08:00
changes.go plans: OutputChange.Encode must preserve Addr field 2018-11-01 17:33:10 -07:00
doc.go plans: New package for in-memory plan models 2018-10-16 18:50:29 -07:00
dynamic_value_test.go plans: New package for in-memory plan models 2018-10-16 18:50:29 -07:00
dynamic_value.go don't convert empty DynamicValue to nil 2018-12-20 10:28:26 -05:00
plan_test.go make Changes.Empty() not count NoOps 2018-10-16 19:14:11 -07:00
plan.go terraform: Ugly huge change to weave in new State and Plan types 2018-10-16 19:11:09 -07:00