JAVA: Move COPY command with database ID from standalone to base client#4804
Merged
affonsov merged 6 commits intorelease-2.1from Oct 1, 2025
Merged
Conversation
- Move COPY command with destinationDB parameter from GenericCommands to GenericBaseCommands - Move implementation from GlideClient to BaseClient to support both standalone and cluster clients - Add COPY with database ID support to BaseBatch class - Update Batch class to inherit COPY functionality from BaseBatch - Add comprehensive tests for COPY with database ID for both String and GlideString types - Update version requirements: Valkey 6.2.0+ for standalone, 9.0.0+ for cluster Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
10 tasks
jduo
approved these changes
Sep 24, 2025
Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
yipin-chen
reviewed
Sep 29, 2025
yipin-chen
approved these changes
Sep 29, 2025
…add-database-id-for-copy-command-on-cluster-mode Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
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.
Refactor COPY Command with Database ID Support
Overview
This PR refactors the COPY command implementation to support database ID parameter across both standalone and cluster clients by moving the functionality from the standalone-specific
GenericCommandsinterface to the sharedGenericBaseCommandsinterface.Changes Made
Core Implementation Changes
GenericCommandstoGenericBaseCommandsinterfaceGlideClienttoBaseClientclassDB_VALKEY_APIconstant fromGenericCommandstoGenericBaseCommandsBatch Support
BaseBatchclassBatchclass (now inherits fromBaseBatch)Test Coverage
API Compatibility
Version Requirements
Testing
copy_with_database_id()test method for String parameterscopy_binary_with_database_id()test method for GlideString parametersThis refactoring improves code organization by consolidating COPY functionality in the base classes while maintaining full backward compatibility and extending support to cluster clients.
Issue link
This Pull Request is linked to issue (URL): [#4766]
Checklist
Before submitting the PR make sure the following are checked: