Skip to content

Commit 71086de

Browse files
committed
Add force detach
Add new controller capability: * UNPUBLISH_FENCE Add new node capabilitiy: * FORCE_UNPUBLISH
1 parent f1ae024 commit 71086de

File tree

3 files changed

+394
-282
lines changed

3 files changed

+394
-282
lines changed

csi.proto

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -788,6 +788,17 @@ message ControllerUnpublishVolumeRequest {
788788
// This field is OPTIONAL. Refer to the `Secrets Requirements`
789789
// section on how to use this field.
790790
map<string, string> secrets = 3 [(csi_secret) = true];
791+
792+
// Indicates SP MUST make the volume inacessible to the node or nodes
793+
// it is being unpublished from. Any attempt to read or write data
794+
// to a volume from a node that has been fenced MUST NOT succeed,
795+
// even if the volume remains staged and/or published on the node.
796+
// CO MUST NOT set this field to true unless SP has the
797+
// UNPUBLISH_FENCE controller capability.
798+
// The SP MAY make the volume inaccessible even when this field is
799+
// false.
800+
// This is an OPTIONAL field.
801+
bool fence = 4;
791802
}
792803

793804
message ControllerUnpublishVolumeResponse {
@@ -1316,6 +1327,13 @@ message NodeUnstageVolumeRequest {
13161327
// system/filesystem, but, at a minimum, SP MUST accept a max path
13171328
// length of at least 128 bytes.
13181329
string staging_target_path = 2;
1330+
1331+
// Indicates that the SP should prefer to successfully unstage the
1332+
// volume, even if data loss would occur as a result.
1333+
// CO MUST NOT set this field to true unless SP has the
1334+
// FORCE_UNPUBLISH node capability.
1335+
// This in an OPTIONAL field.
1336+
bool force = 3;
13191337
}
13201338

13211339
message NodeUnstageVolumeResponse {
@@ -1400,6 +1418,13 @@ message NodeUnpublishVolumeRequest {
14001418
// system/filesystem, but, at a minimum, SP MUST accept a max path
14011419
// length of at least 128 bytes.
14021420
string target_path = 2;
1421+
1422+
// Indicates that the SP should prefer to successfully unpublish the
1423+
// volume, even if data loss would occur as a result.
1424+
// CO MUST NOT set this field to true unless SP has the
1425+
// FORCE_UNPUBLISH node capability.
1426+
// This in an OPTIONAL field.
1427+
bool force = 3;
14031428
}
14041429

14051430
message NodeUnpublishVolumeResponse {

0 commit comments

Comments
 (0)