mirror of https://github.com/pulumi/pulumi.git
a92101cd49
This new method is used to return the state of the resource monitor for a deployment directly to a client. This helps with three major areas: 1) `Construct` and `Call` no longer need to be kept up to date with any new features added to `Run`. All they need is the resource monitor target and can use `GetState` to fetch all other information. 2) We no longer need to find a way to pass all the information from `Run` from the runtime host to the runtime SDKs. Instead all we need to pass is the (again) the resource monitor target, and on startup the SDK can fetch the rest of the information over gRPC. In fact we don't even need to add new information to `Run`, as the language runtime host can also just use `GetState` to fetch the latest information. 3) Features are now a safe enumeration lookup rather than a set of strings that could be typo'd. Further you don't need to make multiple roundtrips to see all features supported, the entire set is returned at once. A few things need pointing out about this change. Firstly SDKs that use this _also_ need to have a fallback to using the old envvar based approch because they might be running against an old engine version. Secondly this PR doesn't update any of the SDKs to use this. The most obvious candidate to update first is YAML as that doesn't actually have an SDK, just the host and the host _doesn't_ need to be backward compatible because we always tie host and engine versions together in a single release. |
||
---|---|---|
.. | ||
auto | ||
common | ||
internal | ||
pulumi | ||
pulumi-language-go | ||
pulumix | ||
Makefile | ||
README.md |
README.md
Pulumi Golang SDK
This directory contains support for writing Pulumi programs in the Go language. There are two aspects to this:
pulumi/
contains the client language bindings Pulumi program's code directly against;pulumi-language-go/
contains the language host plugin that the Pulumi engine uses to orchestrate updates.
To author a Pulumi program in Go, simply say so in your Pulumi.yaml
name: <my-project>
runtime: go
and ensure you have pulumi-language-go
on your path (it is distributed in the Pulumi download automatically).
By default, the language plugin will use your project's name, <my-project>
, as the executable that it loads. This too
must be on your path for the language provider to load it when you run pulumi preview
or pulumi up
.