Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: CSI 1.6 - maximum volume size #173

Merged
merged 6 commits into from
Oct 30, 2023
Merged

Conversation

mdutka-dell
Copy link
Contributor

@mdutka-dell mdutka-dell commented Oct 23, 2023

Description

Adding maximum volume size funtionality in message GetCapacityResponse

The PR does not fix golangci-lint issues

GitHub Issues

List the GitHub issues impacted by this PR:

GitHub Issue #

Checklist:

  • I have performed a self-review of my own code to ensure there are no formatting, vetting, linting, or security issues
  • I have verified that new unit tests pass locally with my changes
  • I have not allowed coverage numbers to degenerate
  • I have maintained at least 90% code coverage
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • Backward compatibility is not broken

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Please also list any relevant details for your test configuration

  • Unit tests written as integration tests
    Given a CSI service                        # <autogenerated>:1 -> *feature
time="2023-10-30T06:27:41-04:00" level=info msg="/csi.v1.Controller/GetCapacity: REQ 0002: VolumeCapabilities=[mount:<> access_mode:<mode:SINGLE_NODE_WRITER > ], Parameters=map[arrayId:APM00213404195 description:CSI Volume Unit Test isDataReductionEnabled:false nasServer:nas_1 storagePool:pool_3 thinProvisioned:true tieringPolicy:0], XXX_NoUnkeyedLiteral={}, XXX_sizecache=0"
time="2023-10-30T06:27:41-04:00" level=debug  runid=2 msg="Executing GetCapacity with args: {VolumeCapabilities:[mount:<> access_mode:<mode:SINGLE_NODE_WRITER > ] Parameters:map[arrayId:APM00213404195 description:CSI Volume Unit Test isDataReductionEnabled:false nasServer:nas_1 storagePool:pool_3 thinProvisioned:true tieringPolicy:0] AccessibleTopology:<nil> XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}" func="github.com/dell/csi-unity/service.(*service).GetCapacity()" file="/home/gosia/repos/csi-unity/service/controller.go:508"
time="2023-10-30T06:27:41-04:00" level=debug arrayid=apm00213404195 runid=2 msg="Probing controller service automatically" func="github.com/dell/csi-unity/service.(*service).requireProbe()" file="/home/gosia/repos/csi-unity/service/service.go:774"
time="2023-10-30T06:27:41-04:00" level=debug arrayid=apm00213404195 runid=2 msg="Inside Controller Probe" func="github.com/dell/csi-unity/service.(*service).probe()" file="/home/gosia/repos/csi-unity/service/service.go:811"
time="2023-10-30T06:27:41-04:00" level=debug msg="Executing Authenticate REST client" func="github.com/dell/gounity.(*Client).Authenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:66"
time="2023-10-30T06:27:42-04:00" level=debug msg="Response code:200 for url: /api/types/loginSessionInfo" func="github.com/dell/gounity/api.(*client).DoAndGetResponseBody()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/api/restclient.go:306"
time="2023-10-30T06:27:42-04:00" level=debug msg="Authentication response code: 200" func="github.com/dell/gounity.(*Client).Authenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:79"
time="2023-10-30T06:27:42-04:00" level=debug msg="Authentication successful" func="github.com/dell/gounity.(*Client).Authenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:89"
time="2023-10-30T06:27:42-04:00" level=debug arrayid=apm00213404195 runid=2 msg="Controller Probe Success" func="github.com/dell/csi-unity/service.singleArrayProbe()" file="/home/gosia/repos/csi-unity/service/service.go:803"
time="2023-10-30T06:27:42-04:00" level=info msg="GetSystemCapacityMetrics: /api/types/systemCapacity/instances?fields=id,sizeFree,sizeTotal,sizeUsed,sizePreallocated,sizeSubscribed,totalLogicalSize" func="github.com/dell/gounity.(*Metrics).GetCapacity()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/metrics.go:130"
time="2023-10-30T06:27:42-04:00" level=debug msg="Invoking REST API server info Method: GET, URI: /api/types/systemCapacity/instances?fields=id,sizeFree,sizeTotal,sizeUsed,sizePreallocated,sizeSubscribed,totalLogicalSize" func="github.com/dell/gounity.(*Client).executeWithRetryAuthenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:120"
time="2023-10-30T06:27:42-04:00" level=debug msg="Response code:200 for url: /api/types/systemCapacity/instances?fields=id,sizeFree,sizeTotal,sizeUsed,sizePreallocated,sizeSubscribed,totalLogicalSize" func="github.com/dell/gounity/api.(*client).DoAndGetResponseBody()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/api/restclient.go:306"
time="2023-10-30T06:27:42-04:00" level=debug msg="Execution successful on Method: GET, URI: /api/types/systemCapacity/instances?fields=id,sizeFree,sizeTotal,sizeUsed,sizePreallocated,sizeSubscribed,totalLogicalSize" func="github.com/dell/gounity.(*Client).executeWithRetryAuthenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:123"
time="2023-10-30T06:27:42-04:00" level=info arrayid=apm00213404195 runid=2 msg="Available capacity from the Array: 2368137592832" func="github.com/dell/csi-unity/service.(*service).GetCapacity()" file="/home/gosia/repos/csi-unity/service/controller.go:536"
time="2023-10-30T06:27:42-04:00" level=debug msg="Invoking REST API server info Method: GET, URI: /api/instances/systemLimit/Limit_MaxLUNSize?fields=limitValue,unit" func="github.com/dell/gounity.(*Client).executeWithRetryAuthenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:120"
time="2023-10-30T06:27:42-04:00" level=debug msg="Response code:200 for url: /api/instances/systemLimit/Limit_MaxLUNSize?fields=limitValue,unit" func="github.com/dell/gounity/api.(*client).DoAndGetResponseBody()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/api/restclient.go:306"
time="2023-10-30T06:27:42-04:00" level=debug msg="Execution successful on Method: GET, URI: /api/instances/systemLimit/Limit_MaxLUNSize?fields=limitValue,unit" func="github.com/dell/gounity.(*Client).executeWithRetryAuthenticate()" file="dell/gounity@v1.15.1-0.20231027105111-fc1c259b8753/unityclient.go:123"
time="2023-10-30T06:27:42-04:00" level=info msg="/csi.v1.Controller/GetCapacity: REP 0002: AvailableCapacity=2368137592832, MaximumVolumeSize=value:281474976710656, XXX_NoUnkeyedLiteral={}, XXX_sizecache=0"
Maximum Volume Size: value:281474976710656 
    When I Call GetCapacity                    # <autogenerated>:1 -> *feature
    Then there are no errors                   # <autogenerated>:1 -> *feature

1 scenarios (1 passed)
3 steps (3 passed)
1.604007409s```

@mdutka-dell mdutka-dell marked this pull request as draft October 23, 2023 12:46
@mdutka-dell mdutka-dell changed the title CSI 1.6 feature: CSI 1.6 - maximum volume size Oct 24, 2023
@mdutka-dell mdutka-dell marked this pull request as ready for review October 30, 2023 10:24
@rajendraindukuri rajendraindukuri self-requested a review October 30, 2023 11:26
@mdutka-dell mdutka-dell merged commit 0162954 into main Oct 30, 2023
3 of 4 checks passed
@mjsdell mjsdell deleted the maximum-volume-size branch October 17, 2024 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants