pulumi/changelog
bors[bot] 881846d9fd
Merge #11896 #11910 #11912
11896: Add support for a Teams array in the CreateStackRequest r=justinvp a=stevesloka

# Description

Add support for a Teams array in the CreateStackRequest which allows specifying Teams when a Stack is created.

Updates #10784

Signed-off-by: Steve Sloka <steve@pulumi.com>

## Checklist

- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] I have run `make changelog` and committed the `changelog/pending/<file>` documenting my change
- [ ] Yes, there are changes in this PR that warrants bumping the Pulumi Service API version


11910: Changelog and go.mod updates for v3.52.0 r=dixler a=pulumi-bot

bors merge

11912: pkg/hcl2/model: Make String methods thread-safe r=abhinav a=abhinav

ObjectType.String and a few other types
do a fair bit of computation to build a string representation.
They memoize the result in an internal `s` field.
This causes a data race if two goroutines call `String()`
on the same object at the same time.

Tests in pkg/codegen/pcl ran into the following
from ObjectType.String.

```
WARNING: DATA RACE
Write at 0x00c00055c030 by goroutine 36:
  github.com/pulumi/pulumi/pkg/v3/codegen/hcl2/model.(*ObjectType).string()
      [..]/pulumi/pkg/codegen/hcl2/model/type_object.go:300 +0x418
  [.. snip ..]
  github.com/pulumi/pulumi/pkg/v3/codegen/pcl.TestApplyRewriter.func1()
      [..]/pulumi/pkg/codegen/pcl/rewrite_apply_test.go:176 +0x68
  testing.tRunner()
      /opt/homebrew/Cellar/go/1.19.5/libexec/src/testing/testing.go:1446 +0x188
  testing.(*T).Run.func1()
      /opt/homebrew/Cellar/go/1.19.5/libexec/src/testing/testing.go:1493 +0x40

Previous read at 0x00c00055c030 by goroutine 37:
  github.com/pulumi/pulumi/pkg/v3/codegen/hcl2/model.(*ObjectType).string()
      [..]/pulumi/pkg/codegen/hcl2/model/type_object.go:276 +0x40
  github.com/pulumi/pulumi/pkg/v3/codegen/hcl2/model.(*OutputType).string()
      [..]/pulumi/pkg/codegen/hcl2/model/type_output.go:110 +0x4c
  [..]
```

To fix this, turn the memoized field into an `atomic.Value`
in all types that memoize it.

When two goroutines race to calculate this value,
one of them will do extra work that will be thrown away,
but it won't cause a data race.

Refs #10092


Co-authored-by: Steve Sloka <steve@pulumi.com>
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Abhinav Gupta <abhinav@pulumi.com>
2023-01-19 20:36:29 +00:00
..
pending Merge #11896 #11910 #11912 2023-01-19 20:36:29 +00:00
config.yaml Reorder scopes to be alphabetically ordered. 2022-11-10 16:54:37 -05:00