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

add canary test entrypoint script #1717

Merged
merged 4 commits into from
Nov 2, 2021
Merged

Conversation

abhipth
Copy link
Contributor

@abhipth abhipth commented Oct 29, 2021

What type of PR is this?
Script for adding Canary tests entrypoint script. The script does the following

  • Installs default addon and runs canary tests.
  • installs the latest addon and runs the smoke tests.

Currently the total time for the entire canary script executions is around 25minutes.

Testing done on this change:
Results from test execution.

loading cluster details networking-prow-test
loading vpc-cni addon details
Running Canary tests on the default addon version
deleting the v1.9.1-eksbuild.1 to install v1.7.5-eksbuild.2
{
    "addon": {
        "addonName": "vpc-cni",
        "clusterName": "networking-prow-test",
        "status": "DELETING",
        "addonVersion": "v1.9.1-eksbuild.1",
        "health": {
            "issues": []
        },
        "addonArn": "arn:aws:eks:us-west-2:REDACTED:addon/networking-prow-test/vpc-cni/0cbe66e5-9fe6-4ce1-739d-c2d721308465",
        "createdAt": 1635540222.059,
        "modifiedAt": 1635542632.955,
        "tags": {}
    }
}

An error occurred (ResourceNotFoundException) when calling the DescribeAddon operation: No addon: vpc-cni found in cluster: networking-prow-test
addon deleted
installing addon v1.7.5-eksbuild.2
{
    "addon": {
        "addonName": "vpc-cni",
        "clusterName": "networking-prow-test",
        "status": "CREATING",
        "addonVersion": "v1.7.5-eksbuild.2",
        "health": {
            "issues": []
        },
        "addonArn": "arn:aws:eks:us-west-2:REDACTED:addon/networking-prow-test/vpc-cni/24be66f8-09ae-45b4-e367-5d32167ad40d",
        "createdAt": 1635542635.609,
        "modifiedAt": 1635542635.629,
        "tags": {}
    }
}
daemonset.apps/aws-node patched
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status matches expected status
Running ginkgo tests with focus: CANARY
Running Suite: CNI Pod Networking Suite
=======================================
Random Seed: 1635542669
Will run 6 of 14 specs

