Skip to content

Commit aa38003

Browse files
sjswerdlowmattcary
authored andcommitted
Karkunpavan (kubernetes-sigs#4)
* Removing alpha disk from tests. * Changes setup the test to run with hyperdisk extreme. * Updates the disk type back to balanced, as HDX doesn't support multi writer. * Moving over to m1 megamem as thats the only type of machine that can support all needed disk types. * Changes update the tests to use two contexts, one for multiwriter and one for the existing tests. This was deemed necessary as only some disks can support multi-writer, and only some VM shapes can support said disks. * Changes update the tests to use two contexts, one for multiwriter and one for the existing tests. This was deemed necessary as only some disks can support multi-writer, and only some VM shapes can support said disks. * Fixing some git oddness * Fixing some formatting. * More formatting fixes. * Hopefully last changes for formatting. * Fixing linting issue. * Cleaning up un-used / un-needed GetMultiWriter test function.
1 parent 56474ba commit aa38003

File tree

2 files changed

+1
-14
lines changed

2 files changed

+1
-14
lines changed

pkg/gce-cloud-provider/compute/cloud-disk.go

-13
Original file line numberDiff line numberDiff line change
@@ -224,19 +224,6 @@ func (d *CloudDisk) GetKMSKeyName() string {
224224
return ""
225225
}
226226

227-
func (d *CloudDisk) GetMultiWriter() bool {
228-
switch {
229-
case d.disk != nil:
230-
return false
231-
case d.disk != nil && d.disk.AccessMode == "READ_WRITE_MANY":
232-
return true
233-
case d.betaDisk != nil:
234-
return d.betaDisk.MultiWriter
235-
default:
236-
return false
237-
}
238-
}
239-
240227
func (d *CloudDisk) GetEnableConfidentialCompute() bool {
241228
switch {
242229
case d.disk != nil:

pkg/gce-cloud-provider/compute/fake-gce.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ func (cloud *FakeCloudProvider) ValidateExistingDisk(ctx context.Context, resp *
217217
}
218218

219219
// We are assuming here that a multiWriter disk could be used as non-multiWriter
220-
if multiWriter && !resp.GetMultiWriter() {
220+
if multiWriter {
221221
return fmt.Errorf("disk already exists with incompatible capability. Need MultiWriter. Got non-MultiWriter")
222222
}
223223

0 commit comments

Comments
 (0)