Skip to content

Commit

Permalink
Change OpenStorageSchedule API parameter type to string (#2454)
Browse files Browse the repository at this point in the history
Signed-off-by: Tengxiao Wang <[email protected]>
  • Loading branch information
twang-ps authored Jun 18, 2024
1 parent 1829c49 commit e4b050e
Show file tree
Hide file tree
Showing 6 changed files with 3,957 additions and 3,997 deletions.
4 changes: 4 additions & 0 deletions SDK_CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## Releases

### v0.186.0 - (06/17/2024)

* Change OpenStorageSchedule API parameter type to string

### v0.185.0 - (05/24/2024)

* Added a parameter for FlashArray Pod names
Expand Down
7,865 changes: 3,930 additions & 3,935 deletions api/api.pb.go

Large diffs are not rendered by default.

30 changes: 6 additions & 24 deletions api/api.pb.gw.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 10 additions & 7 deletions api/api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -4144,8 +4144,9 @@ message Schedule {
message SdkInspectScheduleRequest {
// ID of the schedule
string id = 1;
// Type is schedule type
Job.Type type = 2;
// Type is schedule type (cast to string from a Job.Type enum, as the version of
// protoc-gen-grpc-gateway on release branch doesn't support enum type in REST API path parameter)
string type = 2;
}

// Defines a response of schedule information
Expand All @@ -4155,8 +4156,9 @@ message SdkInspectScheduleResponse {

// Defines a request to enumerate all schedules of a type
message SdkEnumerateSchedulesRequest {
// Type is schedule type
Job.Type type = 1;
// Type is schedule type (cast to string from a Job.Type enum, as the version of
// protoc-gen-grpc-gateway on release branch doesn't support enum type in REST API path parameter)
string type = 1;
}

// Defines a response containing list of schedules
Expand All @@ -4168,8 +4170,9 @@ message SdkEnumerateSchedulesResponse {
message SdkDeleteScheduleRequest {
// ID of the schedule
string id = 1;
// Type is schedule type
Job.Type type = 2;
// Type is schedule type (cast to string from a Job.Type enum, as the version of
// protoc-gen-grpc-gateway on release branch doesn't support enum type in REST API path parameter)
string type = 2;
}

// Empty response
Expand Down Expand Up @@ -5854,7 +5857,7 @@ message SdkVersion {
// SDK version major value of this specification
Major = 0;
// SDK version minor value of this specification
Minor = 185;
Minor = 186;
// SDK version patch value of this specification
Patch = 0;
}
Expand Down
32 changes: 4 additions & 28 deletions api/server/sdk/api/api.swagger.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions api/server/sdk/schedule_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func TestInspectSchedule(t *testing.T) {
r, err := c.Inspect(
context.Background(),
&api.SdkInspectScheduleRequest{
Type: api.Job_DEFRAG,
Type: "DEFRAG",
Id: "12345",
},
)
Expand Down Expand Up @@ -100,7 +100,7 @@ func TestEnumerateSchedules(t *testing.T) {
r, err := c.Enumerate(
context.Background(),
&api.SdkEnumerateSchedulesRequest{
Type: api.Job_DEFRAG,
Type: "DEFRAG",
},
)

Expand Down Expand Up @@ -132,7 +132,7 @@ func TestDeleteSchedule(t *testing.T) {
context.Background(),
&api.SdkDeleteScheduleRequest{
Id: "12345",
Type: api.Job_DEFRAG,
Type: "DEFRAG",
},
)
assert.NoError(t, err)
Expand Down

0 comments on commit e4b050e

Please sign in to comment.