You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Support online and offline expansion without requiring them to be declared in plugin capabilities.
Ability for a plugin to delcare online and offline controller expansion
capabilities via GetPluginCapabilities is deprecated. A plugin may
support either mode of operation without having to declare them
in GetPluginCapabilities call.
If a plugin can not support controller expansion of published volume
it may return Volume-in-use error and CO should ensure that volume is
not published before retrying with exponential backoff.
Copy file name to clipboardexpand all lines: spec.md
+6-16
Original file line number
Diff line number
Diff line change
@@ -625,7 +625,7 @@ message PluginCapability {
625
625
ONLINE = 1;
626
626
627
627
// OFFLINE indicates that volumes currently published and
628
-
// available on a node SHALL NOT be expanded via
628
+
// available on a node SHOULD NOT be expanded via
629
629
// ControllerExpandVolume. When a plugin supports OFFLINE volume
630
630
// expansion it MUST implement either the EXPAND_VOLUME controller
631
631
// capability or both the EXPAND_VOLUME controller capability and
@@ -644,6 +644,7 @@ message PluginCapability {
644
644
oneof type {
645
645
// Service that the plugin supports.
646
646
Service service = 1;
647
+
// deprecated
647
648
VolumeExpansion volume_expansion = 2;
648
649
}
649
650
}
@@ -1930,24 +1931,15 @@ This RPC allows the CO to expand the size of a volume.
1930
1931
This operation MUST be idempotent.
1931
1932
If a volume corresponding to the specified volume ID is already larger than or equal to the target capacity of the expansion request, the plugin SHOULD reply 0 OK.
1932
1933
1933
-
This call MAY be made by the CO during any time in the lifecycle of the volume after creation if plugin has `VolumeExpansion.ONLINE` capability.
1934
+
This call MAY be made by the CO during any time in the lifecycle of the volume after creation but an SP may not permit controller expansion of volumes which are controller published or available on a node. In which case - the plugin may return gRPC error code`FAILED_PRECONDITION` (Volume in use) and CO SHOULD ensure that volume is not published and retry with exponential backoff.
1935
+
1934
1936
If plugin has `EXPAND_VOLUME` node capability, then `NodeExpandVolume` MUST be called after successful `ControllerExpandVolume` and `node_expansion_required` in `ControllerExpandVolumeResponse` is `true`.
1935
1937
1936
1938
If specified, the `volume_capability` in `ControllerExpandVolumeRequest` should be same as what CO would pass in `ControllerPublishVolumeRequest`.
1937
1939
1938
-
If the plugin has only `VolumeExpansion.OFFLINE` expansion capability and volume is currently published or available on a node then `ControllerExpandVolume` MUST be called ONLY after either:
1939
-
- The plugin has controller `PUBLISH_UNPUBLISH_VOLUME` capability and `ControllerUnpublishVolume` has been invoked successfully.
1940
-
1941
-
OR ELSE
1942
-
1943
-
- The plugin does NOT have controller `PUBLISH_UNPUBLISH_VOLUME` capability, the plugin has node `STAGE_UNSTAGE_VOLUME` capability, and `NodeUnstageVolume` has been completed successfully.
1944
-
1945
-
OR ELSE
1946
-
1947
-
- The plugin does NOT have controller `PUBLISH_UNPUBLISH_VOLUME` capability, nor node `STAGE_UNSTAGE_VOLUME` capability, and `NodeUnpublishVolume` has completed successfully.
1948
1940
1949
1941
Examples:
1950
-
* Offline Volume Expansion:
1942
+
* Offline Volume Expansion(SP does not permit controller expansion of controller published volume):
1951
1943
Given an ElasticSearch process that runs on Azure Disk and needs more space.
1952
1944
- The administrator takes the Elasticsearch server offline by stopping the workload and CO calls `ControllerUnpublishVolume`.
1953
1945
- The administrator requests more space for the volume from CO.
| Exceeds capabilities | 3 INVALID_ARGUMENT | Indicates that CO has specified capabilities not supported by the volume. | Caller MAY verify volume capabilities by calling ValidateVolumeCapabilities and retry with matching capabilities. |
2005
1997
| Volume does not exist | 5 NOT FOUND | Indicates that a volume corresponding to the specified volume_id does not exist. | Caller MUST verify that the volume_id is correct and that the volume is accessible and has not been deleted before retrying with exponential back off. |
2006
-
| Volume in use | 9 FAILED_PRECONDITION | Indicates that the volume corresponding to the specified `volume_id` could not be expanded because it is currently published on a node but the plugin does not have ONLINE expansion capability. | Caller SHOULD ensure that volume is not published and retry with exponential back off. |
1998
+
| Volume in use | 9 FAILED_PRECONDITION | Indicates that the volume corresponding to the specified `volume_id` could not be expanded because it is currently published on a node. | Caller SHOULD ensure that volume is not published and retry with exponential back off. |
2007
1999
| Unsupported `capacity_range`| 11 OUT_OF_RANGE | Indicates that the capacity range is not allowed by the Plugin. More human-readable information MAY be provided in the gRPC `status.message` field. | Caller MUST fix the capacity range before retrying. |
2008
2000
2009
2001
#### RPC Interactions
@@ -2523,8 +2515,6 @@ If plugin has `STAGE_UNSTAGE_VOLUME` node capability then:
2523
2515
2524
2516
Otherwise `NodeExpandVolume` MUST be called after successful `NodePublishVolume`.
2525
2517
2526
-
If a plugin only supports expansion via the `VolumeExpansion.OFFLINE` capability, then the volume MUST first be taken offline and expanded via `ControllerExpandVolume` (see `ControllerExpandVolume` for more details), and then node-staged or node-published before it can be expanded on the node via `NodeExpandVolume`.
2527
-
2528
2518
The `staging_target_path` field is not required, for backwards compatibility, but the CO SHOULD supply it.
2529
2519
Plugins can use this field to determine if `volume_path` is where the volume is published or staged,
2530
2520
and setting this field to non-empty allows plugins to function with less stored state on the node.
0 commit comments