Introduce SYNCSLOTS CAPA for forwards compatibility (#2688)

For now, introduce this and have it do nothing. Eventually, we can use
this to negotiate supported capabilities on either end. Right now, there
is nothing to send or support, so it just accepts it and doesn't reply.

---------

Signed-off-by: Jacob Murphy <jkmurphy@google.com>
Co-authored-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
This commit is contained in:
Jacob Murphy
2025-10-07 10:19:36 -07:00
committed by GitHub
parent 383ffe4874
commit a4317e9115
+12
View File
@@ -2557,6 +2557,13 @@ void clusterCommandSyncSlotsAck(client *c) {
}
}
void clusterCommandSyncSlotsCapa(client *c) {
UNUSED(c);
/* As of now there are no supported capa fields. We ignore unknown CAPA
* fields. */
return;
}
/* Sent by either the target or the source as a control message for progressing
* with slot import. */
void clusterCommandSyncSlots(client *c) {
@@ -2604,6 +2611,11 @@ void clusterCommandSyncSlots(client *c) {
clusterCommandSyncSlotsAck(c);
return;
}
if (!strcasecmp(c->argv[2]->ptr, "capa")) {
/* CLUSTER SYNCSLOTS CAPA <field> [<field>...] */
clusterCommandSyncSlotsCapa(c);
return;
}
if (c->slot_migration_job &&
isSlotMigrationJobInProgress(c->slot_migration_job)) {
serverLog(LL_WARNING, "Received unknown SYNCSLOTS subcommand from "