Skip to content

Commit

Permalink
Implement large scale performance test
Browse files Browse the repository at this point in the history
Signed-off-by: Wenqi Qiu <wenqiq@vmware.com>
  • Loading branch information
wenqiq committed Jan 4, 2024
1 parent 7702924 commit 66ae6dd
Show file tree
Hide file tree
Showing 53 changed files with 2,693 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ antrea-agent-simulator:
@mkdir -p $(BINDIR)
GOOS=linux $(GO) build -o $(BINDIR) $(GOFLAGS) -ldflags '$(LDFLAGS)' antrea.io/antrea/cmd/antrea-agent-simulator

.PHONY: antrea-scale
antrea-scale:
@mkdir -p $(BINDIR)
GOOS=linux $(GO) build -o $(BINDIR) $(GOFLAGS) -ldflags '$(LDFLAGS)' antrea.io/antrea/cmd/antrea-scale

.PHONY: antrea-agent-instr-binary
antrea-agent-instr-binary:
@mkdir -p $(BINDIR)
Expand Down Expand Up @@ -332,6 +337,12 @@ else
endif
docker tag antrea/antrea-ubuntu:$(DOCKER_IMG_VERSION) antrea/antrea-ubuntu

.PHONY: antrea-scale-image
antrea-scale-image:
@echo "===> Building antrea/antrea-scale Docker image <==="
docker build -t antrea/antrea-scale:$(DOCKER_IMG_VERSION) -f build/images/Dockerfile.scale .
docker tag antrea/antrea-scale:$(DOCKER_IMG_VERSION) antrea/antrea-scale

# Build bins in a golang container, and build the antrea-ubuntu Docker image.
.PHONY: build-ubuntu
build-ubuntu:
Expand Down
33 changes: 33 additions & 0 deletions build/charts/antrea/templates/simulator/simulator.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: antrea-agent
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: antrea-controller
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
1 change: 1 addition & 0 deletions build/charts/antrea/templates/simulator/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ spec:
initContainers:
- name: init-inotify-limit
image: projects.registry.vmware.com/antrea/busybox:latest
imagePullPolicy: IfNotPresent
command: ['sysctl', '-w', 'fs.inotify.max_user_instances=200']
securityContext:
privileged: true
Expand Down
9 changes: 9 additions & 0 deletions build/images/Dockerfile.scale
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM ubuntu:20.04

LABEL maintainer="Antrea <projectantrea-dev@googlegroups.com>"
LABEL description="Antrea scale test image."

USER root

COPY test/performance/scale.yml .
COPY bin/antrea-scale /usr/local/bin
36 changes: 36 additions & 0 deletions build/yamls/antrea-aks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7118,6 +7118,24 @@ spec:
path: /run/xtables.lock
type: FileOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: antrea-agent
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/deployment.yaml
apiVersion: apps/v1
kind: Deployment
Expand Down Expand Up @@ -7246,6 +7264,24 @@ spec:
path: /var/log/antrea
type: DirectoryOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: Deployment
metadata:
name: antrea-controller
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/apiservices.yaml
apiVersion: apiregistration.k8s.io/v1
kind: APIService
Expand Down
36 changes: 36 additions & 0 deletions build/yamls/antrea-eks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7119,6 +7119,24 @@ spec:
path: /run/xtables.lock
type: FileOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: antrea-agent
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/deployment.yaml
apiVersion: apps/v1
kind: Deployment
Expand Down Expand Up @@ -7247,6 +7265,24 @@ spec:
path: /var/log/antrea
type: DirectoryOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: Deployment
metadata:
name: antrea-controller
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/apiservices.yaml
apiVersion: apiregistration.k8s.io/v1
kind: APIService
Expand Down
36 changes: 36 additions & 0 deletions build/yamls/antrea-gke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7116,6 +7116,24 @@ spec:
path: /run/xtables.lock
type: FileOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: antrea-agent
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/deployment.yaml
apiVersion: apps/v1
kind: Deployment
Expand Down Expand Up @@ -7244,6 +7262,24 @@ spec:
path: /var/log/antrea
type: DirectoryOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: Deployment
metadata:
name: antrea-controller
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/apiservices.yaml
apiVersion: apiregistration.k8s.io/v1
kind: APIService
Expand Down
36 changes: 36 additions & 0 deletions build/yamls/antrea-ipsec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7175,6 +7175,24 @@ spec:
path: /run/xtables.lock
type: FileOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: antrea-agent
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/deployment.yaml
apiVersion: apps/v1
kind: Deployment
Expand Down Expand Up @@ -7303,6 +7321,24 @@ spec:
path: /var/log/antrea
type: DirectoryOrCreate
---
# Source: antrea/templates/simulator/simulator.yml
apiVersion: apps/v1
kind: Deployment
metadata:
name: antrea-controller
spec:
template:
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: antrea/instance
operator: NotIn
values:
- simulator
---
# Source: antrea/templates/controller/apiservices.yaml
apiVersion: apiregistration.k8s.io/v1
kind: APIService
Expand Down
Loading

0 comments on commit 66ae6dd

Please sign in to comment.