STEP: creating test namespace
STEP: getting the node with the node label key kubernetes.io/os and value linux
STEP: verifying more than 1 nodes are present for the test
STEP: getting the instance type from node label beta.kubernetes.io/instance-type
STEP: getting the network interface details from ec2
STEP: describing the VPC to get the VPC CIDRs
STEP: setting the environment variables on the ds to map[WARM_ENI_TARGET:0 WARM_IP_TARGET:3]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists
S
------------------------------
test pod networking [CANARY][SMOKE] when establishing UDP connection from tester to server 
  connection should be established
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:216
STEP: authorizing security group ingress on instance security group
STEP: authorizing security group egress on instance security group
STEP: creating server deployment on the primary node
STEP: creating server deployment on secondary node
STEP: checking connection on same node, primary to primary
verifying connectivity from pod primary-node-server-6cd96cb97d-vz7hb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.238.211 to pod primary-node-server-6cd96cb97d-6bc8v on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.167.97
stdout:  and stderr: Connection to 10.2.167.97 2273 port [udp/*] succeeded!

STEP: checking connection on same node, primary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-vz7hb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.238.211 to pod primary-node-server-6cd96cb97d-x9fv6 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.106.226
stdout:  and stderr: Connection to 10.2.106.226 2273 port [udp/*] succeeded!

STEP: checking connection on same node, secondary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-x9fv6 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.106.226 to pod primary-node-server-6cd96cb97d-p8vbd on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.2.32
stdout:  and stderr: Connection to 10.2.2.32 2273 port [udp/*] succeeded!

STEP: checking connection on different node, primary to primary
verifying connectivity from pod primary-node-server-6cd96cb97d-vz7hb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.238.211 to pod secondary-node-server-dcdfb59b4-mlw4q on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.67.240
stdout:  and stderr: Connection to 10.1.67.240 2273 port [udp/*] succeeded!

STEP: checking connection on different node, primary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-vz7hb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.238.211 to pod secondary-node-server-dcdfb59b4-dhjdl on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.153.41
stdout:  and stderr: Connection to 10.1.153.41 2273 port [udp/*] succeeded!

STEP: checking connection on different node, secondary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-x9fv6 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.106.226 to pod secondary-node-server-dcdfb59b4-dhjdl on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.153.41
stdout:  and stderr: Connection to 10.1.153.41 2273 port [udp/*] succeeded!

STEP: verifying connection fails for unreachable port
verifying connectivity fails from pod primary-node-server-6cd96cb97d-vz7hb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.238.211 to pod primary-node-server-6cd96cb97d-6bc8v on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.167.97
STEP: revoking security group ingress on instance security group
STEP: revoking security group egress on instance security group
STEP: deleting the primary node server deployment
STEP: deleting the secondary node server deployment

• [SLOW TEST:68.808 seconds]
test pod networking
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:35
  [CANARY][SMOKE] when establishing UDP connection from tester to server
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:190
    connection should be established
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:216
------------------------------
test pod networking [CANARY][SMOKE] when establishing TCP connection from tester to server 
  should allow connection across nodes and across interface types
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:255
STEP: authorizing security group ingress on instance security group
STEP: authorizing security group egress on instance security group
STEP: creating server deployment on the primary node
STEP: creating server deployment on secondary node
STEP: checking connection on same node, primary to primary
verifying connectivity from pod primary-node-server-55478b7978-vncv7 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.201.195 to pod primary-node-server-55478b7978-5kzdr on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.46.4
stdout:  and stderr: Connection to 10.2.46.4 2273 port [tcp/*] succeeded!

STEP: checking connection on same node, primary to secondary
verifying connectivity from pod primary-node-server-55478b7978-vncv7 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.201.195 to pod primary-node-server-55478b7978-bwnwj on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.2.32
stdout:  and stderr: Connection to 10.2.2.32 2273 port [tcp/*] succeeded!

STEP: checking connection on same node, secondary to secondary
verifying connectivity from pod primary-node-server-55478b7978-bwnwj on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.2.32 to pod primary-node-server-55478b7978-5v94n on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.115.102
stdout:  and stderr: Connection to 10.2.115.102 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, primary to primary
verifying connectivity from pod primary-node-server-55478b7978-vncv7 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.201.195 to pod secondary-node-server-787dc9cfdd-lc4rg on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.252.195
stdout:  and stderr: Connection to 10.1.252.195 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, primary to secondary
verifying connectivity from pod primary-node-server-55478b7978-vncv7 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.201.195 to pod secondary-node-server-787dc9cfdd-ddb6k on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.253.219
stdout:  and stderr: Connection to 10.1.253.219 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, secondary to secondary
verifying connectivity from pod primary-node-server-55478b7978-bwnwj on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.2.32 to pod secondary-node-server-787dc9cfdd-ddb6k on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.253.219
stdout:  and stderr: Connection to 10.1.253.219 2273 port [tcp/*] succeeded!

STEP: verifying connection fails for unreachable port
verifying connectivity fails from pod primary-node-server-55478b7978-vncv7 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.201.195 to pod primary-node-server-55478b7978-5kzdr on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.46.4
STEP: revoking security group ingress on instance security group
STEP: revoking security group egress on instance security group
STEP: deleting the primary node server deployment
STEP: deleting the secondary node server deployment

• [SLOW TEST:75.793 seconds]
test pod networking
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:35
  [CANARY][SMOKE] when establishing TCP connection from tester to server
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:228
    should allow connection across nodes and across interface types
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:255
------------------------------
SSSSSSS
------------------------------
[CANARY] test service connectivity when a deployment behind clb service is created 
  clb service pod should be reachable
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:147
STEP: creating and waiting for deployment to be ready
STEP: creating the service of type LoadBalancer
created service
: {LoadBalancer:{Ingress:[]}}
STEP: sleeping for some time to allow service to become ready
STEP: creating jobs to verify service connectivity
STEP: creating negative jobs to verify service connectivity fails for unreachable port

• [SLOW TEST:105.482 seconds]
[CANARY] test service connectivity
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:37
  when a deployment behind clb service is created
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:142
    clb service pod should be reachable
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:147
------------------------------
[CANARY] test service connectivity when a deployment behind nlb service is created 
  nlb service pod should be reachable
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:157
STEP: creating and waiting for deployment to be ready
STEP: creating the service of type LoadBalancer
created service
: {LoadBalancer:{Ingress:[]}}
STEP: sleeping for some time to allow service to become ready
STEP: creating jobs to verify service connectivity
STEP: creating negative jobs to verify service connectivity fails for unreachable port

• [SLOW TEST:132.826 seconds]
[CANARY] test service connectivity
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:37
  when a deployment behind nlb service is created
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:150
    nlb service pod should be reachable
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:157
------------------------------
[CANARY] test service connectivity when a deployment behind cluster IP is created 
  clusterIP service pod should be reachable
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:165
STEP: creating and waiting for deployment to be ready
STEP: creating the service of type ClusterIP
created service
: {LoadBalancer:{Ingress:[]}}
STEP: sleeping for some time to allow service to become ready
STEP: creating jobs to verify service connectivity
STEP: creating negative jobs to verify service connectivity fails for unreachable port

• [SLOW TEST:134.843 seconds]
[CANARY] test service connectivity
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:37
  when a deployment behind cluster IP is created
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:160
    clusterIP service pod should be reachable
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:165
------------------------------
[CANARY] test service connectivity when a deployment behind node port is created 
  node port service pod should be reachable
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:173
STEP: creating and waiting for deployment to be ready
STEP: creating the service of type NodePort
created service
: {LoadBalancer:{Ingress:[]}}
STEP: sleeping for some time to allow service to become ready
STEP: creating jobs to verify service connectivity
STEP: creating negative jobs to verify service connectivity fails for unreachable port

• [SLOW TEST:134.904 seconds]
[CANARY] test service connectivity
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:37
  when a deployment behind node port is created
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:168
    node port service pod should be reachable
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/service_connectivity_test.go:173
------------------------------
STEP: deleting test namespace
STEP: update environment variables map[AWS_VPC_ENI_MTU:9001 AWS_VPC_K8S_CNI_VETHPREFIX:eni], remove map[WARM_ENI_TARGET:{} WARM_IP_TARGET:{}]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists

Ran 6 of 14 Specs in 734.695 seconds
SUCCESS! -- 6 Passed | 0 Failed | 0 Pending | 8 Skipped
PASS

Ginkgo ran 1 suite in 12m25.749202272s
Test Suite Passed
Running Suite: VPC IPAMD Test Suite
===================================
Random Seed: 1635543414
Will run 1 of 26 specs

STEP: Delete coredns addon if it exists
SSSSSSSSSSSSSSSSSSSSSSSSS
------------------------------
[CANARY] ENI/IP Leak Test ENI/IP Released on Pod Deletion 
  Verify that on Pod Deletion, ENI/IP State is restored
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/ipamd/eni_ip_leak_test.go:28
STEP: creating test namespace
STEP: Setting WARM_ENI_TARGET to 0
STEP: setting the environment variables on the ds to map[WARM_ENI_TARGET:0 WARM_IP_TARGET:3]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists
STEP: Recording the initial count of IP before new deployment
STEP: Deploying a max number of Busybox pods
STEP: Deleting the deployment
STEP: Validating that count of ENI/IP is same as before
STEP: deleting test namespace
STEP: Restoring WARM ENI Target value
STEP: removing the environment variables from the ds map[WARM_ENI_TARGET:{} WARM_IP_TARGET:{}]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists

• [SLOW TEST:257.230 seconds]
[CANARY] ENI/IP Leak Test
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/ipamd/eni_ip_leak_test.go:20
  ENI/IP Released on Pod Deletion
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/ipamd/eni_ip_leak_test.go:21
    Verify that on Pod Deletion, ENI/IP State is restored
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/ipamd/eni_ip_leak_test.go:28
------------------------------

Ran 1 of 26 Specs in 261.096 seconds
SUCCESS! -- 1 Passed | 0 Failed | 0 Pending | 25 Skipped
PASS

Ginkgo ran 1 suite in 4m30.218992238s
Test Suite Passed
Running Smoke tests on the latest addon version
deleting the v1.7.5-eksbuild.2 to install v1.9.1-eksbuild.1
{
    "addon": {
        "addonName": "vpc-cni",
        "clusterName": "networking-prow-test",
        "status": "DELETING",
        "addonVersion": "v1.7.5-eksbuild.2",
        "health": {
            "issues": []
        },
        "addonArn": "arn:aws:eks:us-west-2:REDACTED:addon/networking-prow-test/vpc-cni/24be66f8-09ae-45b4-e367-5d32167ad40d",
        "createdAt": 1635542635.609,
        "modifiedAt": 1635543687.535,
        "tags": {}
    }
}

An error occurred (ResourceNotFoundException) when calling the DescribeAddon operation: No addon: vpc-cni found in cluster: networking-prow-test
addon deleted
installing addon v1.9.1-eksbuild.1
{
    "addon": {
        "addonName": "vpc-cni",
        "clusterName": "networking-prow-test",
        "status": "CREATING",
        "addonVersion": "v1.9.1-eksbuild.1",
        "health": {
            "issues": []
        },
        "addonArn": "arn:aws:eks:us-west-2:REDACTED:addon/networking-prow-test/vpc-cni/c4be6700-1528-7436-0393-efe087b818e3",
        "createdAt": 1635543689.965,
        "modifiedAt": 1635543689.984,
        "tags": {}
    }
}
daemonset.apps/aws-node patched
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status is not euqal to ACTIVE
addon status matches expected status
Running ginkgo tests with focus: SMOKE
Running Suite: CNI Pod Networking Suite
=======================================
Random Seed: 1635543751
Will run 2 of 14 specs

STEP: creating test namespace
STEP: getting the node with the node label key kubernetes.io/os and value linux
STEP: verifying more than 1 nodes are present for the test
STEP: getting the instance type from node label beta.kubernetes.io/instance-type
STEP: getting the network interface details from ec2
STEP: describing the VPC to get the VPC CIDRs
STEP: setting the environment variables on the ds to map[WARM_ENI_TARGET:0 WARM_IP_TARGET:3]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists
SSSSSSS
------------------------------
test pod networking [CANARY][SMOKE] when establishing UDP connection from tester to server 
  connection should be established
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:216
STEP: authorizing security group ingress on instance security group
STEP: authorizing security group egress on instance security group
STEP: creating server deployment on the primary node
STEP: creating server deployment on secondary node
STEP: checking connection on same node, primary to primary
verifying connectivity from pod primary-node-server-6cd96cb97d-wnws8 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.80.4 to pod primary-node-server-6cd96cb97d-mh49j on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165
stdout:  and stderr: Connection to 10.2.94.165 2273 port [udp/*] succeeded!

STEP: checking connection on same node, primary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-wnws8 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.80.4 to pod primary-node-server-6cd96cb97d-w26jq on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.172.230
stdout:  and stderr: Connection to 10.2.172.230 2273 port [udp/*] succeeded!

STEP: checking connection on same node, secondary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-w26jq on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.172.230 to pod primary-node-server-6cd96cb97d-7ptzb on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.67.23
stdout:  and stderr: Connection to 10.2.67.23 2273 port [udp/*] succeeded!

STEP: checking connection on different node, primary to primary
verifying connectivity from pod primary-node-server-6cd96cb97d-wnws8 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.80.4 to pod secondary-node-server-dcdfb59b4-pbz9r on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.10.67
stdout:  and stderr: Connection to 10.1.10.67 2273 port [udp/*] succeeded!

STEP: checking connection on different node, primary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-wnws8 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.80.4 to pod secondary-node-server-dcdfb59b4-mdtct on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.213.180
stdout:  and stderr: Connection to 10.1.213.180 2273 port [udp/*] succeeded!

STEP: checking connection on different node, secondary to secondary
verifying connectivity from pod primary-node-server-6cd96cb97d-w26jq on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.172.230 to pod secondary-node-server-dcdfb59b4-mdtct on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.213.180
stdout:  and stderr: Connection to 10.1.213.180 2273 port [udp/*] succeeded!

STEP: verifying connection fails for unreachable port
verifying connectivity fails from pod primary-node-server-6cd96cb97d-wnws8 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.80.4 to pod primary-node-server-6cd96cb97d-mh49j on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165
STEP: revoking security group ingress on instance security group
STEP: revoking security group egress on instance security group
STEP: deleting the primary node server deployment
STEP: deleting the secondary node server deployment

• [SLOW TEST:120.364 seconds]
test pod networking
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:35
  [CANARY][SMOKE] when establishing UDP connection from tester to server
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:190
    connection should be established
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:216
------------------------------
test pod networking [CANARY][SMOKE] when establishing TCP connection from tester to server 
  should allow connection across nodes and across interface types
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:255
STEP: authorizing security group ingress on instance security group
STEP: authorizing security group egress on instance security group
STEP: creating server deployment on the primary node
STEP: creating server deployment on secondary node
STEP: checking connection on same node, primary to primary
verifying connectivity from pod primary-node-server-55478b7978-mn5vk on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165 to pod primary-node-server-55478b7978-qhvp2 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.144.216
stdout:  and stderr: Connection to 10.2.144.216 2273 port [tcp/*] succeeded!

STEP: checking connection on same node, primary to secondary
verifying connectivity from pod primary-node-server-55478b7978-mn5vk on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165 to pod primary-node-server-55478b7978-j2wp2 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.117.83
stdout:  and stderr: Connection to 10.2.117.83 2273 port [tcp/*] succeeded!

STEP: checking connection on same node, secondary to secondary
verifying connectivity from pod primary-node-server-55478b7978-j2wp2 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.117.83 to pod primary-node-server-55478b7978-cjb5b on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.51.129
stdout:  and stderr: Connection to 10.2.51.129 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, primary to primary
verifying connectivity from pod primary-node-server-55478b7978-mn5vk on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165 to pod secondary-node-server-787dc9cfdd-rfvjl on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.150.51
stdout:  and stderr: Connection to 10.1.150.51 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, primary to secondary
verifying connectivity from pod primary-node-server-55478b7978-mn5vk on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165 to pod secondary-node-server-787dc9cfdd-xhptj on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.91.155
stdout:  and stderr: Connection to 10.1.91.155 2273 port [tcp/*] succeeded!

STEP: checking connection on different node, secondary to secondary
verifying connectivity from pod primary-node-server-55478b7978-j2wp2 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.117.83 to pod secondary-node-server-787dc9cfdd-xhptj on node ip-10-1-119-98.us-west-2.compute.internal with IP 10.1.91.155
stdout:  and stderr: Connection to 10.1.91.155 2273 port [tcp/*] succeeded!

STEP: verifying connection fails for unreachable port
verifying connectivity fails from pod primary-node-server-55478b7978-mn5vk on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.94.165 to pod primary-node-server-55478b7978-qhvp2 on node ip-10-2-176-108.us-west-2.compute.internal with IP 10.2.144.216
STEP: revoking security group ingress on instance security group
STEP: revoking security group egress on instance security group
STEP: deleting the primary node server deployment
STEP: deleting the secondary node server deployment

• [SLOW TEST:124.517 seconds]
test pod networking
/Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:35
  [CANARY][SMOKE] when establishing TCP connection from tester to server
  /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:228
    should allow connection across nodes and across interface types
    /Users/abhipth/go/src/github.com/aws/amazon-vpc-cni-k8s/test/integration-new/cni/pod_traffic_test.go:255
------------------------------
SSSSSSTEP: deleting test namespace
STEP: update environment variables map[AWS_VPC_ENI_MTU:9001 AWS_VPC_K8S_CNI_VETHPREFIX:eni], remove map[WARM_ENI_TARGET:{} WARM_IP_TARGET:{}]
STEP: getting the aws-node daemon set in namesapce kube-system
STEP: updating the daemon set with new environment variable
STEP: Restarting Multus daemonset if it exists

Ran 2 of 14 Specs in 321.148 seconds
SUCCESS! -- 2 Passed | 0 Failed | 0 Pending | 12 Skipped
PASS

Ginkgo ran 1 suite in 5m29.733108522s
Test Suite Passed
Running Suite: VPC IPAMD Test Suite
===================================
Random Seed: 1635544081
Will run 0 of 26 specs

STEP: Delete coredns addon if it exists
SSSSSSSSSSSSSSSSSSSSSSSSSS
Ran 0 of 26 Specs in 3.878 seconds
SUCCESS! -- 0 Passed | 0 Failed | 0 Pending | 26 Skipped
PASS

Ginkgo ran 1 suite in 10.965499193s
Test Suite Passed
all tests ran successfully in 24 minutes and 25 seconds

Will this break upgrades or downgrades. Has updating a running cluster been tested?:
No

Does this change require updates to the CNI daemonset config files to work?:
No

Does this PR introduce any user-facing change?:
No

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

test/README.md Outdated
@@ -0,0 +1,8 @@
## Available Ginkgo Focuses

### [CANARY]
Copy link
Member

Choose a reason for hiding this comment

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

A note on why do we separate it, and how it is used in testing infrastructure might guide the next maintainer.
Is the idea that

  • SMOKE will be run always against any environment and change?
  • CANARY will be run before the release or nightly?

Copy link
Contributor Author

@abhipth abhipth Oct 29, 2021

Choose a reason for hiding this comment

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

Here are my initial thoughts,

  • The nightly tests will run all integration tests which could run for hours.
  • Canary tests will be run quite frequently multiple times in a day so we won't be able to run all of our integration tests. So we run a selected set of tests of most important features that need to be tested. And probably cross dependencies like ALB creation as part of Service creation etc..
  • Smoke tests can be utilized to fail a workflow early, for example PR Integration workflow can run Smoke tests as prerequisite before running the lengthy integration tests. But in case of this PR we are also using it to run on latest addon given running the entire Canary test could lead to the script running for 20 more minutes.

I don't have much information about how upstream does this, so open to feedback to be more aligned with upstream testing or to improve this PR. Also I think as you suggested we need more clear guidance on types of tests and what should run in each type of test.

Copy link
Member

Choose a reason for hiding this comment

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

Hi @abhipth - This information is sufficient. You could please add this in the readme itself.
When we realize how upstream or other projects do any different for their benefits, we can evaluate and change it then.

But the above schedule idea and separation looks good to me.

INTEGRATION_TEST_DIR="$SCRIPT_DIR/../test/integration-new"
VPC_CNI_ADDON_NAME="vpc-cni"

echo "Running Canary tests for amazon-vpc-cni-k8s with the following varialbes
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: varialbes->variables

echo "addon status matches expected status"
return
fi
echo "addon status is not euqal to $expected_status"
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: euqal -> equal

Copy link
Member

@orsenthil orsenthil left a comment

Choose a reason for hiding this comment

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

Once Jayanth's comments are addressed. LGTM

Copy link
Contributor

@jayanthvn jayanthvn left a comment

Choose a reason for hiding this comment

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

lgtm

@jayanthvn jayanthvn merged commit 6a15a84 into aws:master Nov 2, 2021
haouc pushed a commit to haouc/amazon-vpc-cni-k8s that referenced this pull request Feb 9, 2022
* add canary test entrypoint script

* only run the linux tests on linux nodes

* add details about the type of tests in README

* run tests only on the latest addon version
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.

3 participants