@@ -1041,10 +1041,44 @@ message ControllerModifyVolumeRequest {
10411041 // on the absence of keys, only keys that are specified should result
10421042 // in modifications to the volume.
10431043 map <string , string > mutable_parameters = 3 ;
1044+
1045+ // Indicates whether the CO allows the SP to update the topology
1046+ // as part of the modification.
1047+ bool allow_topology_updates = 4 ;
10441048}
10451049
10461050message ControllerModifyVolumeResponse {
10471051 option (alpha_message) = true ;
1052+
1053+ // Specifies where (regions, zones, racks, etc.) the modified
1054+ // volume is accessible from.
1055+ // A plugin that returns this field MUST also set the
1056+ // VOLUME_ACCESSIBILITY_CONSTRAINTS plugin capability.
1057+ // An SP MAY specify multiple topologies to indicate the volume is
1058+ // accessible from multiple locations.
1059+ // COs MAY use this information along with the topology information
1060+ // returned by NodeGetInfo to ensure that a given volume is accessible
1061+ // from a given node when scheduling workloads.
1062+ // This field is OPTIONAL. It is effective to replace the
1063+ // accessible_topology returned by CreateVolume if the plugin has
1064+ // MODIFY_VOLUME_TOPOLOGY controller capability.
1065+ // If it is not specified, the CO MAY assume
1066+ // the volume is equally accessible from all nodes in the cluster and
1067+ // MAY schedule workloads referencing the volume on any available
1068+ // node.
1069+ //
1070+ // SP MUST only set this field if allow_topology_updates is set
1071+ // in the request. SP SHOULD fail the request if it needs to update
1072+ // topology but is not allowed by CO.
1073+ repeated Topology accessible_topology = 1 ;
1074+
1075+ // Indicates whether the modification is still in progress.
1076+ // SPs MAY set in_progress to update the accessible_topology
1077+ // before the modification finishes to reduce possible race
1078+ // conditions.
1079+ // COs SHOULD retry the request if in_progress is set to true,
1080+ // until in_progress is set to false.
1081+ bool in_progress = 2 ;
10481082}
10491083
10501084message GetCapacityRequest {
@@ -1194,6 +1228,10 @@ message ControllerServiceCapability {
11941228 // Indicates the SP supports the GetSnapshot RPC.
11951229 // This enables COs to fetch an existing snapshot.
11961230 GET_SNAPSHOT = 15 [(alpha_enum_value) = true ];
1231+
1232+ // Indicates the SP supports modifying volume topology.
1233+ // See ControllerModifyVolume for details.
1234+ MODIFY_VOLUME_TOPOLOGY = 16 [(alpha_enum_value) = true ];
11971235 }
11981236
11991237 Type type = 1 ;
0 commit comments