Skip to content
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

Node: add ZINTER and ZUNION commands #2146

Merged

Conversation

tjzhang-BQ
Copy link
Collaborator

@tjzhang-BQ tjzhang-BQ commented Aug 15, 2024

original PR: #1556

@tjzhang-BQ tjzhang-BQ added the node Node.js wrapper label Aug 15, 2024
@tjzhang-BQ tjzhang-BQ requested a review from a team as a code owner August 15, 2024 21:16
@tjzhang-BQ tjzhang-BQ force-pushed the node/integ-tjz-VALKEY-62-zunion branch from 1d6c498 to a7ed20f Compare August 15, 2024 21:43
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
@@ -1871,6 +1873,8 @@ export class BaseTransaction<T extends BaseTransaction<T>> {
*
* @see {@link https://valkey.io/commands/zinterstore/|valkey.io} for details.
*
* since Valkey version 6.2.0.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* since Valkey version 6.2.0.
* @remarks Since Valkey version 6.2.0.

node/src/Transaction.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
Signed-off-by: TJ Zhang <[email protected]>
node/src/BaseClient.ts Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
node/tests/GlideClusterClient.test.ts Outdated Show resolved Hide resolved
async (protocol) => {
await runTest(async (client: BaseClient, cluster: RedisCluster) => {
if (cluster.checkIfServerVersionLessThan("6.2.0")) return;
await zunionBasicTest(client);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

upvoting to split into multiple tests

*/
function createZCmdArgs(
keys: string[] | KeyWeight[],
aggregationType?: AggregationType,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit - change this to use an anonymous object to define the 3 optional variables:

function createZCmdArgs(
    keys: string[] | KeyWeight[],
    options: {aggregationType: string?, withscores: boolean?, destination: string? }
): string[] {

Signed-off-by: TJ Zhang <[email protected]>
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/BaseClient.ts Outdated Show resolved Hide resolved
node/src/Transaction.ts Outdated Show resolved Hide resolved
@jonathanl-bq jonathanl-bq merged commit d91fbab into valkey-io:main Aug 19, 2024
8 checks passed
@jonathanl-bq jonathanl-bq deleted the node/integ-tjz-VALKEY-62-zunion branch August 19, 2024 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
node Node.js wrapper
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants