-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* introduce share-upload-rename use newest ocis apis and introduce api switch to classic apis * enable user after login * fix user import * add admin account login and password env variables * remove legacy parts update readme and add test manifest * provide URLSearchParams * improvement of the test explanation * fix test description * simplify test options * fix test description * fix test description * - added documentation how to execute the tests with docker * - added fail if authentication fails * update build artifacts remove husky * add basic surf like upload test * fix api version default value docs remove dollar sign in the bash examples cleanup Makefile * fix broken share create fail check make share upload rename test asset size and quantity configurable add more context to the surf upload test * minify tests * fix typo wrap k6 jslib remote imports mute k6 remote import rollup build warnings generate oidc logon request state update caniuse --------- Co-authored-by: Dennis Sieben <[email protected]>
- Loading branch information
Showing
60 changed files
with
1,639 additions
and
3,688 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,5 @@ | |
"trailingComma": "all", | ||
"singleQuote": true, | ||
"printWidth": 120, | ||
"tabWidth": 4 | ||
"tabWidth": 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,6 @@ | ||
.ONESHELL: | ||
ROOT_DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST)))) | ||
|
||
.PHONY: build | ||
build: | ||
docker build --tag owncloud/cdperf-k6 . | ||
docker run --rm --volume $(ROOT_DIR)/tests:/cp owncloud/cdperf-k6 cp -r . /cp | ||
chmod +x ./scripts/cdperf | ||
|
||
.PHONY: local | ||
local: clean | ||
yarn && yarn build | ||
|
||
.PHONY: clean | ||
clean: | ||
rm -rf ./tests | ||
|
||
.PHONY: changelog | ||
changelog: | ||
go run github.com/restic/calens -i ./changelog -t ./changelog/CHANGELOG.tmpl >| ./CHANGELOG.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,36 +11,8 @@ Supported clouds are: | |
* [Docker](https://docs.docker.com/) | ||
|
||
## Usage | ||
To see available options run ./scripts/cdperf --help | ||
|
||
```shell | ||
$ # build via docker | ||
$ make clean build | ||
$ | ||
$ # alternatively, build locally (requires node + yarn installed) | ||
$ make local | ||
$ | ||
$ # all available options | ||
$ ./scripts/cdperf --help | ||
$ | ||
$ # test with docker ocis and k6 | ||
$ ./scripts/cdperf --cloud-vendor=ocis --k6-test-host=https://host.docker.internal:9200 | ||
$ | ||
$ # test with local ocis and docker k6 | ||
$ ./scripts/cdperf --cloud-docker=false --cloud-vendor=ocis --k6-test-host=https://host.docker.internal:9200 | ||
$ | ||
$ # test with docker ocis and local k6 | ||
$ ./scripts/cdperf --cloud-vendor=ocis --k6-test-host=https://localhost:9200 --k6-docker=false | ||
$ | ||
$ # export test results to influxdb v1 | ||
$ ./scripts/cdperf --cloud-vendor=ocis --k6-test-host=https://host.docker.internal:9200 --k6-out=influxdb=http://admin:[email protected]:8086/k6 | ||
$ | ||
$ # export test results to influxdb v2 | ||
$ ./scripts/cdperf --cloud-vendor=ocis --k6-test-host=https://host.docker.internal:9200 --k6-out=xk6-influxdb=http://host.docker.internal:8086 --k6-influxdb-token="superlongadmintoken" | ||
$ | ||
$ # with cloud on remote docker host | ||
$ ./scripts/cdperf --cloud-docker-host=ssh://user@your-host --cloud-vendor=ocis --k6-test-host=https://your-host:9200 | ||
``` | ||
cdPerf is just a collection of prepared scripts which can used with k6 as described | ||
[here](https://k6.io/docs/get-started/running-k6/). | ||
|
||
## How to test | ||
It's important to know how to compare the tests against each other and what those numbers mean. | ||
|
@@ -61,24 +33,21 @@ We collect those metrics over time to get indicators of how the performance chan | |
|
||
**How to read the test results** | ||
|
||
Let's use 'test-issue-github-ocis-1018-propfind-flat.js' as an example. | ||
* Total time of execution | ||
* This is the total elapsed time of the test for all users and iterations | ||
* status | ||
* Red || Green is a quick overview of how many requests failed or not | ||
* cloud_default_play_$PLAYNAME$_$OPERATION$_$TYPE$ | ||
* PLAYNAME: name of the play, for example dav, users, ... | ||
* OPERATION: type of operation, for example create, delete, update, ... | ||
* TYPE: type of operation, for example trend (min, max, avg, ...) or error (count) | ||
|
||
Only those numbers should be considered for comparison. | ||
Don't forget to only compare same tests with same requirements. | ||
for a more detailed instruction how to read the results you should consider reading the k6 manual, | ||
specially the [end of test](https://k6.io/docs/results-output/end-of-test/) section. | ||
|
||
## Details | ||
|
||
Read more about [considerations](docs/considerations.md) of performance measurement. | ||
A precise description of what a test does and what the requirements are can be found in the respective test folder. | ||
|
||
Detailed descriptions about all tests are [available here](docs/tests.md). | ||
## Available tests | ||
* [share-upload-rename](src/tests/share-upload-rename/default.md) | ||
* [surf-upload](src/tests/surf/upload.md) | ||
|
||
## Dashboard | ||
To visualize the test results you need an influxdb and grafana instance running. | ||
|
@@ -95,5 +64,5 @@ Apache-2.0 | |
|
||
## Copyright | ||
```console | ||
Copyright (c) 2022 ownCloud GmbH <https://owncloud.com> | ||
Copyright (c) 2023 ownCloud GmbH <https://owncloud.com> | ||
``` |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,65 +1,54 @@ | ||
{ | ||
"name": "oc-k6", | ||
"version": "1.0.0", | ||
"main": "index.js", | ||
"license": "Apache-2.0", | ||
"author": { | ||
"name": "Florian Schade", | ||
"email": "[email protected]", | ||
"url": "https://owncloud.com" | ||
}, | ||
"scripts": { | ||
"build": "rollup -c", | ||
"build:w": "rollup -c -w", | ||
"clean": "rm -rf ./tests", | ||
"lint": "eslint './src/**/*.ts'", | ||
"lint:f": "yarn lint --fix", | ||
"depcheck": "depcheck" | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.{ts}": [ | ||
"eslint --fix" | ||
] | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "^7.9.0", | ||
"@babel/preset-env": "^7.9.5", | ||
"@babel/preset-typescript": "^7.9.0", | ||
"@rollup/plugin-commonjs": "^11.1.0", | ||
"@rollup/plugin-json": "^4.0.3", | ||
"@rollup/plugin-node-resolve": "^7.1.3", | ||
"@rollup/pluginutils": "^4.1.0", | ||
"@types/k6": "^0.35.2", | ||
"@types/lodash": "^4.14.165", | ||
"@types/xmldom": "^0.1.30", | ||
"@typescript-eslint/eslint-plugin": "^4.9.0", | ||
"@typescript-eslint/parser": "^4.9.0", | ||
"babel-plugin-lodash": "^3.3.4", | ||
"core-js": "3", | ||
"depcheck": "^1.3.1", | ||
"eslint": "^7.14.0", | ||
"eslint-config-prettier": "^6.15.0", | ||
"eslint-plugin-import": "^2.22.1", | ||
"eslint-plugin-prettier": "^3.2.0", | ||
"eslint-plugin-simple-import-sort": "^6.0.1", | ||
"husky": "^4.3.0", | ||
"k6": "^0.0.0", | ||
"lint-staged": "^10.1.7", | ||
"lodash": "^4.17.20", | ||
"prettier": "^2.2.1", | ||
"prettier-eslint": "^12.0.0", | ||
"rollup": "^2.7.2", | ||
"rollup-plugin-babel": "^4.4.0", | ||
"rollup-plugin-multi-input": "^1.1.1", | ||
"rollup-plugin-terser": "^5.3.0", | ||
"typescript": "^4.1.2" | ||
}, | ||
"dependencies": { | ||
"xmldom": "^0.4.0" | ||
} | ||
"name": "oc-k6", | ||
"version": "1.0.0", | ||
"main": "index.js", | ||
"license": "Apache-2.0", | ||
"author": { | ||
"name": "Florian Schade", | ||
"email": "[email protected]", | ||
"url": "https://owncloud.com" | ||
}, | ||
"scripts": { | ||
"build": "rm -rf ./run && rollup -c", | ||
"build:w": "rollup -c -w", | ||
"clean": "rm -rf ./tests", | ||
"lint": "eslint './src/**/*.ts'", | ||
"lint:f": "yarn lint --fix", | ||
"depcheck": "depcheck" | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "^7.9.0", | ||
"@babel/preset-env": "^7.9.5", | ||
"@babel/preset-typescript": "^7.9.0", | ||
"@rollup/plugin-commonjs": "^11.1.0", | ||
"@rollup/plugin-json": "^4.0.3", | ||
"@rollup/plugin-node-resolve": "^7.1.3", | ||
"@rollup/pluginutils": "^4.1.0", | ||
"@types/k6": "^0.42.0", | ||
"@types/lodash": "^4.14.165", | ||
"@types/xmldom": "^0.1.30", | ||
"@typescript-eslint/eslint-plugin": "^4.9.0", | ||
"@typescript-eslint/parser": "^4.9.0", | ||
"babel-plugin-lodash": "^3.3.4", | ||
"core-js": "3", | ||
"depcheck": "^1.3.1", | ||
"eslint": "^7.14.0", | ||
"eslint-config-prettier": "^6.15.0", | ||
"eslint-plugin-import": "^2.22.1", | ||
"eslint-plugin-prettier": "^3.2.0", | ||
"eslint-plugin-simple-import-sort": "^6.0.1", | ||
"k6": "^0.0.0", | ||
"lint-staged": "^10.1.7", | ||
"lodash": "^4.17.20", | ||
"prettier": "^2.2.1", | ||
"prettier-eslint": "^12.0.0", | ||
"rollup": "^2.7.2", | ||
"rollup-plugin-babel": "^4.4.0", | ||
"rollup-plugin-multi-input": "^1.1.1", | ||
"rollup-plugin-terser": "^5.3.0", | ||
"typescript": "^4.1.2" | ||
}, | ||
"dependencies": { | ||
"xmldom": "^0.4.0" | ||
} | ||
} |
Oops, something went wrong.