Skip to content

Conversation

@nilanshu-sharma
Copy link
Collaborator

@nilanshu-sharma nilanshu-sharma commented Nov 7, 2025

Change Summary:

  1. Adding custom responses for the following commands:

    • CLUSTER SLOTS
    • CLUSTER SLOT-STATS
    • CLUSTER LINKS
  2. Converting error types for those Cluster Commands to RESPDecodeError

  3. Removing docker network to make cluster-mode valkey directly accessible to integration tests while testing locally on laptop.

  4. Restoring platform availability macros causing builds to fail

  5. Also realized that the Integration tests meant to cluster-mode features are not running in the CI, so CI needs to be enhanced to run cluster mode related docker dependencies. For now the verification of new integration tests is done locally.

@nilanshu-sharma nilanshu-sharma force-pushed the custom-cluster-command-types branch from 5023075 to 2bc45cb Compare November 7, 2025 02:22
Nilanshu Sharma added 2 commits November 7, 2025 11:07
@nilanshu-sharma nilanshu-sharma force-pushed the custom-cluster-command-types branch from 2bc45cb to cbe091e Compare November 7, 2025 19:28
@github-actions
Copy link

github-actions bot commented Nov 7, 2025

✅ Pull request has performance improvements ✅

Summary
================================================================================
Threshold deviations for ValkeyBenchmarks:Connection: GET benchmark – NoOpTracer
================================================================================
Malloc (total) (#, %) main pull_request Difference % Threshold %
p50 10143 8455 -16 5
p75 11119 10175 -8 5

New baseline 'pull_request' is BETTER than the 'main' baseline thresholds.

Full Benchmark Comparison

Comparing results between 'main' and 'pull_request'

Host '9b1bc5ae602b' with 4 'x86_64' processors with 15 GB memory, running:
#18~24.04.1-Ubuntu SMP Sat Jun 28 04:46:03 UTC 2025

ValkeyBenchmarks

Client: GET benchmark metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 76 78 79 80 81 81 81 6
pull_request 77 78 81 81 82 82 82 6
Δ 1 0 2 1 1 1 1 0
Improvement % -1 0 -3 -1 -1 -1 -1 0

Client: GET benchmark | parallel 20 | 20 concurrent connections metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 72 78 80 84 87 88 88 27
pull_request 72 77 78 83 84 85 85 27
Δ 0 -1 -2 -1 -3 -3 -3 0
Improvement % 0 1 2 1 3 3 3 0

Connection: GET benchmark metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 4 4 4 4 4 4 4 8
pull_request 4 4 4 4 4 4 4 8
Δ 0 0 0 0 0 0 0 0
Improvement % 0 0 0 0 0 0 0 0

Connection: GET benchmark – NoOpTracer metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 7 8 10 11 11 11 11 7
pull_request 7 8 8 10 11 11 11 8
Δ 0 0 -2 -1 0 0 0 1
Improvement % 0 0 20 9 0 0 0 1

Connection: Pipeline array benchmark metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 33 33 34 34 34 34 34 6
pull_request 33 33 34 34 34 34 34 6
Δ 0 0 0 0 0 0 0 0
Improvement % 0 0 0 0 0 0 0 0

Connection: Pipeline benchmark metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 33 33 33 34 34 34 34 6
pull_request 33 33 33 34 34 34 34 6
Δ 0 0 0 0 0 0 0 0
Improvement % 0 0 0 0 0 0 0 0

HashSlot – {user}.whatever metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 0 0 0 0 0 0 0 18
pull_request 0 0 0 0 0 0 0 19
Δ 0 0 0 0 0 0 0 1
Improvement % 0 0 0 0 0 0 0 1

ValkeyCommandEncoder – Command with 7 words metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 0 0 0 0 0 0 0 738
pull_request 0 0 0 0 0 0 0 726
Δ 0 0 0 0 0 0 0 -12
Improvement % 0 0 0 0 0 0 0 -12

ValkeyCommandEncoder – Simple GET metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 0 0 0 0 0 0 0 1867
pull_request 0 0 0 0 0 0 0 1841
Δ 0 0 0 0 0 0 0 -26
Improvement % 0 0 0 0 0 0 0 -26

ValkeyCommandEncoder – Simple MGET 15 keys metrics

Malloc (total): results within specified thresholds, fold down for details.

Malloc (total) * p0 p25 p50 p75 p90 p99 p100 Samples
main 0 0 0 0 0 0 0 354
pull_request 0 0 0 0 0 0 0 348
Δ 0 0 0 0 0 0 0 -6
Improvement % 0 0 0 0 0 0 0 -6

Signed-off-by: Nilanshu Sharma <[email protected]>
@nilanshu-sharma nilanshu-sharma changed the title [Work in Progress]: Custom responses for cluster commands Custom responses for cluster commands Nov 7, 2025
Nilanshu Sharma added 3 commits November 7, 2025 13:23
Copy link
Collaborator

@adam-fowler adam-fowler left a comment

Choose a reason for hiding this comment

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

Hi @nilanshu-sharma I've had a quick look at this on my phone. Hard to do a proper review on the phone, but see my comments related to errors thrown.

Copy link
Collaborator

@adam-fowler adam-fowler left a comment

Choose a reason for hiding this comment

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

A quick review from my iPhone

Signed-off-by: Nilanshu Sharma <[email protected]>
@nilanshu-sharma
Copy link
Collaborator Author

Thanks @adam-fowler. I have addressed your comments.

@nilanshu-sharma nilanshu-sharma changed the title Custom responses for cluster commands Custom responses and Standard Error types for cluster commands Nov 14, 2025
@nilanshu-sharma nilanshu-sharma force-pushed the custom-cluster-command-types branch from 868f4b3 to deeae68 Compare November 15, 2025 01:51
Copy link
Collaborator

@adam-fowler adam-fowler left a comment

Choose a reason for hiding this comment

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

Most of this is fine, just moving code about.

Can we remove the docker file edits, as I'm not sure they work. At least valkey docs imply they don't. When testing cluster I tend to use a devcontainer in vscode. But if you can create a docker file we can use on macOS and Linux for testing cluster lets do it in another PR.

}
}

@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
Copy link
Collaborator

Choose a reason for hiding this comment

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

These were never needed before why are they needed now

Copy link
Collaborator Author

@nilanshu-sharma nilanshu-sharma Dec 1, 2025

Choose a reason for hiding this comment

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

These got removed as per these connection pool changes on Oct 29: https://github.com/valkey-io/valkey-swift/pull/256/files
Since then my local builds are failing. I'm okay to remove these if they are not required as it could be an issue with my local build env.

@@ -1,3 +1,4 @@
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
Copy link
Collaborator

Choose a reason for hiding this comment

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

See above

@adam-fowler adam-fowler merged commit c8b7686 into main Dec 2, 2025
14 of 15 checks passed
@adam-fowler adam-fowler deleted the custom-cluster-command-types branch December 2, 2025 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants