There was a bug in #26722 where we added a whitespace between comment
prefix and each line of the license notice, regardless it's empty or not.
This creates trailing whitespaces if the license note contains blank
lines, which makes most of the formatters and linters unhappy.
This PR resolves this issue.
* fix: If client request iterators raise exceptions, _consume_request_iterator should not dump its stack to stderr
fixes: #25339
* fix: use format_exc
* fix: linter
* fix: lint round 2
The XDS code incurs a significant binary size increase, and isn't
generally relevant/useful to builds of gRPC for mobile platforms.
Note that this makes it impossible to build the XDS for mobile platforms
(as opposed to turning XDS off by default but still allowing it to be
force-enabled via a config flag). We're going this route, because any
approach that turns the feature off by default on some platforms but
that still allows force-enabling it on those platforms ends up hitting
either bazel's limits (bazel doesn't support a select() statement where
multiple branches match), or ends up having to rely on the linker to
strip out unused code (by still including the srcs and deps
unconditionally, and using a preprocessor directive to remove symbol
references, which the linker can then remove), which we don't want to do
because relying on the linker makes it too easy to accidentally
re-introduce symbol references.
* Add a --fix flag to check_copyright.py
When enabled, automatically add copyright headers to files without one.
* Fix formatting issue.
* Address code review comments
* Add folder for bindertransport and its smoke test
We will import the sources in the next few pull requests. Main purpose
of this commit is to create the folder and add dummy smoke test to make
sure nothing breaks
* regenerate projects.
This is a fairly low effort migration of the current codebase into a C++ class, instead of free standing C code.
It builds upon #26657 as a necessary first step.
I've tried to minimize any changes to semantics or logic in this change, except where required to get a minimal amount of encapsulation - which is the major aim of this change.
A future change in this series will buffer slices until all HPACK headers are in memory for a stream prior to decoding -- it's important to have an encapsulated API to the parser before doing so however (hence this CL).
The next change after that will be an almost complete rewrite of the parsing functionality -- since we'll have the total set of header bytes, we'll no longer need to support suspending decoding at arbitrary points. This will allow us to move to a simple recursive descent parser, eliminate a bunch of indirection in this code, and end up in a much more malleable place for when we start doing metadata API changes.
(we likely also end up with some good performance wins!)
This adds support for protobuf ObjC support for using the proto package to
define the prefix for the file
(https://github.com/protocolbuffers/protobuf/pull/8760).
Once protobuf cuts a release, it likely makes sense to support the same
generator options that the objc generator does, but for now the environment
variable support can used to enable this when building from recent sources.
Eliminate HPACK table
Use a switch statement instead of a table lookup for the first byte of
HPACK parsing.
This will lead the way to some other improvements down the track (I have
a substantial overhaul here planned), but this is a necessary first
step.
* Use constexpr to simplify HPACK parser
This is a bit of a trial balloon: in C++11, generate at load time a
table that used to be hard coded. In C++14, generate that same table at
compile time, but eliminate the code generator.
Should this work out, I'd like to expand the technique so that we can
eliminate some of the confusing tables in this file by keeping the code
that generates them *in the same place* as the code that consumes them.
* comments
* c++14 fixes