Skip to content

/AWS1/CL_VL=>CRESVCNETWORKVPCASSOCIATION()

About CreateServiceNetworkVpcAssociation

Associates a VPC with a service network. When you associate a VPC with the service network, it enables all the resources within that VPC to be clients and communicate with other services in the service network. For more information, see Manage VPC associations in the Amazon VPC Lattice User Guide.

You can't use this operation if there is a disassociation in progress. If the association fails, retry by deleting the association and recreating it.

As a result of this operation, the association gets created in the service network account and the VPC owner account.

If you add a security group to the service network and VPC association, the association must continue to always have at least one security group. You can add or edit security groups at any time. However, to remove all security groups, you must first delete the association and recreate it without security groups.

Method Signature

IMPORTING

Required arguments:

IV_SERVICENETWORKIDENTIFIER TYPE /AWS1/VL_SERVICENETWORKID /AWS1/VL_SERVICENETWORKID

The ID or Amazon Resource Name (ARN) of the service network. You must use the ARN when the resources specified in the operation are in different accounts.

IV_VPCIDENTIFIER TYPE /AWS1/VL_VPCID /AWS1/VL_VPCID

The ID of the VPC.

Optional arguments:

IV_CLIENTTOKEN TYPE /AWS1/VL_CLIENTTOKEN /AWS1/VL_CLIENTTOKEN

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If you retry a request that completed successfully using the same client token and parameters, the retry succeeds without performing any actions. If the parameters aren't identical, the retry fails.

IT_SECURITYGROUPIDS TYPE /AWS1/CL_VL_SECGROUPLIST_W=>TT_SECURITYGROUPLIST TT_SECURITYGROUPLIST

The IDs of the security groups. Security groups aren't added by default. You can add a security group to apply network level controls to control which resources in a VPC are allowed to access the service network and its services. For more information, see Control traffic to resources using security groups in the Amazon VPC User Guide.

IT_TAGS TYPE /AWS1/CL_VL_TAGMAP_W=>TT_TAGMAP TT_TAGMAP

The tags for the association.

RETURNING

OO_OUTPUT TYPE REF TO /AWS1/CL_VL_CRESVCNETWORKVPC01 /AWS1/CL_VL_CRESVCNETWORKVPC01