File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ func bridgedProvider(prov *providerbuilder.Provider) info.Provider {
55
55
Name : prov .TypeName ,
56
56
Version : "0.0.1" ,
57
57
MetadataInfo : & tfbridge0.MetadataInfo {},
58
+ EnableAccurateBridgePreview : true ,
58
59
}
59
60
60
61
provider .MustComputeTokens (tokens .SingleModule (prov .TypeName , "index" , tokens .MakeStandard (prov .TypeName )))
Original file line number Diff line number Diff line change @@ -483,6 +483,12 @@ func MakeDetailedDiffV2(
483
483
ps map [string ]* SchemaInfo ,
484
484
priorProps , props , newInputs resource.PropertyMap ,
485
485
) map [string ]* pulumirpc.PropertyDiff {
486
+ // Strip secrets and outputs from the properties before calculating the diff.
487
+ // This allows the rest of the algorithm to focus on the actual changes and not
488
+ // have to deal with the extra noise.
489
+ // This is safe to do here because the detailed diff we return to the engine
490
+ // is only represented by paths to the values and not the values themselves.
491
+ // The engine will then takes care of masking secrets.
486
492
stripSecretsAndOutputs := func (props resource.PropertyMap ) resource.PropertyMap {
487
493
propsVal := propertyvalue .RemoveSecretsAndOutputs (resource .NewProperty (props ))
488
494
return propsVal .ObjectValue ()
You can’t perform that action at this time.
0 commit comments