pulumi/sdk
Abhinav Gupta 0bf1b8c860
sdk/go: Don't drop Dependencies in ResourceOptions snapshot for MLCs
We recently added a new API, NewResourceOptions to build a preview
of a set of resource options.

    func NewResourceOptions(...ResourceOption) (*ResourceOptions, error)

This currently drops the dependencies of an MLC from the snapshot.
The reason for this is that it used a special type "urnSet"
to represent dependencies for MLCs received over the wire.
This decision was made at the time because the original Resource objects
were not available for these dependencies.

Turns out that that limitation isn't a blocker:
we can use newDependencyResource to create dummy Resource objects
that hold nothing but a URN.

This allows NewResourceOptions to work on options even inside an MLC.
Note that this currently only works for some of the options:
those that are propagated from `construct` into the Go SDK options.
Others will be added as part of #12154.

Testing:
The accompanying test failed for Dependencies without this change.
2023-04-18 12:18:00 -07:00
..
go sdk/go: Don't drop Dependencies in ResourceOptions snapshot for MLCs 2023-04-18 12:18:00 -07:00
nodejs [sdk/nodejs] Upgrade json5 2023-04-10 12:31:34 -07:00
proto/go Add mapping service to converter 2023-03-24 17:09:17 +00:00
python sdk/py/Resource: Don't drop merged providers 2023-04-13 18:12:20 -07:00
README.md Cleanup sdk/README.md 2023-01-03 17:12:12 -05:00
go.mod Bump go-git to v5.6.0 to remove cgo dependency fixing 2023-02-28 16:01:31 -08:00
go.sum Bump go-git to v5.6.0 to remove cgo dependency fixing 2023-02-28 16:01:31 -08:00

README.md

Pulumi Language SDKs

This directory contains Pulumi SDKs for the following languages:

See the respective READMEs for information about installing and using these libraries.

The language providers work by implementing gRPC interfaces defined in the top level directory proto.