-
Notifications
You must be signed in to change notification settings - Fork 0
Feature/non blocking persistence #3
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
Closed
Closed
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
b22d739
feat: implement async batched persistence for MessageQueue
ofek29 7d79ea1
test: add performance test with report
ofek29 6194821
test: new script to run the performance test
ofek29 d89d4fb
docs: update README with Async batch persistence and Performance test
ofek29 dca937a
test: moved to fixed payload, change logs path
ofek29 74503d0
test(script): improve and optimaized Java settings
ofek29 0ee36ee
test(script): improve and optimaized Java settings
ofek29 141ba61
test: add messages folder for performance test
ofek29 adc0c2b
fix: improve persistence worker, fix batch save, add messages save on…
ofek29 4198a2a
fix: update example to courrent implementation
ofek29 4b74ff0
chore: new testing tools, parallel testing enable
ofek29 3a9ba38
fix: shutdown function await for persistence worker
ofek29 6b92054
test: message queue test
ofek29 a0f549f
test: message class unit tests
ofek29 4da7874
test: consumer class tests
ofek29 6a7ce48
test: producer class tests
ofek29 6f39b69
test: new integrarion test
ofek29 f832cb3
chore: add test CI workflow
ofek29 67c9dd7
fix: delete app test file
ofek29 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 hidden or 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,45 @@ | ||
| name: CI | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| paths-ignore: | ||
| - "*.md" | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| paths-ignore: | ||
| - "*.md" | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| test: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| strategy: | ||
| matrix: | ||
| java-version: [21] | ||
|
|
||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up JDK ${{ matrix.java-version }} | ||
| uses: actions/setup-java@v4 | ||
| with: | ||
| java-version: ${{ matrix.java-version }} | ||
| distribution: "temurin" | ||
| cache: maven | ||
|
|
||
| - name: Cache Maven dependencies | ||
| uses: actions/cache@v4 | ||
| with: | ||
| path: ~/.m2/repository | ||
| key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | ||
| restore-keys: ${{ runner.os }}-m2 | ||
|
|
||
| - name: Run tests | ||
| run: mvn clean test | ||
This file contains hidden or 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 contains hidden or 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 contains hidden or 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,38 @@ | ||
| #!/bin/bash | ||
|
|
||
| echo "Message Queue Performance Test" | ||
| echo "==============================" | ||
| echo | ||
|
|
||
| # Optimized GC, Heap and others Java settings | ||
| export MAVEN_OPTS="-Xms2g -Xmx4g -XX:+UseG1GC -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=2m -XX:+G1UseAdaptiveIHOP -XX:G1MixedGCCountTarget=4 -Xlog:gc*:logs/gc.log" | ||
|
|
||
| # Clean and compile the project | ||
| echo "Compiling project..." | ||
| mvn clean compile test-compile -q | ||
|
|
||
| if [ $? -ne 0 ]; then | ||
| echo "Error: Compilation failed" | ||
| exit 1 | ||
| fi | ||
|
|
||
| echo "Compilation successful!" | ||
| echo | ||
|
|
||
| # Run the performance test | ||
| echo "Starting performance test..." | ||
| echo | ||
|
|
||
| # Run the test | ||
| mvn exec:java \ | ||
| -Dexec.mainClass="com.ofek.queue.PerformanceTest" \ | ||
| -Dexec.classpathScope="test" | ||
|
|
||
| if [ $? -eq 0 ]; then | ||
| echo | ||
| echo "Performance test completed successfully!" | ||
| echo | ||
| else | ||
| echo "Error: Performance test failed" | ||
| exit 1 | ||
| fi |
This file contains hidden or 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
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.
why matrix for one runner one version? just use jobs