Skip to content

Rename RPC parameters to be more consistent with the RPC names#150

Merged
tiyash-basu-frequenz merged 1 commit intofrequenz-floss:v0.x.xfrom
tiyash-basu-frequenz:rename_rpc_params
Oct 4, 2023
Merged

Rename RPC parameters to be more consistent with the RPC names#150
tiyash-basu-frequenz merged 1 commit intofrequenz-floss:v0.x.xfrom
tiyash-basu-frequenz:rename_rpc_params

Conversation

@tiyash-basu-frequenz
Copy link
Copy Markdown
Contributor

The RPC parameters were named in a way that was not consistent with the RPC names. This commit renames the RPC parameters to be more consistent with the RPC names. The following rules have been followed, in order:

  1. If an RPC is named GetX, then its request message is named GetXRequest and its response message is named X. Same for SubscribeX.
  2. If an RPC is named VerbX, then its request message is named VerbXRequest. Its response message is named VerbXResponse, unless the response type is google.protobuf.Empty.

Also, the documentation in the proto files has been updated to be more consistent with each other.

@tiyash-basu-frequenz tiyash-basu-frequenz added this to the v0.16.0 milestone Oct 4, 2023
@tiyash-basu-frequenz tiyash-basu-frequenz requested a review from a team as a code owner October 4, 2023 14:55
@tiyash-basu-frequenz tiyash-basu-frequenz self-assigned this Oct 4, 2023
@github-actions github-actions Bot added part:docs Affects the documentation part:protobuf Affects the protocol buffer definition files labels Oct 4, 2023
@tiyash-basu-frequenz tiyash-basu-frequenz linked an issue Oct 4, 2023 that may be closed by this pull request
@tiyash-basu-frequenz tiyash-basu-frequenz removed this from the v0.16.0 milestone Oct 4, 2023
TargetMetric target_metric = 2;
// Request parameters for the RPC `HotStandbyComponent`.
message HotStandbyComponentRequest {
// The component ID to.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick: The component ID to what?

Here and below :)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops 🙈
Fixed!

The RPC parameters were named in a way that was not consistent with the
RPC names. This commit renames the RPC parameters to be more consistent
with the RPC names. The following rules have been followed, in order:
1. If an RPC is named `GetX`, then its request message is named
   `GetXRequest` and its response message is named `X`. Same for
   `SubscribeX`.
2. If an RPC is named `VerbX`, then its request message is named
   `VerbXRequest`. Its response message is named `VerbXResponse`, unless
   the response type is `google.protobuf.Empty`.

Also, the documentation in the proto files has been updated to be more
consistent with each other.

Signed-off-by: Tiyash Basu <tiyash.basu@frequenz.com>
@tiyash-basu-frequenz tiyash-basu-frequenz added this pull request to the merge queue Oct 4, 2023
Merged via the queue into frequenz-floss:v0.x.x with commit e2a14ca Oct 4, 2023
@tiyash-basu-frequenz tiyash-basu-frequenz deleted the rename_rpc_params branch October 4, 2023 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:docs Affects the documentation part:protobuf Affects the protocol buffer definition files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rename RPC parameters

2 participants