mirror of https://github.com/grpc/grpc.git
[Configurability] Add flag to disable automatic registration of gRPC C++ reflection server when depending on //:grpc++_reflection (#37527)
Some applications cannot avoid the dependency on `//:grpc++_reflection` because it is buried by several infrastructural layers. For binaries that need to implement their own reflection server via generic handlers, this makes accepting request impossible as they will instead be handled by the default reflection server added by the server reflection plugin.
It would not be feasible to implement this as a build define because this binary is depended upon by many applications and buried beneath several layers of infrastructure.
Further, we cannot use the flag to control whether or not the plugin is installed as the plugin is installed at static initialization time, meaning that flags have not been parsed yet. Instead, we simply disable the functionality of the plugin with this flag.
CC @temawi
Closes #37527
COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/37527 from gnossen:disable_cpp_reflection 8d7e32961a
PiperOrigin-RevId: 665051996
pull/37529/head
parent
a07b6b89b3
commit
406fbf07a4
6 changed files with 49 additions and 12 deletions
Loading…
Reference in new issue