Fix Volume provisioning service instance parameter validation #103
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
What this PR does / why we need it:
This make the request parameter keys in accordance with the swagger.
a) Change the Key case
b) If the parameter is defined in action yaml to be required false, it sends the parameter as 'null'. This invalidates the default parameter value of the function and the SODA API fails for validation. So passing the default values explicitly
Some errors in API log:
E0706 12:58:42.250396 2799048 validation.go:64] invalid request: Request body has an error: doesn't match the schema: Property 'name' is missing
E0706 12:58:42.256562 2799048 context.go:155] code: 400, reason: Request body has an error: doesn't match the schema: Property 'name' is missing
I0706 23:04:09.462377 2892953 accesslog.go:26] ^[[32m[D] 172.23.0.6:37156 -- POST /v1beta/94b280022d0c4401bcf3b0ea85870519/block/volumes^[[0m
E0706 23:04:09.462515 2892953 validation.go:69] invalid request: Request body has an error: doesn't match the schema: Error at "/availabilityZone":Value is not nullable {"ProfileId": "868a7d24-74ac-41b4-8ef3-9e974f19a03d", "profileId": "868a7d24-74ac-41b4-8ef3-9e974f19a03d", "availabilityZone": null, "name": "test001", "size": 1}
E0706 23:04:09.462951 2892953 context.go:155] code: 400, reason: Request body has an error: doesn't match the schema: Error at "/availabilityZone":Value is not nullable
Which issue(s) this PR fixes:
Fixes #102
Test Report Added?:
Test Report:
Volume provisioning in SODA Dashboard
![image](https://user-images.githubusercontent.com/48085413/86751976-ab331f80-c05c-11ea-8267-ce1716204fd0.png)
![image](https://user-images.githubusercontent.com/48085413/86752192-cf8efc00-c05c-11ea-8a4b-691a85765f1a.png)
Volume provisioning in Stackstorm
Bucket migration in SODA Dashboard:
![image](https://user-images.githubusercontent.com/48085413/86752622-1bda3c00-c05d-11ea-8ae6-a9a44ea69380.png)
Bucket MIgration in Stackstorm:
![image](https://user-images.githubusercontent.com/48085413/86752347-e9304380-c05c-11ea-9308-7271ebb22fc8.png)
Special notes for your reviewer: