A new metadata type `x-envoy-peer-metadata` is being introduced. We
don't have a better way to do this at the moment compared to just adding
it in `metadata_batch.h`.
The GSM Observability plugin uses this metadata to send topology
information to peers in the form of serialized and base64 encoded
`google::protobuf::Struct`. The individual keys being used inside the
struct are subject to change.
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
This rolls forward only the pick_first changes from #32692, which were
rolled back in #33718. Specifically:
- Changes PF to use its own subchannel list implementation instead of
using the subchannel_list library, since the latter will be going away
with the dualstack changes.
- As a result of no longer using the subchannel_list library, PF no
longer needs to set the `GRPC_ARG_INHIBIT_HEALTH_CHECKING` channel arg.
- Adds an option to start a health watch on the chosen subchannel, to be
used in the future when pick_first is the child of a petiole policy.
(Currently, this code is not actually called anywhere.)
Based on updates at https://github.com/grpc/proposal/pull/380
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
PanCakes to the rescue!
We noticed that our 'sanity' test was going to fail, but we think we can
fix that automatically, so we put together this PR to do just that!
If you'd like to opt-out of these PR's, add yourself to NO_AUTOFIX_USERS
in .github/workflows/pr-auto-fix.yaml
Co-authored-by: sergiitk <sergiitk@users.noreply.github.com>
This change is to update the TD bootstrap generator for prod tests. This
is part of the TD release process. The new image has already been merged
to staging and tested locally in google3.
cc: @sergiitk PTAL.
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
---------
Co-authored-by: Mark D. Roth <roth@google.com>
Co-authored-by: markdroth <markdroth@users.noreply.github.com>
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
Pipe-like type (has a send end, a receive end, and a closing mechanism)
for cross-activity transfers.
---------
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
Old message:
new_cluster_1: UNAVAILABLE: errors validating xds_cluster_resolver LB
policy config: [field:discoveryMechanisms error:must be non-empty]
New message:
new_cluster_1: FAILED_PRECONDITION: aggregate cluster graph has no leaf
clusters
A set of simplifications to make this code easier to reason about:
- Replace `SockToPolledFdMap` with `std::map`
- Make the c-ares `close` callback do nothing. Instead, let the ares
wrapper code destroy polled fds as it normally does, and let everything
that hasn't been registered for I/O get destroyed in the
`GrpcPolledFdFactoryWindows` dtor.
- Get rid of `GrpcPolledFdWindowsWrapper`
- Move `socket_notify_on_write` to the `RegisterForOnWriteableLocked`
method. This makes for a nice invariant that no async callback is
pending *unless* a `RegisterForOnWriteableLocked` or
`RegisterForOnReadableLocked` callback is pending.
Related: internal issue b/293321613
This is to address too many warnings coming from upb 24.x
```
In file included from external/upb/upb/mini_table/field.h:32:
external/upb/upb/mini_table/internal/message.h:36:14:
warning: redefinition of typedef 'upb_Message' is a C11 feature [-Wtypedef-redefinition]
typedef void upb_Message;
^
external/upb/upb/message/tagged_ptr.h:40:14: note: previous definition is here
typedef void upb_Message;
^
1 warning generated.
```
If we get a readable event on an fd and both the following happens:
- c-ares does *not* read all bytes off the fd
- c-ares removes the fd from the set ARES_GETSOCK_READABLE
... then we have a busy loop here, where we'd keep asking c-ares to
process an fd that it no longer cares about.
This is indirectly related to a change in this code one month ago:
https://github.com/grpc/grpc/pull/33942 - before that change, c-ares
would close the socket when it called
[handle_error](7f3262312f/src/lib/ares_process.c (L707))
and so `IsFdStillReadableLocked` would start returning `false`, causing
us to get away with [this
loop](f6a994229e/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc (L371)).
Now, because `IsFdStillReadableLocked` will keep returning true (because
of our overridden `close` API), we'll loop forever.
```
[ 7%] Building CXX object CMakeFiles/grpc_unsecure.dir/src/core/ext/filters/channel_idle/idle_filter_state.cc.o
In file included from /home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/ext/filters/census/grpc_context.cc:26:
In file included from /home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/lib/debug/trace.h:34:
In file included from /home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/lib/gprpp/global_config.h:91:
In file included from /home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/lib/gprpp/global_config_env.h:27:
In file included from /home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/lib/gprpp/memory.h:24:
In file included from /usr/include/c++/v1/memory:898:
In file included from /usr/include/c++/v1/__memory/shared_ptr.h:31:
/usr/include/c++/v1/__memory/unique_ptr.h:63:19: error: invalid application of 'sizeof' to an incomplete type 'grpc_server_config_fetcher'
static_assert(sizeof(_Tp) >= 0, "cannot delete an incomplete type");
^~~~~~~~~~~
/usr/include/c++/v1/__memory/unique_ptr.h:297:7: note: in instantiation of member function 'std::default_delete<grpc_server_config_fetcher>::operator()' requested here
__ptr_.second()(__tmp);
^
/usr/include/c++/v1/__memory/unique_ptr.h:231:5: note: in instantiation of member function 'std::unique_ptr<grpc_server_config_fetcher>::reset' requested here
reset(__u.release());
^
/home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/src/core/lib/surface/server.h:145:21: note: in instantiation of member function 'std::unique_ptr<grpc_server_config_fetcher>::operator=' requested here
config_fetcher_ = std::move(config_fetcher);
^
/home/dpronin/.conan2/p/t/grpc7af12e0c3f76b/b/src/include/grpc/grpc.h:458:16: note: forward declaration of 'grpc_server_config_fetcher'
typedef struct grpc_server_config_fetcher grpc_server_config_fetcher;
^
[ 7%] Built target grpc_python_plugin
```
src/core/lib/surface/server.h: Server::set_config_fetcher() function
must be defined below the definition of the type
'struct grpc_server_config_fetcher' because std::unique_ptr must know
how type looks like at the place where the smart pointer calls a deleter
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
---------
Signed-off-by: Denis Pronin <dannftk@yandex.ru>
Co-authored-by: Yash Tibrewal <yashkt@google.com>
libuv was previously considered as the base of event engine, it's not
the case anymore.
It was removed from third_party in #33748, this PR remove it from objc
Batch completions can run after the Server promise call finishes and
deallocates the server trailing metadata. Remove the use of
grpc_transport_stream_op_batch_string so that such batch completions
dont end up de-referencing an already free'ed grpc_metadata_batch.
Fix for https://github.com/grpc/grpc/issues/34113 - setting C# option
base_namespace to an empty string results in inconsistent behavior
Allow the `base_namespace` option in the protocol buffers C# gRPC plugin
to be specified with an empty string to make sure the plugin has the
same behaviour as the protocol buffers compiler.
Based on updates at https://github.com/grpc/proposal/pull/380
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
Building out a new framing layer for chttp2.
The central idea here is to have the framing layer be solely responsible
for serialization of frames, and their deserialization - the framing
layer can reject frames that have invalid syntax - but the enacting of
what that frame means is left to a higher layer.
This class will become foundational for the promise conversion of chttp2
- by eliminating action from the parsing of frames we can reuse this
sensitive code.
Right now the new layer is inactive - there's a test that exercises it
relatively well, and not much more. In the next PRs I'll add an
experiments to enable using this layer or the existing code in the
writing and reading paths.
---------
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
This is the initial implementation of the chaotic-good client transport
write path. There will be a follow-up PR to fulfill the read path.
<!--
If you know who should review your pull request, please assign it to
that
person, otherwise the pull request would get assigned randomly.
If your pull request is for a specific language, please add the
appropriate
lang label.
-->
- Add a couple of new TODOs that we need to address before making the LB
policy API public.
- Remove a comment about picker thread-safety that should be been
removed in #31973.
- Remove a TODO that was addressed in #33451.
We added this as an exploratory measure for a customer that thought they
were using open census (this turned out to be emphatically false).
Remove it since it's probably not how we ultimately want to do this, and
wait for something better to come along.
---------
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
Fixes internal b/297030898.
This ought not be necessary, but getting context from the promise based
filter wrapper code at call destruction is unwieldy.
Hacking around it here and fixing it properly post client rollout seems
wiser.