Commit abd441f
authored
No Empty Responses in Go SDK in future. (#3135)
## Changes
<!-- Brief summary of your changes that is easy to understand -->
This PR updates templates such that only legacyEmptyResponse and
googleEmpty are not rendered. Otherwise, it assumes that the Go SDK will
return a response.
GoogleEmpty - a google well known proto that ensures that we will never
add a field in it.
LegactEmptyResponse - Responses that are empty and not rendered in the
Go SDK because of legacy reasons. Rendering it will be a breaking change
for the users as it changes the method signature.
## Why
<!-- Why are these changes needed? Provide the context that the reviewer
might be missing.
For example, were there any decisions behind the change that are not
reflected in the code itself? -->
We have decided in the Go SDK that we will not omit the Response in the
method signature if it is empty in the future. As it restricts adding
new fields in the response. So, to remove this restriction, we need to
return an object from the beginning. So, this PR updates the template to
take into account.
## Tests
<!-- How have you tested the changes? -->
Generated CLI with zero diff.
<!-- If your PR needs to be included in the release notes for next
release,
add a separate entry in NEXT_CHANGELOG.md as part of your PR. -->1 parent 4432d62 commit abd441f
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
305 | 305 | | |
306 | 306 | | |
307 | 307 | | |
308 | | - | |
| 308 | + | |
309 | 309 | | |
310 | 310 | | |
311 | 311 | | |
| |||
358 | 358 | | |
359 | 359 | | |
360 | 360 | | |
361 | | - | |
| 361 | + | |
362 | 362 | | |
363 | 363 | | |
364 | 364 | | |
| |||
376 | 376 | | |
377 | 377 | | |
378 | 378 | | |
379 | | - | |
| 379 | + | |
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
| |||
0 commit comments