An AWS Lambda can be network-attached to multiple subnets of a VPC. For each attached subnet (and security group) the Lambda will have (at least) one ENI.
When a Lambda, which has more than one subnet/ENI attachment, initiates traffic to a destination in the same VPC, what rules determine which subnet/ENI is chosen for the initiated traffic?
AWS could perhaps choose a subnet randomly from the attached subnets/ENI's. If so, it would work fine because of the "local" default route for a VPC doesn't care about the originating subnet. But is it random?
Recently AWS has overhauled Lambda subnet/ENI attachments to become more efficient...so that a minimum of ENI's are created and re-used, rather than a new ENI per Lambda execution. But this doesn't change the question. Fundamentally any Lambda that is attached to multiple subnets will require that (one ENI in) one of the attached subnets is chosen for intra-VPC traffic generated by the lambda.
What are the rules for the how that subnet is chosen?