Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Resource: alicloud_ack_one_membership_attachment #8122

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vie-serendipity
Copy link

Support AttachClusterToHub and DetachClusterFromHub for terraform integrations.

@CLAassistant
Copy link

CLAassistant commented Jan 13, 2025

CLA assistant check
All committers have signed the CLA.

@vie-serendipity vie-serendipity changed the title feat: support resource ack one membership attaching New Resource: alicloud_ack_one_membership_attaching Jan 15, 2025
@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 2 times, most recently from 3b2bafd to cec9b18 Compare January 16, 2025 02:54
@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 2 times, most recently from 0d27bd5 to 7378ccc Compare January 16, 2025 06:32
@vie-serendipity vie-serendipity changed the title New Resource: alicloud_ack_one_membership_attaching New Resource: alicloud_ack_one_membership_attachment Jan 16, 2025
@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 2 times, most recently from e8c954f to 26fb537 Compare January 16, 2025 06:48
@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 2 times, most recently from 8565c74 to 498347f Compare January 16, 2025 09:48
@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 2 times, most recently from 17f4ddc to b58d804 Compare January 16, 2025 11:37
Copy link
Collaborator

@ChenHanZhang ChenHanZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved


The following attributes are exported:

* `id` - The ID of the resource supplied above.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

id描述改一下,The resource ID in terraform of Membership Attachment. It formats as < cluster_id >:< managed_cluster_id >.
image

Ack One Membership Attachment can be imported using the id, which consists of cluster_id and sub_cluster_id, e.g.

```shell
terraform import alicloud_ack_one_membership_attachment.example <cluster_id:sub_cluster_id>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

格式有问题应该是<>:<>,还有,这个资源是个二级id,一级是cluster_id,二级id中managedClusterIds[0].(string)对应的是出参字段managed_cluster_id,还是入参sub_cluster_id?
image

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

managed_cluster_id和sub_cluster_id是一致的,sub_cluster_id是入参,方便用户理解,我就都用sub_cluster_id可以吗

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

就是说,这个资源一共两个入参字段,一个出参字段,其中入参字段sub_cluster_id等价出参字段managed_cluster_id,对吗?如果是这样,那就字段冗余了,把出参managed_cluster_id删掉吧。

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

它的用处是如果managed_cluster_id为null的话表示关联关系没有创建成功

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不过id存在应该就能表明关联关系存不存在,那我删一下managed_cluster_id

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

已删除

@vie-serendipity vie-serendipity force-pushed the feat/ackonemembership branch 3 times, most recently from 7604cf7 to 8929f75 Compare January 17, 2025 08:52
Copy link
Collaborator

@MrWolong MrWolong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

Copy link
Collaborator

@MrWolong MrWolong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

Copy link
Collaborator

@ChenHanZhang ChenHanZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

Copy link
Collaborator

@ChenHanZhang ChenHanZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

doc: add doc for alicloud_ack_one_membership_attaching

test: new resource alicloud_ack_one_membership_attaching
Signed-off-by: 宜松 <zzy405810@alibaba-inc.com>
Copy link
Collaborator

@ChenHanZhang ChenHanZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants