Skip to content

Commit

Permalink
Clarify idempotent for ControllerExpandVolume and NodeExpandVolume
Browse files Browse the repository at this point in the history
Add explicit documentation for clarity idempotent for
ControllerExpandVolume and NodeExpandVolume

Signed-off-by: Xin Wang <wileywang@yunify.com>
  • Loading branch information
Xin Wang authored and jdef committed Feb 11, 2020
1 parent 09fd6f3 commit da3002f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -1804,6 +1804,9 @@ The CO MUST implement the specified error recovery behavior when it encounters t
A Controller plugin MUST implement this RPC call if plugin has `EXPAND_VOLUME` controller capability.
This RPC allows the CO to expand the size of a volume.

This operation MUST be idempotent.
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.

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.
If plugin has `EXPAND_VOLUME` node capability, then `NodeExpandVolume` MUST be called after successful `ControllerExpandVolume` and `node_expansion_required` in `ControllerExpandVolumeResponse` is `true`.

Expand Down Expand Up @@ -2355,6 +2358,9 @@ The CO MUST implement the specified error recovery behavior when it encounters t
A Node Plugin MUST implement this RPC call if it has `EXPAND_VOLUME` node capability.
This RPC call allows CO to expand volume on a node.

This operation MUST be idempotent.
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.

`NodeExpandVolume` ONLY supports expansion of already node-published or node-staged volumes on the given `volume_path`.

If plugin has `STAGE_UNSTAGE_VOLUME` node capability then:
Expand Down

0 comments on commit da3002f

Please sign in to comment.