Skip to content

Commit

Permalink
PP-3248: Add K8s deployment for Go profiler load tester
Browse files Browse the repository at this point in the history
Summary: This diff adds the K8s YAML files to deploy the Go profiler load tester to a cluster. When we have other language profilers, we can add a profile to the skaffold file that gets passed in as an input argument.

Test Plan: ran it on my cluster

Reviewers: zasgar, vihang, oazizi, jamesbartlett

Reviewed By: vihang

JIRA Issues: PP-3248

Signed-off-by: Natalie Serrino <nserrino@pixielabs.ai>

Differential Revision: https://phab.corp.pixielabs.ai/D10789

GitOrigin-RevId: 6d83bca
  • Loading branch information
Natalie Serrino authored and copybaranaut committed Feb 16, 2022
1 parent b847492 commit 4993c43
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/e2e_test/profiler_loadtest/go/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ container_push(
format = "Docker",
image = ":profiler_loadtest_golang_image",
registry = "gcr.io",
repository = "pixie-oss/pixie-dev/experimental/profiler_loadtest_golang",
repository = "gcr.io/pixie-oss/pixie-dev/src/e2e_test/profiler_loadtest/profiler_loadtest_golang",
tag = "{STABLE_BUILD_TAG}",
tags = ["manual"],
)
28 changes: 28 additions & 0 deletions src/e2e_test/profiler_loadtest/k8s/go_loadtest_deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: server
namespace: px-profiler-loadtest
spec:
replicas: 1
selector:
matchLabels:
name: go-app
template:
metadata:
labels:
name: go-app
spec:
containers:
- name: app
image: gcr.io/pixie-oss/pixie-dev/src/e2e_test/profiler_loadtest/profiler_loadtest_golang:latest
env:
- name: NUM_GOROUTINES
value: "50"
- name: PAUSE_TIME_NS
value: "100000"
- name: NUM_FUNCTIONS
value: "5"
- name: CALL_STACK_DEPTH
value: "30"
6 changes: 6 additions & 0 deletions src/e2e_test/profiler_loadtest/k8s/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: px-profiler-loadtest
resources:
- go_loadtest_deployment.yaml
17 changes: 17 additions & 0 deletions src/e2e_test/profiler_loadtest/skaffold_loadtest.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
apiVersion: skaffold/v2alpha3
kind: Config
build:
artifacts:
- image: gcr.io/pixie-oss/pixie-dev/src/e2e_test/profiler_loadtest/profiler_loadtest_golang
context: .
bazel:
target: //src/e2e_test/profiler_loadtest/go:profiler_loadtest_golang_image.tar
tagPolicy:
dateTime: {}
local:
push: true
deploy:
kustomize:
paths:
- k8s/

0 comments on commit 4993c43

Please sign in to comment.