pulumi/sdk/go/common/resource
Thomas Gummerer 2f4b26b681
rewrite the URN when resources are being moved between projects (#16523)
When a resource is moved between stacks in different projects we also
need to rewrite project part of the URNs. Do that here. Moving between
different projects already works by virtue of the requireStack function
supporting that when providing the fully qualified name of the stack.

There is some awkwardness here as old diy backends may not return a
project name, in which case we error out here. Curious if anyone has
thought about what to do here. Is erroring out the best we can do? What
happens if we don't rewrite the project name in this case?

---------

Co-authored-by: Will Jones <will@sacharissa.co.uk>
2024-07-01 17:36:11 +00:00
..
archive Add asset archive test to conformance tests (#16455) 2024-06-24 14:23:18 +00:00
asset Add asset/archive to conformance tests and fix engine working dir issues (#16100) 2024-05-02 11:32:54 +00:00
config Enable finding Pulumi projects created from Templates (#15056) 2024-01-24 16:47:12 +00:00
plugin Add not-found markers to missing executables for packagemanagers (#16488) 2024-06-28 23:21:55 +00:00
sig Move assets and archives to their own package (#15157) 2024-01-25 20:39:31 +00:00
testing Move assets and archives to their own package (#15157) 2024-01-25 20:39:31 +00:00
urn rewrite the URN when resources are being moved between projects (#16523) 2024-07-01 17:36:11 +00:00
alias.go [engine] Fix aliasing children 2023-06-14 05:19:17 -07:00
alias_test.go feat(engine): Adds structured alias support to the engine 2022-10-11 17:56:32 -04:00
asset.go Add asset archive test to conformance tests (#16455) 2024-06-24 14:23:18 +00:00
asset_test.go Deserialize Assets with their Sig (#16073) 2024-04-26 19:05:50 +00:00
custom_timeouts.go move pkg/resource -> sdk/go/common/resource, but leave nested resource packages 2020-03-18 13:36:19 -07:00
errors.go [breaking] Changing the version of go.mod in sdk / pkg to be v3 2021-04-14 19:32:18 +01:00
mapper_test.go Move assets and archives to their own package (#15157) 2024-01-25 20:39:31 +00:00
properties.go A property.Value implementation to replace resource.PropertyValue (#15145) 2024-03-14 19:58:59 +00:00
properties_diff.go A property.Value implementation to replace resource.PropertyValue (#15145) 2024-03-14 19:58:59 +00:00
properties_diff_test.go Move assets and archives to their own package (#15157) 2024-01-25 20:39:31 +00:00
properties_path.go Fix a panic when ignoring wildcard values with arrays of different length (#16406) 2024-06-17 08:16:41 +00:00
properties_path_test.go Fix a panic when ignoring wildcard values with arrays of different length (#16406) 2024-06-17 08:16:41 +00:00
properties_test.go [resource] Add a generic NewProperty function (#14534) 2023-11-11 21:12:17 +00:00
property_compatibility.go Property map keys are just strings (#15767) 2024-03-25 17:26:41 +00:00
property_compatibility_test.go A property.Value implementation to replace resource.PropertyValue (#15145) 2024-03-14 19:58:59 +00:00
resource_goal.go Allow anything in resource names (#14107) 2023-11-20 08:59:00 +00:00
resource_id.go sdk/go: Prefer contract.Assertf over Assert 2023-02-15 10:22:43 -08:00
resource_id_test.go Use EqualError/ErrorContains instead of Error (#14737) 2023-12-08 06:40:14 +00:00
resource_operation.go move pkg/resource -> sdk/go/common/resource, but leave nested resource packages 2020-03-18 13:36:19 -07:00
resource_state.go Change `pulumi refresh` to report diff relative to desired state instead of relative to only output changes (#16146) 2024-06-12 16:17:05 +00:00
stack.go Move resource.URN to urn.URN (#15689) 2024-03-14 15:28:32 +00:00
status.go move pkg/resource -> sdk/go/common/resource, but leave nested resource packages 2020-03-18 13:36:19 -07:00
urn.go Move resource.URN to urn.URN (#15689) 2024-03-14 15:28:32 +00:00