Skip to content

Commit

Permalink
feat: add optimus get resource changelog rpc (#113)
Browse files Browse the repository at this point in the history
* feat: add optimus get resource changelog rpc

* feat: change repeated type
  • Loading branch information
ahmadnaufal authored Jul 9, 2024
1 parent 0278f04 commit 01ffd0c
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions gotocompany/optimus/core/v1beta1/resource.proto
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,13 @@ service ResourceService {
body: "*"
};
}

// GetResourceChangelogs get all the change logs for a specific resource
rpc GetResourceChangelogs(GetResourceChangelogsRequest) returns (GetResourceChangelogsResponse) {
option (google.api.http) = {
get: "/v1beta1/project/{project_name}/resource/{resource_name}/changelog"
};
}
}

message DeployResourceSpecificationRequest {
Expand Down Expand Up @@ -219,4 +226,24 @@ message DeleteResourceRequest {

message DeleteResourceResponse {
repeated string downstream_jobs = 1;
}

message GetResourceChangelogsRequest {
string project_name = 1;
string resource_name = 2;
}

message ResourceChange {
string attribute_name = 1;
string diff = 2;
}

message ResourceChangelog {
string event_type = 1;
string timestamp = 2;
repeated ResourceChange change = 3;
}

message GetResourceChangelogsResponse {
repeated ResourceChangelog history = 1;
}

0 comments on commit 01ffd0c

Please sign in to comment.