Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(gengapic): rest-numeric-enums option enables enum-encoding sys param #1022

Merged
merged 8 commits into from
Jul 27, 2022

Conversation

noahdietz
Copy link
Collaborator

@noahdietz noahdietz commented Jun 7, 2022

For REGAPIC API calls, when the rest-numeric-enums plugin option is provided, include the new system parameter variant of $alt=json that enables proto-json encoding of enums in server responses as integers - enum-encoding=int. The default is false. Includes the bazel attribute as well.

Also updates the README with option documentation.

Requested in http://b/232457394.

@noahdietz noahdietz requested a review from vchudnov-g June 7, 2022 21:23
@noahdietz noahdietz requested review from a team as code owners June 7, 2022 21:23
@noahdietz noahdietz added the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Jun 8, 2022
internal/gengapic/genrest.go Outdated Show resolved Hide resolved
@vchudnov-g
Copy link
Contributor

Oh, one question: are you planning on encoding all enums as ints when sending the request too? We think that would be desirable for symmetry.

@noahdietz
Copy link
Collaborator Author

Oh, one question: are you planning on encoding all enums as ints when sending the request too? We think that would be desirable for symmetry.

That was already done in #994 :)

@vchudnov-g
Copy link
Contributor

Oh, right! Great!

@noahdietz noahdietz added disable job: compute-regen disables the compute-regen job and removed disable job: compute-regen disables the compute-regen job labels Jun 10, 2022
@noahdietz
Copy link
Collaborator Author

@vchudnov-g are we good to merge/release this yet? Thanks

@vchudnov-g
Copy link
Contributor

@noahdietz No, let's not merge this yet. The server changes have not been rolled out yet.

@noahdietz noahdietz removed the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Jun 27, 2022
@noahdietz noahdietz changed the title feat(gengapic): regapic includes enum-encoding sys param feat(gengapic): rest-numeric-enums option enables enum-encoding sys param Jun 27, 2022
README.md Show resolved Hide resolved
@noahdietz noahdietz added the automerge Summon MOG for automerging label Jul 27, 2022
@gcf-merge-on-green gcf-merge-on-green bot merged commit 6bbbf6f into googleapis:main Jul 27, 2022
@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Summon MOG for automerging label Jul 27, 2022
gcf-merge-on-green bot pushed a commit that referenced this pull request Aug 16, 2022
🤖 I have created a release *beep* *boop*
---


## [0.32.0](v0.31.2...v0.32.0) (2022-08-16)


### Features

* **gengapic:** rest-numeric-enums option enables enum-encoding sys param ([#1022](#1022)) ([6bbbf6f](6bbbf6f))


### Bug Fixes

* **gengapic:** fix linkParser regexp to support multi-line link tags ([#1098](#1098)) ([863675e](863675e)), closes [#1097](#1097)
* **gengapic:** fix service-specific constructor name in doc_file.go ([#1099](#1099)) ([4f80726](4f80726)), closes [#1077](#1077)

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants