forked from valkey-io/valkey-glide
-
Notifications
You must be signed in to change notification settings - Fork 0
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 Jedis and Lettuce benchmarks #1
Closed
Closed
Changes from 19 commits
Commits
Show all changes
34 commits
Select commit
Hold shift + click to select a range
06574ea
Add Jedis and Lettuce benchmarks
jonathanl-bq 5990767
Start ignoring .gradle files
jonathanl-bq 6ae93f5
Update gitignore and remove generated files from git
acarbonetto 8203c4d
Update gitignore and remove generated files from git
acarbonetto e517744
Update gitignore and remove generated files from git
acarbonetto 2a11e9a
Add benchmarks for GET non-existing
jonathanl-bq cbb0dcb
Revert "Update gitignore and remove generated files from git"
acarbonetto 5f51a5b
fix redis-rs submodules
acarbonetto 52df672
Randomize commands in Java benchmarks
jonathanl-bq 84f0efc
rename chooseAction to randomAction
jonathanl-bq 1983974
Add a Java benchmarking app (#7)
acarbonetto 6c1fb45
Add Readme and update install_and_test script to runJava
acarbonetto 46d0cf6
Add Readme and update install_and_test script to runJava
acarbonetto d526f96
Combine java pipeline and java benchmarks (#8)
Yury-Fridlyand 436da8f
Add sync and async clients both to tests. (#12)
Yury-Fridlyand 016f5f6
Move duplicated logic in benchmark JS scripts to a single file, and c…
acarbonetto e57c1ff
Add dataSize option to java benchmark. (#11)
Yury-Fridlyand 8664d05
Rename jabushka to javababushka (#14)
acarbonetto b15f93e
Add missing renames. (#17)
Yury-Fridlyand 1bab56a
Add option to run tests on multiple clients in concurrency (#16)
Yury-Fridlyand d99d27a
Update redis-rs to match main branch
acarbonetto 540f49a
Create clients only once per iteration (#19)
acarbonetto 65090b4
Updated ClientCount to client_count for uniformity.
SanHalacogluImproving 8a0449d
Convert client count to snake case for rust benchmark. (#27)
SanHalacogluImproving c3d235a
Add json reporting. (#10)
Yury-Fridlyand fe9bb98
Merge remote-tracking branch 'upstream/main' into java_benchmarks
Yury-Fridlyand d533b7f
Typo fix.
Yury-Fridlyand 9cbc9c2
Typo fix.
Yury-Fridlyand b00a205
Merge branch 'java_benchmarks' of github.com:Bit-Quill/babushka into …
Yury-Fridlyand a62fe92
fix java install_and_test script variables
acarbonetto 30f2f62
Merge branch 'main' into java_benchmarks
acarbonetto 05590b0
Java benchmarks clusters (#34)
acarbonetto bcf188c
Clean up timer
acarbonetto b50d57e
Java client jni netty (#32)
Yury-Fridlyand File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Java client benchmarks | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
name: | ||
required: false | ||
type: string | ||
|
||
run-name: ${{ inputs.name == '' && format('{0} @ {1}', github.ref_name, github.sha) || inputs.name }} | ||
|
||
jobs: | ||
java-benchmark: | ||
strategy: | ||
matrix: | ||
java: | ||
- 11 | ||
- 17 | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Set up JDK ${{ matrix.java }} | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: "temurin" | ||
java-version: ${{ matrix.java }} | ||
|
||
- name: Start Redis | ||
run: docker run -p 6379:6379 -p 8001:8001 -d redis/redis-stack | ||
|
||
- name: Run benchmarks | ||
working-directory: java | ||
run: ./gradlew :benchmark:run | ||
|
||
- name: Upload test reports | ||
if: always() | ||
continue-on-error: true | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: test-reports-${{ matrix.java }} | ||
path: | | ||
java/benchmarks/build/reports/** |
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 |
---|---|---|
@@ -0,0 +1,63 @@ | ||
name: SQL Java CI | ||
|
||
on: | ||
pull_request: | ||
push: | ||
paths: | ||
- "java/**" | ||
- ".github/workflows/java.yml" | ||
|
||
# Run only most latest job on a branch and cancel previous ones | ||
concurrency: | ||
group: ${{ github.head_ref || github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build-and-test-java-client: | ||
strategy: | ||
# Run all jobs | ||
fail-fast: false | ||
matrix: | ||
java: | ||
- 11 | ||
- 17 | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Set up JDK ${{ matrix.java }} | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: "temurin" | ||
java-version: ${{ matrix.java }} | ||
|
||
- name: Install and run protoc (protobuf) | ||
run: | | ||
sudo apt update | ||
sudo apt install -y protobuf-compiler | ||
mkdir -p java/client/src/main/java/org/babushka/javababushka/generated | ||
protoc -Iprotobuf=babushka-core/src/protobuf/ --java_out=java/client/src/main/java/org/babushka/javababushka/generated babushka-core/src/protobuf/*.proto | ||
|
||
- name: Build rust part | ||
working-directory: java | ||
run: cargo build | ||
|
||
- name: Start Redis | ||
run: docker run -p 6379:6379 -p 8001:8001 -d redis/redis-stack | ||
|
||
- name: Build java part | ||
working-directory: java | ||
run: ./gradlew --continue build | ||
|
||
- name: Upload test reports | ||
if: always() | ||
continue-on-error: true | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: test-reports-${{ matrix.java }} | ||
path: | | ||
java/client/build/reports/** | ||
java/integTest/build/reports/** |
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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 | ||||
---|---|---|---|---|---|---|
|
@@ -24,12 +24,14 @@ runAllBenchmarks=1 | |||||
runPython=0 | ||||||
runNode=0 | ||||||
runCsharp=0 | ||||||
runJava=0 | ||||||
runRust=0 | ||||||
concurrentTasks="1 10 100 1000" | ||||||
dataSize="100 4000" | ||||||
clientCount="1" | ||||||
chosenClients="all" | ||||||
host="localhost" | ||||||
port=6379 | ||||||
tlsFlag="--tls" | ||||||
|
||||||
function runPythonBenchmark(){ | ||||||
|
@@ -68,6 +70,22 @@ function runCSharpBenchmark(){ | |||||
dotnet run --configuration Release --resultsFile=../$1 --dataSize $2 --concurrentTasks $concurrentTasks --clients $chosenClients --host $host --clientCount $clientCount $tlsFlag $portFlag | ||||||
} | ||||||
|
||||||
function runJavaBenchmark(){ | ||||||
cd ${BENCH_FOLDER}/../java | ||||||
echo "./gradlew run --args=\"--resultsFile=${BENCH_FOLDER}/$1 --clients $chosenClients --host $host --port $port\"" | ||||||
# ./gradlew run --args="--resultsFile=../$1 --dataSize $2 --concurrentTasks $concurrentTasks --clients $chosenClients --host $host --port $port --clientCount $clientCount $tlsFlag" | ||||||
./gradlew run --args="--resultsFile=${BENCH_FOLDER}/$1 --clients $chosenClients --host $host --port $port" | ||||||
cd ${BENCH_FOLDER}/java | ||||||
} | ||||||
|
||||||
function runJavaBenchmark(){ | ||||||
cd ${BENCH_FOLDER}/../java | ||||||
echo "./gradlew run --args=\"--resultsFile=${BENCH_FOLDER}/$1 --clients $chosenClients --host $host --port $port\"" | ||||||
# ./gradlew run --args="--resultsFile=../$1 --dataSize $2 --concurrentTasks $concurrentTasks --clients $chosenClients --host $host --port $port --clientCount $clientCount $tlsFlag" | ||||||
./gradlew run --args="--resultsFile=${BENCH_FOLDER}/$1 --clients $chosenClients --host $host --port $port" | ||||||
cd ${BENCH_FOLDER}/java | ||||||
} | ||||||
|
||||||
function runRustBenchmark(){ | ||||||
rustConcurrentTasks= | ||||||
for value in $concurrentTasks | ||||||
|
@@ -185,6 +203,36 @@ do | |||||
runAllBenchmarks=0 | ||||||
runNode=1 | ||||||
;; | ||||||
-java) | ||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Babushka" | ||||||
;; | ||||||
-lettuce) | ||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Lettuce" | ||||||
;; | ||||||
-lettuce) | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Jedis" | ||||||
;; | ||||||
-java) | ||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Babushka" | ||||||
;; | ||||||
-lettuce) | ||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Lettuce" | ||||||
;; | ||||||
-lettuce) | ||||||
runAllBenchmarks=0 | ||||||
runJava=1 | ||||||
chosenClients="Jedis" | ||||||
;; | ||||||
-csharp) | ||||||
runAllBenchmarks=0 | ||||||
runCsharp=1 | ||||||
|
@@ -242,6 +290,13 @@ do | |||||
runCSharpBenchmark $csharpResults $currentDataSize | ||||||
fi | ||||||
|
||||||
if [ $runAllBenchmarks == 1 ] || [ $runJava == 1 ]; | ||||||
then | ||||||
javaResults=$(resultFileName java $currentDataSize) | ||||||
resultFiles+=$javaResults" " | ||||||
runJavaBenchmark $javaResults $currentDataSize | ||||||
fi | ||||||
|
||||||
if [ $runAllBenchmarks == 1 ] || [ $runRust == 1 ]; | ||||||
then | ||||||
rustResults=$(resultFileName rust $currentDataSize) | ||||||
|
@@ -250,8 +305,6 @@ do | |||||
fi | ||||||
done | ||||||
|
||||||
|
||||||
|
||||||
flushDB | ||||||
|
||||||
if [ $writeResultsCSV == 1 ]; | ||||||
|
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[env] | ||
BABUSHKA_NAME = { value = "BabushkaPy", force = true } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. rename |
||
BABUSHKA_VERSION = "0.1.0" |
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Ignore Gradle project-specific cache directory | ||
.gradle | ||
|
||
# Ignore Gradle build output directory | ||
build | ||
|
||
# Ignore generated files (e.g. protobuf) | ||
generated |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
[package] | ||
name = "javababushka" | ||
version = "0.0.0" | ||
edition = "2021" | ||
license = "BSD-3-Clause" | ||
|
||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | ||
[lib] | ||
name = "javababushka" | ||
crate-type = ["cdylib"] | ||
|
||
[dependencies] | ||
redis = { path = "../submodules/redis-rs/redis", features = ["aio", "tokio-comp", "connection-manager", "tls", "tokio-rustls-comp"] } | ||
babushka = { path = "../babushka-core" } | ||
tokio = { version = "^1", features = ["rt", "macros", "rt-multi-thread", "time"] } | ||
logger_core = {path = "../logger_core"} | ||
tracing-subscriber = "0.3.16" | ||
|
||
[profile.release] | ||
lto = true | ||
debug = true |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reminder for
--dataSize
--concurrentTasks
--clientCount
$tlsFlag