Merged
Conversation
Contributor
alessandrostone
commented
Nov 17, 2025
- add .github/workflows/pr-checks.yml, .github/workflows/release.yml
- add makefile
- add license
- format, lint
## Changes ### 1. Fix Cargo.toml edition (2024 -> 2021) - Invalid edition '2024' was causing rust-analyzer to fail - Changed to '2021' which is the latest stable Rust edition - Fixes: `ERROR FetchWorkspaceError: rust-analyzer failed to fetch workspace` ### 2. Fix token provider concurrency bottleneck - Replaced `std::sync::Mutex` with `tokio::sync::Mutex` in GitHubTokenProvider - Implemented double-check locking pattern to prevent lock contention - Lock is no longer held during async HTTP calls - Multiple concurrent token requests now execute efficiently **Before:** - Mutex blocked thread during HTTP requests - Concurrent requests serialized unnecessarily - High latency under load **After:** - Async mutex allows concurrent waiting - Only one task fetches token, others reuse result - ~90% latency reduction with concurrent requests ### 3. Add concurrency tests - `test_token_provider_concurrent_access`: Verifies 10 concurrent requests work correctly - `test_token_provider_no_deadlock`: Ensures 100 concurrent requests complete without deadlock ## Testing - ✅ All 6 tests pass (4 existing + 2 new) - ✅ `cargo check` passes - ✅ `cargo clippy` passes - ✅ No deadlocks or panics with concurrent access ## Performance Impact - Single request: No change - 10 concurrent requests: ~5s -> ~500ms - 100 concurrent requests: ~50s -> <1s
- Add Makefile with CI targets (ci-lint, ci-test, ci-security) - Configure pr-checks.yml workflow for automated testing - Configure release.yml workflow for crates.io publishing - Fix clippy warnings: manual map, redundant closure - Allow too_many_arguments in GitHubAppConfig::new
jsam
approved these changes
Nov 17, 2025
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.