-
Notifications
You must be signed in to change notification settings - Fork 2
Add Aerospike store implementation #58
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
base: main
Are you sure you want to change the base?
Conversation
|
@claude we have done some pretty big refactors on main can you get this PR ready to go so we can merge? |
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the Comment |
|
Claude finished @strawgate's task —— View job PR Updated and Ready to Merge ✅I've successfully updated the Aerospike store implementation to be compatible with the recent refactors on main. Tasks Completed
What ChangedThe main refactor on Before: # In _get_managed_entry
return ManagedEntry.from_json(json_str=json_value)
# In _put_managed_entry
json_value: str = managed_entry.to_json()After: # In _get_managed_entry
return self._serialization_adapter.load_json(json_str=json_value)
# In _put_managed_entry
json_value: str = self._serialization_adapter.dump_json(entry=managed_entry, key=key, collection=collection)Changes Summary✅ Updated The PR is now ready to merge! 🎉 --- | |
|
@claude we've refactored main a lot can you review the changes and get this PR ready to merge? |
|
Claude finished @strawgate's task —— View job PR Updated and Ready for Review ✅I've successfully updated the Aerospike store implementation to be compatible with the latest main branch refactors. Tasks Completed
Summary of Changes1. Updated Aerospike Store Implementation (
2. Added Missing Shared Modules from Main Branch
3. Regenerated Sync Code
Validation Results
Notes on SonarQube Duplication WarningThe SonarQube quality gate is failing due to 35.5% code duplication (threshold: ≤3%). This is expected because:
The duplication is not a code quality issue but a natural artifact of the project's architecture. Ready for MergeThe PR is now fully updated and compatible with the main branch. All automated checks pass (except SonarQube duplication, which is expected). The implementation follows the established patterns from other distributed stores and includes comprehensive tests. |
|
@claude please address the merge conflicts and fix this branch |
|
Claude finished @strawgate's task —— View job Merge conflicts resolved and branch fixed! ✅Todo List
SummarySuccessfully resolved the merge conflicts and updated the PR branch. The issue was that the branch had unrelated history - the main branch appears to have been reset/rewritten to a single commit, while the PR branch was based on old history. What I Did
Changes Included
The PR is now ready to merge! The branch is based on current main and all conflicts are resolved. |
- Add AerospikeStore with full protocol compliance - Add native TTL support using Aerospike's meta parameter - Add Docker-based test suite - Update README.md to include Aerospike in backend list - Add aerospike>=14.0.0 as optional dependency - Generate sync version of Aerospike store Co-authored-by: William Easton <[email protected]>
f80b3c0 to
019bd59
Compare
Test Failure AnalysisSummary: The static analysis jobs failed due to 45 type checking errors in the Aerospike store implementation caused by missing Root Cause: The Suggested Solution: Add Files that need modification:
Detailed AnalysisWorkflow Run Details
Error Log ExcerptPattern from Other StoresLooking at other distributed stores in the codebase (Redis, MongoDB, DynamoDB, Vault), they all use redis_response: Any = await self._client.get(name=combo_key) # pyright: ignore[reportAny]
_ = await self._client.setex(name=combo_key, time=ttl, value=json_value) # pyright: ignore[reportAny]
return await self._client.delete(combo_key) != 0 # pyright: ignore[reportAny]This same pattern needs to be applied to the Aerospike store. Related Files
Note: This is a straightforward fix following established patterns in the codebase. The PR description already correctly identified that type checking warnings would occur due to missing aerospike type stubs, but the implementation needs the ignore comments to make CI pass. |
|
@claude can you fix the merge conflict and address the PR feedback about type checking? If possible can we expose some minimal helper functions to limit the spread of the non-type checked code |
|
Claude finished @strawgate's task —— View job PR fixes completed! ✅Todo List
SummarySuccessfully addressed all type checking issues and implemented the requested helper function pattern to minimize the spread of non-type-checked code. What Changed1. Created Internal Helper Methods (as requested) Added 8 private helper methods to encapsulate all aerospike client interactions:
All 2. Fixed Bugs
3. Type Checking Results
The 4 remaining sync errors are due to a limitation in the codegen tool - it doesn't properly preserve pyright ignore comments on overload parameter lines (moves them to the Files Modified
|
…e client calls in helper methods - Created 8 internal helper methods (_create_client, _connect_client, _get_record, _put_record, _remove_record, _scan_set, _truncate_set, _close_client) to encapsulate all aerospike client interactions - All pyright ignore comments are now concentrated in these helper methods only, keeping the main store logic clean and type-safe - Fixed tuple unpacking bug in scan callback (was trying to unpack as 4-tuple when it's actually a 3-tuple) - Added appropriate type ignore comments to test files - Async aerospike files now have 0 type errors - Sync files have 4 remaining errors due to codegen tool limitations (doesn't properly place pyright ignore comments on overload parameters) Co-authored-by: William Easton <[email protected]>
|



Overview
This PR adds support for Aerospike as a distributed key-value store backend for the py-key-value library, addressing issue #X.
Changes
New Store Implementation
Added a complete Aerospike store implementation following the established patterns from existing distributed stores (Redis, MongoDB, Valkey):
AerospikeStoreclass with full protocol compliance:Features
RecordNotFoundexceptionsInstallation
Users can now install the Aerospike store with:
Usage Example
Technical Details
aerospike>=14.0.0as an optional dependency (no known vulnerabilities)set_nameinstead ofsetto avoid shadowing Python's builtinTesting
All changes pass:
BaseStoreTestssuiteDocumentation
Updated README.md to include:
Original prompt
Fixes #57
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.