Skip to content
Snippets Groups Projects
Commit c28f9a1d authored by Lorenz Boguhn's avatar Lorenz Boguhn
Browse files

Merge branch 'master' of git.se.informatik.uni-kiel.de:she/theodolite into...

Merge branch 'master' of git.se.informatik.uni-kiel.de:she/theodolite into feature/281-Add-Beam-Kubernetes-Benchmark-Definitions
parents 591ddf1c c4283e7b
No related branches found
No related tags found
1 merge request!218Add Beam Kubernetes Benchmark Definitions
Pipeline #6127 passed
Showing
with 10753 additions and 309 deletions
...@@ -41,6 +41,60 @@ default: ...@@ -41,6 +41,60 @@ default:
- /kaniko/executor --context `pwd`/$CONTEXT $KANIKO_DOCKERFILE $KANIKO_D - /kaniko/executor --context `pwd`/$CONTEXT $KANIKO_DOCKERFILE $KANIKO_D
# Theodolite Docs
.docs:
image: alpine/bundle:3.0.3
cache:
paths:
- docs/vendor
before_script:
- cd docs
- bundle config set --local path 'vendor'
- bundle install
rules:
- changes:
- docs/**/*
- when: manual
allow_failure: true
build-docs:
stage: build
extends: .docs
script: bundle exec jekyll build
artifacts:
paths:
- docs/_site
test-docs-links:
stage: test
extends: .docs
needs:
- build-docs
script: bundle exec htmlproofer --assume-extension --allow_hash_href ./_site
test-docs-crds-regression:
stage: test
image: golang
before_script:
- cd docs
- go install fybrik.io/crdoc@latest
script:
- crdoc --resources ../theodolite/crd/ --template api-reference/crds.tmpl --output api-reference/crds.ref.md
- cmp api-reference/crds.md api-reference/crds.ref.md
artifacts:
when: on_failure
paths:
- docs/api-reference/crds.ref.md
expire_in: 1 week
rules:
- changes:
- docs/api-reference/crds.tmpl
- theodolite/crd/**/*
- when: manual
allow_failure: true
# Theodolite Helm Chart # Theodolite Helm Chart
lint-helm: lint-helm:
...@@ -89,6 +143,7 @@ test-benchmarks: ...@@ -89,6 +143,7 @@ test-benchmarks:
- build-benchmarks - build-benchmarks
script: ./gradlew test --continue script: ./gradlew test --continue
artifacts: artifacts:
when: always
reports: reports:
junit: junit:
- "theodolite-benchmarks/**/build/test-results/test/TEST-*.xml" - "theodolite-benchmarks/**/build/test-results/test/TEST-*.xml"
...@@ -319,8 +374,10 @@ build-theodolite-jvm: ...@@ -319,8 +374,10 @@ build-theodolite-jvm:
script: ./gradlew --build-cache assemble script: ./gradlew --build-cache assemble
artifacts: artifacts:
paths: paths:
- "theodolite/build/lib/*" - "theodolite/build/quarkus-app/lib/"
- "theodolite/build/*-runner.jar" - "theodolite/build/quarkus-app/*.jar"
- "theodolite/build/quarkus-app/app/"
- "theodolite/build/quarkus-app/quarkus/"
expire_in: 6 hours expire_in: 6 hours
build-theodolite-native: build-theodolite-native:
...@@ -342,6 +399,7 @@ test-theodolite: ...@@ -342,6 +399,7 @@ test-theodolite:
#- build-theodolite-native #- build-theodolite-native
script: ./gradlew test --stacktrace script: ./gradlew test --stacktrace
artifacts: artifacts:
when: always
reports: reports:
junit: junit:
- "theodolite/**/build/test-results/test/TEST-*.xml" - "theodolite/**/build/test-results/test/TEST-*.xml"
...@@ -420,6 +478,22 @@ test-slo-checker-dropped-records-kstreams: ...@@ -420,6 +478,22 @@ test-slo-checker-dropped-records-kstreams:
- when: manual - when: manual
allow_failure: true allow_failure: true
test-slo-checker-generic:
stage: test
needs: []
image: python:3.7-slim
before_script:
- cd slo-checker/generic
script:
- pip install -r requirements.txt
- cd app
- python -m unittest
rules:
- changes:
- slo-checker/generic/**/*
- when: manual
allow_failure: true
deploy-slo-checker-lag-trend: deploy-slo-checker-lag-trend:
stage: deploy stage: deploy
extends: extends:
...@@ -456,6 +530,24 @@ deploy-slo-checker-dropped-records-kstreams: ...@@ -456,6 +530,24 @@ deploy-slo-checker-dropped-records-kstreams:
when: manual when: manual
allow_failure: true allow_failure: true
deploy-slo-checker-generic:
stage: deploy
extends:
- .kaniko-push
needs:
- test-slo-checker-generic
before_script:
- cd slo-checker/generic
variables:
IMAGE_NAME: theodolite-slo-checker-generic
rules:
- changes:
- slo-checker/generic/**/*
if: "$CR_HOST && $CR_ORG && $CR_USER && $CR_PW"
- if: "$CR_HOST && $CR_ORG && $CR_USER && $CR_PW"
when: manual
allow_failure: true
# Theodolite Random Scheduler # Theodolite Random Scheduler
......
...@@ -8,7 +8,7 @@ authors: ...@@ -8,7 +8,7 @@ authors:
given-names: Wilhelm given-names: Wilhelm
orcid: "https://orcid.org/0000-0001-6625-4335" orcid: "https://orcid.org/0000-0001-6625-4335"
title: Theodolite title: Theodolite
version: "0.5.1" version: "0.6.1"
repository-code: "https://github.com/cau-se/theodolite" repository-code: "https://github.com/cau-se/theodolite"
license: "Apache-2.0" license: "Apache-2.0"
doi: "10.1016/j.bdr.2021.100209" doi: "10.1016/j.bdr.2021.100209"
......
../analysis/requirements.txt
\ No newline at end of file
...@@ -5,16 +5,20 @@ ...@@ -5,16 +5,20 @@
"codeRepository": "https://github.com/cau-se/theodolite", "codeRepository": "https://github.com/cau-se/theodolite",
"dateCreated": "2020-03-13", "dateCreated": "2020-03-13",
"datePublished": "2020-07-27", "datePublished": "2020-07-27",
"dateModified": "2021-11-12", "dateModified": "2022-01-17",
"downloadUrl": "https://github.com/cau-se/theodolite/releases", "downloadUrl": "https://github.com/cau-se/theodolite/releases",
"name": "Theodolite", "name": "Theodolite",
"version": "0.5.1", "version": "0.6.1",
"description": "Theodolite is a framework for benchmarking the horizontal and vertical scalability of stream processing engines.", "description": "Theodolite is a framework for benchmarking the horizontal and vertical scalability of cloud-native applications.",
"developmentStatus": "active", "developmentStatus": "active",
"relatedLink": [
"https://www.theodolite.rocks"
],
"referencePublication": "https://doi.org/10.1016/j.bdr.2021.100209", "referencePublication": "https://doi.org/10.1016/j.bdr.2021.100209",
"programmingLanguage": [ "programmingLanguage": [
"Python", "Kotlin",
"Java" "Java",
"Python"
], ],
"runtimePlatform": [ "runtimePlatform": [
"Kubernetes" "Kubernetes"
......
_site
.sass-cache
.jekyll-cache
.jekyll-metadata
vendor
source "https://rubygems.org"
# Hello! This is where you manage which Jekyll version is used to run.
# When you want to use a different version, change it below, save the
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
#
# bundle exec jekyll serve
#
# This will help ensure the proper Jekyll version is running.
# Happy Jekylling!
#gem "jekyll", "~> 4.2.0"
# This is the default theme for new Jekyll sites. You may change this to anything you like.
gem "minima", "~> 2.5"
# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
# uncomment the line below. To upgrade, run `bundle update github-pages`.
# gem "github-pages", group: :jekyll_plugins
gem "github-pages", "~> 215", group: :jekyll_plugins
# If you have any plugins, put them here!
#group :jekyll_plugins do
#gem "jekyll-feed", "~> 0.12"
#end
gem 'html-proofer'
# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
# and associated library.
platforms :mingw, :x64_mingw, :mswin, :jruby do
gem "tzinfo", "~> 1.2"
gem "tzinfo-data"
end
# Performance-booster for watching directories on Windows
gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin]
GEM
remote: https://rubygems.org/
specs:
activesupport (6.0.4)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
tzinfo (~> 1.1)
zeitwerk (~> 2.2, >= 2.2.2)
addressable (2.8.0)
public_suffix (>= 2.0.2, < 5.0)
coffee-script (2.4.1)
coffee-script-source
execjs
coffee-script-source (1.11.1)
colorator (1.1.0)
commonmarker (0.17.13)
ruby-enum (~> 0.5)
concurrent-ruby (1.1.9)
dnsruby (1.61.7)
simpleidn (~> 0.1)
em-websocket (0.5.2)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0.6.0)
ethon (0.14.0)
ffi (>= 1.15.0)
eventmachine (1.2.7)
execjs (2.8.1)
faraday (1.4.3)
faraday-em_http (~> 1.0)
faraday-em_synchrony (~> 1.0)
faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
ruby2_keywords (>= 0.0.4)
faraday-em_http (1.0.0)
faraday-em_synchrony (1.0.0)
faraday-excon (1.1.0)
faraday-net_http (1.0.1)
faraday-net_http_persistent (1.1.0)
ffi (1.15.3)
forwardable-extended (2.6.0)
gemoji (3.0.1)
github-pages (215)
github-pages-health-check (= 1.17.2)
jekyll (= 3.9.0)
jekyll-avatar (= 0.7.0)
jekyll-coffeescript (= 1.1.1)
jekyll-commonmark-ghpages (= 0.1.6)
jekyll-default-layout (= 0.1.4)
jekyll-feed (= 0.15.1)
jekyll-gist (= 1.5.0)
jekyll-github-metadata (= 2.13.0)
jekyll-mentions (= 1.6.0)
jekyll-optional-front-matter (= 0.3.2)
jekyll-paginate (= 1.1.0)
jekyll-readme-index (= 0.3.0)
jekyll-redirect-from (= 0.16.0)
jekyll-relative-links (= 0.6.1)
jekyll-remote-theme (= 0.4.3)
jekyll-sass-converter (= 1.5.2)
jekyll-seo-tag (= 2.7.1)
jekyll-sitemap (= 1.4.0)
jekyll-swiss (= 1.0.0)
jekyll-theme-architect (= 0.1.1)
jekyll-theme-cayman (= 0.1.1)
jekyll-theme-dinky (= 0.1.1)
jekyll-theme-hacker (= 0.1.2)
jekyll-theme-leap-day (= 0.1.1)
jekyll-theme-merlot (= 0.1.1)
jekyll-theme-midnight (= 0.1.1)
jekyll-theme-minimal (= 0.1.1)
jekyll-theme-modernist (= 0.1.1)
jekyll-theme-primer (= 0.5.4)
jekyll-theme-slate (= 0.1.1)
jekyll-theme-tactile (= 0.1.1)
jekyll-theme-time-machine (= 0.1.1)
jekyll-titles-from-headings (= 0.5.3)
jemoji (= 0.12.0)
kramdown (= 2.3.1)
kramdown-parser-gfm (= 1.1.0)
liquid (= 4.0.3)
mercenary (~> 0.3)
minima (= 2.5.1)
nokogiri (>= 1.10.4, < 2.0)
rouge (= 3.26.0)
terminal-table (~> 1.4)
github-pages-health-check (1.17.2)
addressable (~> 2.3)
dnsruby (~> 1.60)
octokit (~> 4.0)
public_suffix (>= 2.0.2, < 5.0)
typhoeus (~> 1.3)
html-pipeline (2.14.0)
activesupport (>= 2)
nokogiri (>= 1.4)
html-proofer (3.19.2)
addressable (~> 2.3)
mercenary (~> 0.3)
nokogumbo (~> 2.0)
parallel (~> 1.3)
rainbow (~> 3.0)
typhoeus (~> 1.3)
yell (~> 2.0)
http_parser.rb (0.6.0)
i18n (0.9.5)
concurrent-ruby (~> 1.0)
jekyll (3.9.0)
addressable (~> 2.4)
colorator (~> 1.0)
em-websocket (~> 0.5)
i18n (~> 0.7)
jekyll-sass-converter (~> 1.0)
jekyll-watch (~> 2.0)
kramdown (>= 1.17, < 3)
liquid (~> 4.0)
mercenary (~> 0.3.3)
pathutil (~> 0.9)
rouge (>= 1.7, < 4)
safe_yaml (~> 1.0)
jekyll-avatar (0.7.0)
jekyll (>= 3.0, < 5.0)
jekyll-coffeescript (1.1.1)
coffee-script (~> 2.2)
coffee-script-source (~> 1.11.1)
jekyll-commonmark (1.3.1)
commonmarker (~> 0.14)
jekyll (>= 3.7, < 5.0)
jekyll-commonmark-ghpages (0.1.6)
commonmarker (~> 0.17.6)
jekyll-commonmark (~> 1.2)
rouge (>= 2.0, < 4.0)
jekyll-default-layout (0.1.4)
jekyll (~> 3.0)
jekyll-feed (0.15.1)
jekyll (>= 3.7, < 5.0)
jekyll-gist (1.5.0)
octokit (~> 4.2)
jekyll-github-metadata (2.13.0)
jekyll (>= 3.4, < 5.0)
octokit (~> 4.0, != 4.4.0)
jekyll-mentions (1.6.0)
html-pipeline (~> 2.3)
jekyll (>= 3.7, < 5.0)
jekyll-optional-front-matter (0.3.2)
jekyll (>= 3.0, < 5.0)
jekyll-paginate (1.1.0)
jekyll-readme-index (0.3.0)
jekyll (>= 3.0, < 5.0)
jekyll-redirect-from (0.16.0)
jekyll (>= 3.3, < 5.0)
jekyll-relative-links (0.6.1)
jekyll (>= 3.3, < 5.0)
jekyll-remote-theme (0.4.3)
addressable (~> 2.0)
jekyll (>= 3.5, < 5.0)
jekyll-sass-converter (>= 1.0, <= 3.0.0, != 2.0.0)
rubyzip (>= 1.3.0, < 3.0)
jekyll-sass-converter (1.5.2)
sass (~> 3.4)
jekyll-seo-tag (2.7.1)
jekyll (>= 3.8, < 5.0)
jekyll-sitemap (1.4.0)
jekyll (>= 3.7, < 5.0)
jekyll-swiss (1.0.0)
jekyll-theme-architect (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-cayman (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-dinky (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-hacker (0.1.2)
jekyll (> 3.5, < 5.0)
jekyll-seo-tag (~> 2.0)
jekyll-theme-leap-day (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-merlot (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-midnight (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-minimal (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-modernist (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-primer (0.5.4)
jekyll (> 3.5, < 5.0)
jekyll-github-metadata (~> 2.9)
jekyll-seo-tag (~> 2.0)
jekyll-theme-slate (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-tactile (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-theme-time-machine (0.1.1)
jekyll (~> 3.5)
jekyll-seo-tag (~> 2.0)
jekyll-titles-from-headings (0.5.3)
jekyll (>= 3.3, < 5.0)
jekyll-watch (2.2.1)
listen (~> 3.0)
jemoji (0.12.0)
gemoji (~> 3.0)
html-pipeline (~> 2.2)
jekyll (>= 3.0, < 5.0)
kramdown (2.3.1)
rexml
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
liquid (4.0.3)
listen (3.5.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
mercenary (0.3.6)
minima (2.5.1)
jekyll (>= 3.5, < 5.0)
jekyll-feed (~> 0.9)
jekyll-seo-tag (~> 2.1)
minitest (5.14.4)
multipart-post (2.1.1)
nokogiri (1.13.0-x86_64-linux)
racc (~> 1.4)
nokogumbo (2.0.5)
nokogiri (~> 1.8, >= 1.8.4)
octokit (4.21.0)
faraday (>= 0.9)
sawyer (~> 0.8.0, >= 0.5.3)
parallel (1.21.0)
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (4.0.6)
racc (1.6.0)
rainbow (3.0.0)
rb-fsevent (0.11.0)
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.5)
rouge (3.26.0)
ruby-enum (0.9.0)
i18n
ruby2_keywords (0.0.4)
rubyzip (2.3.0)
safe_yaml (1.0.5)
sass (3.7.4)
sass-listen (~> 4.0.0)
sass-listen (4.0.0)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
sawyer (0.8.2)
addressable (>= 2.3.5)
faraday (> 0.8, < 2.0)
simpleidn (0.2.1)
unf (~> 0.1.4)
terminal-table (1.8.0)
unicode-display_width (~> 1.1, >= 1.1.1)
thread_safe (0.3.6)
typhoeus (1.4.0)
ethon (>= 0.9.0)
tzinfo (1.2.9)
thread_safe (~> 0.1)
unf (0.1.4)
unf_ext
unf_ext (0.0.7.7)
unicode-display_width (1.7.0)
yell (2.2.2)
zeitwerk (2.4.2)
PLATFORMS
x86_64-linux
x86_64-linux-musl
DEPENDENCIES
github-pages (~> 215)
html-proofer
minima (~> 2.5)
tzinfo (~> 1.2)
tzinfo-data
wdm (~> 0.1.1)
BUNDLED WITH
2.2.21
--- # Theodolite Docs
title: Theodolite
nav_order: 1
permalink: /
---
# Theodolite Theodolite's docs are generated with Jekyll from Markdown files.
> A theodolite is a precision optical instrument for measuring angles between designated visible points in the horizontal and vertical planes. -- <cite>[Wikipedia](https://en.wikipedia.org/wiki/Theodolite)</cite> ## Installation
Theodolite is a framework for benchmarking the horizontal and vertical scalability of stream processing engines. It consists of three modules: To set up Jekyll run:
## Theodolite Benchmarking Tool ```sh
gem install bundler
bundle config set --local path 'vendor'
bundle install
```
Theodolite aims to benchmark scalability of stream processing engines for real use cases. Microservices that apply stream processing techniques are usually deployed in elastic cloud environments. Hence, Theodolite's cloud-native benchmarking framework deploys its components in a cloud environment, orchestrated by Kubernetes. It is recommended to install Theodolite with the package manager Helm. The Theodolite Helm chart along with instructions how to install it can be found in the [`helm`](helm) directory. ## Local Testing
## Theodolite Analysis Tools For live serving the docs run:
Theodolite's benchmarking method maps load intensities to the resource amounts that are required for processing them. A plot showing how resource demand evolves with an increasing load allows to draw conclusions about the scalability of a stream processing engine or its deployment. Theodolite provides Jupyter notebooks for creating such plots based on benchmarking results from the execution framework. More information can be found in [Theodolite analysis tool](analysis). ```sh
bundle exec jekyll serve
```
## Theodolite Benchmarks ## Building
Theodolite comes with 4 application benchmarks, which are based on typical use cases for stream processing within microservices. For each benchmark, a corresponding load generator is provided. Currently, this repository provides benchmark implementations for Apache Kafka Streams and Apache Flink. The benchmark sources can be found in [Thedolite benchmarks](theodolite-benchmarks). You can compile everything to HTML via:
## How to Cite ```sh
bundle exec jekyll build
```
If you use Theodolite, please cite ## CRD API Reference
> Sören Henning and Wilhelm Hasselbring. (2021). Theodolite: Scalability Benchmarking of Distributed Stream Processing Engines in Microservice Architectures. Big Data Research, Volume 25. DOI: [10.1016/j.bdr.2021.100209](https://doi.org/10.1016/j.bdr.2021.100209). arXiv:[2009.00304](https://arxiv.org/abs/2009.00304). We use the [crdoc](https://github.com/fybrik/crdoc) tool to generate the API reference for our CRDs:
```sh
crdoc --resources ../theodolite/crd/ --template api-reference/crds.tmpl --output api-reference/crds.md
```
With the following command, crdoc is executed in Docker:
```sh
docker run --rm -v "`pwd`/../theodolite/crd/":/crd -u $UID -v "`pwd`/api-reference":/api-reference ghcr.io/fybrik/crdoc:0.6.0 --resources /crd/ --template /api-reference/crds.tmpl --output /api-reference/crds.md
```
title: "Theodolite" title: "Theodolite"
description: >-
Theodolite is a framework for benchmarking the horizontal and vertical
scalability of cloud-native applications.
remote_theme: pmarsceill/just-the-docs remote_theme: pmarsceill/just-the-docs
#color_scheme: "dark"
aux_links: aux_links:
"Theodolite on GitHub": "Theodolite on GitHub":
- "//github.com/cau-se/theodolite" - "//github.com/cau-se/theodolite"
\ No newline at end of file
exclude:
- "*.tmpl"
- Gemfile
- Gemfile.lock
- README.md
- vendor/
- drafts/
.theodolite-logo {
height: 18em;
}
\ No newline at end of file
This diff is collapsed.
---
title: Theodolite CRDs
has_children: false
parent: API Reference
nav_order: 1
---
# API Reference
Packages:
{{range .Groups}}
- [{{.Group}}/{{.Version}}](#{{ anchorize (printf "%s/%s" .Group .Version) }})
{{- end -}}{{/* range .Groups */}}
{{- range .Groups }}
{{- $group := . }}
# {{.Group}}/{{.Version}}
Resource Types:
{{range .Kinds}}
- [{{.Name}}](#{{ anchorize .Name }})
{{end}}{{/* range .Kinds */}}
{{range .Kinds}}
{{$kind := .}}
## {{.Name}}
<sup><sup>[↩ Parent](#{{ anchorize (printf "%s/%s" $group.Group $group.Version) }} )</sup></sup>
{{range .Types}}
{{if not .IsTopLevel}}
### {{.Name}}
{{if .ParentKey}}<sup><sup>[↩ Parent](#{{.ParentKey}})</sup></sup>{{end}}
{{end}}
{{.Description}}
<table>
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
<th>Required</th>
</tr>
</thead>
<tbody>
{{- if .IsTopLevel -}}
<tr>
<td><b>apiVersion</b></td>
<td>string</td>
<td>{{$group.Group}}/{{$group.Version}}</td>
<td>true</td>
</tr>
<tr>
<td><b>kind</b></td>
<td>string</td>
<td>{{$kind.Name}}</td>
<td>true</td>
</tr>
<tr>
<td><b><a href="https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.20/#objectmeta-v1-meta">metadata</a></b></td>
<td>object</td>
<td>Refer to the Kubernetes API documentation for the fields of the `metadata` field.</td>
<td>true</td>
</tr>
{{- end -}}
{{- range .Fields -}}
<tr>
<td><b>{{if .TypeKey}}<a href="#{{.TypeKey}}">{{.Name}}</a>{{else}}{{.Name}}{{end}}</b></td>
<td>{{.Type}}</td>
<td>
{{.Description}}<br/>
{{- if or .Schema.Format .Schema.Enum .Schema.Default .Schema.Minimum .Schema.Maximum }}
<br/>
{{- end}}
{{- if .Schema.Format }}
<i>Format</i>: {{ .Schema.Format }}<br/>
{{- end }}
{{- if .Schema.Enum }}
<i>Enum</i>: {{ .Schema.Enum | toStrings | join ", " }}<br/>
{{- end }}
{{- if .Schema.Default }}
<i>Default</i>: {{ .Schema.Default }}<br/>
{{- end }}
{{- if .Schema.Minimum }}
<i>Minimum</i>: {{ .Schema.Minimum }}<br/>
{{- end }}
{{- if .Schema.Maximum }}
<i>Maximum</i>: {{ .Schema.Maximum }}<br/>
{{- end }}
</td>
<td>{{.Required}}</td>
</tr>
{{- end -}}
</tbody>
</table>
{{- end}}{{/* range .Types */}}
{{- end}}{{/* range .Kinds */}}
{{- end}}{{/* range .Groups */}}
\ No newline at end of file
---
title: API Reference
has_children: true
nav_order: 9
---
\ No newline at end of file
## Patchers ---
title: Patchers
has_children: false
parent: API Reference
nav_order: 2
---
* **ReplicaPatcher**: Allows to modify the number of Replicas for a kubernetes deployment. # Patchers
Patchers can be seen as functions which take a value as input and modify a Kubernetes resource in a patcher-specific way.
## Available Patchers
* **ReplicaPatcher**: Modifies the number of replicas for a Kubernetes deployment.
* **type**: "ReplicaPatcher" * **type**: "ReplicaPatcher"
* **resource**: "uc1-kstreams-deployment.yaml" * **resource**: "uc1-kstreams-deployment.yaml"
* **NumSensorsLoadGeneratorReplicaPatcher**: Allows to scale the nummer of load generators. Scales arcording to the following formular: (value + 15_000 - 1) / 15_000 * **NumSensorsLoadGeneratorReplicaPatcher**: Modifies the number of load generators, according to the following formula: *(value + loadGenMaxRecords - 1) / loadGenMaxRecords*
* **type**: "NumSensorsLoadGeneratorReplicaPatcher" * **type**: "NumSensorsLoadGeneratorReplicaPatcher"
* **resource**: "uc1-load-generator-deployment.yaml" * **resource**: "uc1-load-generator-deployment.yaml"
* **properties**:
* loadGenMaxRecords: 150000
* **NumNestedGroupsLoadGeneratorReplicaPatcher**: Allows to scale the nummer of load generators. Scales arcording to the following formular: (4^(value) + 15_000 -1) /15_000 * **NumNestedGroupsLoadGeneratorReplicaPatcher**: Modifies the number of load generators, according to the following formula: *(4^(value) + loadGenMaxRecords - 1) / loadGenMaxRecords*
* **type**: "NumNestedGroupsLoadGeneratorReplicaPatcher" * **type**: "NumNestedGroupsLoadGeneratorReplicaPatcher"
* **resource**: "uc1-load-generator-deployment.yaml" * **resource**: "uc1-load-generator-deployment.yaml"
* **properties**:
* loadGenMaxRecords: 150000
* **ReplicaPatcher**: Allows to modify the number of Replicas for a kubernetes deployment. * **EnvVarPatcher**: Modifies the value of an environment variable for a container in a Kubernetes deployment.
* **type**: "ReplicaPatcher"
* **resource**: "uc1-kstreams-deployment.yaml"
* **EnvVarPatcher**: Allows to modify the value of an environment variable for a container in a kubernetes deployment.
* **type**: "EnvVarPatcher" * **type**: "EnvVarPatcher"
* **resource**: "uc1-load-generator-deployment.yaml" * **resource**: "uc1-load-generator-deployment.yaml"
* **properties**: * **properties**:
* container: "workload-generator" * container: "workload-generator"
* variableName: "NUM_SENSORS" * variableName: "NUM_SENSORS"
* **NodeSelectorPatcher**: Changes the node selection field in kubernetes resources. * **NodeSelectorPatcher**: Changes the node selection field in Kubernetes resources.
* **type**: "NodeSelectorPatcher" * **type**: "NodeSelectorPatcher"
* **resource**: "uc1-load-generator-deployment.yaml" * **resource**: "uc1-load-generator-deployment.yaml"
* **properties**: * **properties**:
* variableName: "env" * variableName: "env"
* **value**: "prod" * **example value**: "prod"
* **ResourceLimitPatcher**: Changes the resource limit for a kubernetes resource. * **ResourceLimitPatcher**: Changes the resource limit for a Kubernetes resource.
* **resource**: "uc1-kstreams-deployment.yaml" * **resource**: "uc1-kstreams-deployment.yaml"
* **properties**: * **properties**:
* container: "uc-application" * container: "uc-application"
* variableName: "cpu" or "memory" * variableName: "cpu" or "memory"
* **value**:"1000m" or "2Gi" * **example value**:"1000m" or "2Gi"
* **SchedulerNamePatcher**: Changes the sheduler for kubernetes resources. * **SchedulerNamePatcher**: Changes the scheduler for Kubernetes resources.
* **type**: "SchedulerNamePatcher" * **type**: "SchedulerNamePatcher"
* **resource**: "uc1-kstreams-deployment.yaml" * **resource**: "uc1-kstreams-deployment.yaml"
* **value**: "random-scheduler" * **example value**: "random-scheduler"
* **ImagePatcher**: Changes the image of a kubernetes resource. Currently not fully implemented. * **ImagePatcher**: Changes the image of a Kubernetes resource. **Currently not fully implemented.**
* **type**: "ImagePatcher" * **type**: "ImagePatcher"
* **resource**: "uc1-kstreams-deployment.yaml" * **resource**: "uc1-kstreams-deployment.yaml"
* **properties**: * **properties**:
* container: "uc-application" * container: "uc-application"
* **value**: "dockerhubrepo/imagename" * **example value**: "dockerhub-org/image-name"
This diff is collapsed.
This diff is collapsed.
---
title: Fundamental Concepts
has_children: false
nav_order: 2
---
# Benchmarks and Executions
In Theodolite, we distinguish between the static description of a scalability benchmark and its execution.
## Benchmarks
Benchmarks define what should be executed in scalability experiments. They
consist of a system under test (SUT) and an associated load generator, where
both SUT and load generator are represented as sets of Kubernetes resources
such as Pods, Services, or ConfigMaps.
Additionally, benchmarks define one or more load and resource types, scalability
can be evaluated for.
[TODO]: # (Link to metrics)
Benchmarks are portable, that is they can be provided by standardization
organizations, researchers, etc. and installed by other researchers,
engineers, etc.
They do not have a life-cycle. Instead, to run a benchmark, an execution of a
benchmark is created and passed to Theodolite.
## Execution
An execution represents a one-time execution of a benchmark with a
specific configuration. Hence, an execution refers to a benchmark and one of
the load and resource types defined by that benchmark. Additionally, executions
allow to alter the SUT or the load generator to evaluate regarding specific
configurations.
Executions also describe details regarding the scalability measurement method,
such as for long experiment should be performed or how often they should be
repeated.
In contrast to benchmarks, execution have a life-cycle. They can be planned,
executed, or aborted. Each execution of a benchmark is represented by an
individual entity. This supports repeatability as executions can be archived
and shared.
---
title: Creating Benchmarks
has_children: false
nav_order: 5
---
# Creating a Benchmark
Please note that to simply run a benchmark, it is not required to define one. Theodolite comes with a [set of benchmarks](theodolite-benchmarks), which are ready to be executed. See the [fundamental concepts](benchmarks-and-executions) page to learn more about our distinction between benchmarks and executions.
A typical benchmark looks like this:
```yaml
apiVersion: theodolite.com/v1
kind: benchmark
metadata:
name: example-benchmark
spec:
sut:
resources:
- configMap:
name: "example-configmap"
files:
- "uc1-kstreams-deployment.yaml"
loadGenerator:
resources:
- configMap:
name: "example-configmap"
files:
- uc1-load-generator-service.yaml
- uc1-load-generator-deployment.yaml
loadTypes:
- typeName: "NumSensors"
patchers:
- type: "EnvVarPatcher"
resource: "uc1-load-generator-deployment.yaml"
properties:
variableName: "NUM_SENSORS"
container: "workload-generator"
- type: "NumSensorsLoadGeneratorReplicaPatcher"
resource: "uc1-load-generator-deployment.yaml"
properties:
loadGenMaxRecords: "150000"
kafkaConfig:
bootstrapServer: "theodolite-cp-kafka:9092"
topics:
- name: "input"
numPartitions: 40
replicationFactor: 1
- name: "theodolite-.*"
removeOnly: True
```
## System under Test (SUT), Load Generator and Infrastructure
In Thedolite, the system under test (SUT), the load generator as well as additional infrastructure (e.g., a middleware) are described by Kubernetes resources files.
All resources defined for the SUT and the load generator are started and stopped for each SLO experiment, with SUT resources being started before the load generator.
Infrastructure resources live over the entire duration of a benchmark run. They avoid time-consuming recreation of software components like middlewares, but should be used with caution to not let previous SLO experiments influence latte ones.
### Resources
#### ConfigMap
The recommended way to link Kubernetes resources files from a Benchmark is by bundling them in one or multiple ConfigMaps and refer to that ConfigMap from `sut.resources`, `loadGenerator.resources` or `infrastructure.resources`.
To create a ConfigMap from all the Kubernetes resources in a directory run:
```sh
kubectl create configmap <configmap-name> --from-file=<path-to-resource-dir>
```
Add an item such as the following one to the `resources` list of the `sut`, `loadGenerator` or `infrastructure` fields.
```yaml
configMap:
name: example-configmap
files:
- example-deployment.yaml
- example-service.yaml
```
#### Filesystem
Alternatively, resources can also be read from the filesystem, Theodolite has access to. This usually requires that the Benchmark resources are available in a volume, which is mounted into the Theodolite container.
```yaml
filesystem:
path: example/path/to/files
files:
- example-deployment.yaml
- example-service.yaml
```
<!-- ### Before and after actions -->
<!--
A Benchmark refers to other Kubernetes resources (e.g., Deployments, Services, ConfigMaps), which describe the system under test, the load generator and infrastructure components such as a middleware used in the benchmark. To manage those resources, Theodolite needs to have access to them. This is done by bundling resources in ConfigMaps.
Suppose the resources needed by your benchmark are defined as YAML files, located in the `resources` directory. You can put them into the ConfigMap `benchmark-resources-custom` by running:
-->
## Load and Resource Types
Benchmarks need to specify at least one supported load and resource type for which scalability can be benchmarked.
Load and resource types are described by a name (used for reference from an Execution) and a list of patchers.
Patchers can be seen as functions, which take a value as input and modify a Kubernetes resource in a patcher-specific way. Examples of patchers are the *ReplicaPatcher*, which modifies the replica specification of a deployment, or the *EnvVarPatcher*, which modifies an environment variable.
See the [patcher API reference](api-reference/patchers) for an overview of available patchers.
If a benchmark is [executed by an Execution](running-benchmarks), these patchers are used to configure SUT and load generator according to the [load and resource values](creating-an-execution) set in the Execution.
## Kafka Configuration
Theodolite allows to automatically create and remove Kafka topics for each SLO experiment.
Use the `removeOnly: True` property for topics which are created automatically by the SUT.
For those topics, also wildcards are allowed in the topic name.
If no Kafka topics should be created, simply set:
```yaml
kafkaConfig: []
```
<!-- Further information: API Reference -->
<!-- Further information: How to deploy -->
---
title: Creating an Execution
has_children: false
parent: Running Benchmarks
nav_order: 6
---
# Creating an Execution
Theodolite Executions look similar to the following example.
<!-- TODO align with upstream -->
```yaml
apiVersion: theodolite.com/v1
kind: execution
metadata:
name: theodolite-example-execution
spec:
benchmark: "uc1-kstreams"
load:
loadType: "NumSensors"
loadValues: [25000, 50000]
resources:
resourceType: "Instances"
resourceValues: [1, 2]
slos:
- sloType: "lag trend"
prometheusUrl: "http://prometheus-operated:9090"
offset: 0
properties:
threshold: 2000
externalSloUrl: "http://localhost:80/evaluate-slope"
warmup: 60 # in seconds
execution:
strategy: "LinearSearch"
duration: 300 # in seconds
repetitions: 1
loadGenerationDelay: 30 # in seconds
restrictions:
- "LowerBound"
configOverrides:
- patcher:
type: "SchedulerNamePatcher"
resource: "uc1-kstreams-deployment.yaml"
value: "random-scheduler"
```
## Naming and Labeling
Similar to [Kubernetes Jobs](https://kubernetes.io/docs/concepts/workloads/controllers/job/), Theodolite Executions are not automatically deleted after they are finished. Therefore, it is recommended to choose a meaningful name for your Execution. Additionally, you can add labels to your Executions as with any other Kubernetes resource.
## Reference to a Benchmark
An Execution always refers to a Benchmark. For the Execution to run, the Benchmark must be registered with Kubernetes and it must be in state *Ready*. If this is not the case, the Execution will remain in state *Pending*.
As a Benchmark may define multiple supported load and resource types, an Execution has to pick exactly one of each by its name. Additionally, it defines the set of load values and resource values the benchmark should be executed with. Both these values are represented as integers, which are interpreted in a [Benchmark-specific way](creating-a-benchmark) to configure the SUT and load generator.
## Definition of SLOs
SLOs provide a way to quantify whether a certain load intensity can be handled by a certain amount of provisioned resources.
In Theodolite, SLO are evaluated by requesting monitoring data from Prometheus and analyzing it in a benchmark-specific way.
An Execution must at least define one SLO to be checked.
A good choice to get started is defining an SLO of type `generic`:
```yaml
- sloType: "generic"
prometheusUrl: "http://prometheus-operated:9090"
offset: 0
properties:
externalSloUrl: "http://localhost:8082"
promQLQuery: "sum by(job) (kafka_streams_stream_task_metrics_dropped_records_total>=0)"
warmup: 60 # in seconds
queryAggregation: max
repetitionAggregation: median
operator: lte
threshold: 1000
```
All you have to do is to define a [PromQL query](https://prometheus.io/docs/prometheus/latest/querying/basics/) describing which metrics should be requested (`promQLQuery`) and how the resulting time series should be evaluated. With `queryAggregation` you specify how the resulting time series is aggregated to a single value and `repetitionAggregation` describes how the results of multiple repetitions are aggregated. Possible values are
`mean`, `median`, `mode`, `sum`, `count`, `max`, `min`, `std`, `var`, `skew`, `kurt` as well as percentiles such as `p99` or `p99.9`. The result of aggregation all repetitions is checked against `threshold`. This check is performed using an `operator`, which describes that the result must be "less than" (`lt`), "less than equal" (`lte`), "greater than" (`gt`) or "greater than equal" (`gte`) to the threshold.
In case you need to evaluate monitoring data in a more flexible fashion, you can also change the value of `externalSloUrl` to your custom SLO checker. Have a look at the source code of the [generic SLO checker](https://github.com/cau-se/theodolite/tree/master/slo-checker/generic) to get started.
## Experimental Setup
According to Theodolite's measurement method, isolated SLO experiments are performed for different combinations of load intensity and resource amounts.
The experimental setup can be configured by:
* A search strategy (`strategy`), which determines which load and resource combinations should be tested. Supported values are `FullSearch`, `LinearSearch` and `BinarySearch`. Additionally, a `restrictions` can be set to `LowerBound`.
* The `duration` per SLO experiment in seconds.
* The number of repetitions (`repetitions`) for each SLO experiment.
* A `loadGenerationDelay`, specifying the time in seconds before the load generation starts.
## Configuration Overrides
In cases where only small modifications of a system under test should be benchmarked, it is not necessary to [create a new benchmark](creating-a-benchmark).
Instead, also Executions allow to do small reconfigurations, such as switching on or off a specific Pod scheduler.
This is done by defining `configOverrides` in the Execution. Each override consists of a patcher, defining which Kubernetes resource should be patched in which way, and a value the patcher is applied with.
<!-- Further information: API Reference -->
<!-- Further information: How to run -->
---
title: Development
has_children: true
nav_order: 8
---
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment