Commit Graph

8222 Commits

Author SHA1 Message Date
gRPC Team Bot 2b3f21daea Internal change
PiperOrigin-RevId: 606360614
2024-02-12 14:11:47 -08:00
Yousuk Seung 3459e5c7b8 [work-serializer] deflake tests with dispatching workserializer
PiperOrigin-RevId: 606292107
2024-02-12 10:28:10 -08:00
Mark D. Roth 41606054c2 [load_file] remove grpc_load_file() in favor of grpc_core::LoadFile() (#35857)
Closes #35857

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35857 from markdroth:highlander 7b7d95aaa9
PiperOrigin-RevId: 605742734
2024-02-09 15:16:24 -08:00
Craig Tiller d1cb0c0874 [chaotic-good] Bring up core e2e tests (#35663)
Closes #35663

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35663 from ctiller:shush-e2e 0c1f82ed71
PiperOrigin-RevId: 605717663
2024-02-09 13:34:46 -08:00
erm-g 3343756673 [ssl] Fix for ALPN comparision logic (#35863)
fix for b/316952851

Closes #35863

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35863 from erm-g:apln-calc 1b445bf14a
PiperOrigin-RevId: 605697428
2024-02-09 12:11:30 -08:00
Mark D. Roth 21cb320080 [reorg] move service config code to src/core/service_config (#35843)
Closes #35843

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35843 from markdroth:client_channel_reorg4 0c50ada6f9
PiperOrigin-RevId: 605466874
2024-02-08 16:58:20 -08:00
AJ Heller 521b2ea17c [EventEngine] Make oauth2 test utils work with EventEngine clients (#35866)
The Oauth2 credentials currently rely on pollsets and polling entities, partially because grpc_core::HttpRequest relies on them as well. This is a temporary solution to get both iomgr and EventEngine clients to pass the oauth2 interop tests.

Tested with the client experiment on and off.

Closes #35866

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35866 from drfloob:oauth2_utils_work_with_ee_hack 91eea0c196
PiperOrigin-RevId: 605433817
2024-02-08 14:49:43 -08:00
Mark D. Roth f22c954ef5 [reorg] move client channel code to src/core/client_channel (#35827)
Also rename client_channel.{h,cc} -> client_channel_filter.{h,cc}.

Closes #35827

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35827 from markdroth:client_channel_reorg3 449bff563f
PiperOrigin-RevId: 605006293
2024-02-07 09:23:26 -08:00
Yash Tibrewal 242e9185a3 [metadata] Allow non application/grpc content-type values (#35824)
Fixes #33935

The gRPC spec is not clear on how to handle headers where the "content-type" is not "application/grpc" or similar. We should be safe and not reject such headers.

Closes #35824

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35824 from yashykt:Fix33935 3d89af87ec
PiperOrigin-RevId: 604742049
2024-02-06 13:15:45 -08:00
Mark D. Roth 10e83973e7 [reorg] move resolver code to src/core/resolver (#35804)
This new directory combines code from the following locations:
- src/core/ext/filters/client_channel/resolver
- src/core/lib/resolver

Closes #35804

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35804 from markdroth:client_channel_resolver_reorg2 30660e6b00
PiperOrigin-RevId: 604665835
2024-02-06 09:07:56 -08:00
Craig Tiller b2bf241a71 [call-v3] Add a quick & easy way to add an interceptor for *just* server trailing metadata (#35797)
Closes #35797

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35797 from ctiller:chan3+1.5 53077db9e1
PiperOrigin-RevId: 604470351
2024-02-05 16:41:31 -08:00
Craig Tiller 3ff53525d1 [channel] Integrate channel init infrastructure with new call filter infrastructure (#35767)
built on #35766

Closes #35767

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35767 from ctiller:chan3+1 22cbba7de8
PiperOrigin-RevId: 604446427
2024-02-05 15:16:49 -08:00
Mark D. Roth 122a1996ae [promise] add optional is_acceptable callback to Observable (#35789)
Closes #35789

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35789 from markdroth:observable_is_acceptable 75a888a769
PiperOrigin-RevId: 604437699
2024-02-05 14:44:18 -08:00
Mark D. Roth 148f59c15a [reorg] move LB policy code to src/core/load_balancing (#35786)
This new directory combines code from the following locations:
- src/core/ext/filters/client_channel/lb_policy
- src/core/lib/load_balancing

Closes #35786

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35786 from markdroth:client_channel_resolver_reorg 98554efb98
PiperOrigin-RevId: 604351832
2024-02-05 10:05:35 -08:00
Mark D. Roth fa5603c72c [client channel] rename ClientChannel to ClientChannelFilter (#35783)
Closes #35783

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35783 from markdroth:client_channel_filter_rename ea8b74a33a
PiperOrigin-RevId: 603424220
2024-02-01 11:20:17 -08:00
AJ Heller 2288b63601 [EventEngine] Fix HttpCli test to deail with EventEngine async execution (#35776)
One test (`CallerPollentsAreNotReferencedAfterCallbackIsRan`) was not waiting for a callback to be run before finishing when the EventEngine client is in use. With the iomgr implementation, `exec_ctx.Flush();` previously guaranteed that the callback would be executed before the test ended, but the EventEngine runs it in a separate thread, with the EventEngine shim providing its own isolated ExecCtx. This fix simply waits for the callback to be run before exiting, in the same way many other tests in this file wait on iomgr-based callback execution.

Closes #35776

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35776 from drfloob:httpcli-test-async 3c920da741
PiperOrigin-RevId: 603175531
2024-01-31 15:23:24 -08:00
Vignesh Babu 6e9dad7deb [testing] Update max fd limit in test (#35775)
Please see cl/602800790 for details.

Closes #35775

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35775 from Vignesh2208:test-fix 95d3d93bb9
PiperOrigin-RevId: 603138045
2024-01-31 13:10:59 -08:00
Eugene Ostroukhov 8ea3b417cc [csds] Make grpc_dump_xds_configs return ClientStatusResponse (#35612)
Closes #35612

PiperOrigin-RevId: 602443727
2024-01-29 11:14:23 -08:00
AJ Heller 71fa68f7fb [EventEngine] Add QueryExtension Interfaces for *SupportsFd (#35648)
This PR:
* adds FD extensions to the public headers
* Adds the query extension interface to EventEngine, Listener, and Endpoint, via a new `Extensible` interface
* Refactors the PosixEventEngine to use the Extensible interface.

Closes #35648

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35648 from drfloob:posix-ee-query-interface 7cae28e0b3
PiperOrigin-RevId: 601794970
2024-01-26 10:03:18 -08:00
AJ Heller ba2f74a84c [EventEngine] Dump all thread stacks when the thread pool is wedged
This should help us debug rare flakes where the thread pool waits indefinitely

PiperOrigin-RevId: 601546451
2024-01-25 13:25:36 -08:00
Craig Tiller 19ad49d169 [bazel] disable fuzzer on mac (#35662)
Closes #35662

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35662 from ctiller:nononono 4f7d2fb893
PiperOrigin-RevId: 601448944
2024-01-25 08:03:46 -08:00
Craig Tiller 870a66d9a0 [chaotic-good] Connection setup & test suites (#35650)
Closes #35650

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35650 from ctiller:shush-tsan fd55ea1be3
PiperOrigin-RevId: 601221780
2024-01-24 13:46:08 -08:00
apolcyn 7d5b53e2a7 [testing] minor logging improvement in http cli tests (#35654)
as title

Closes #35654

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35654 from apolcyn:fix_logs eb1fbcd7a5
PiperOrigin-RevId: 601198258
2024-01-24 12:26:44 -08:00
Craig Tiller 6b6ce36f74 [fuzzing] Allow server fuzzer to take multiple connection requests at the same time (#35645)
Closes #35645

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35645 from ctiller:shush-multipass e63e1e5ddb
PiperOrigin-RevId: 600998039
2024-01-23 21:19:49 -08:00
Craig Tiller 7507e3b644 [fuzzing] Teach server_fuzzer about the chaotic good protocol (#35643)
No explicit testing yet, just some building blocks

Closes #35643

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35643 from ctiller:shush-chaotic-protocol 48dcaa0632
PiperOrigin-RevId: 600928555
2024-01-23 15:43:34 -08:00
Craig Tiller 19f1b39829 [fuzzer] Eliminate use of mock_endpoint in server fuzzer (#35625)
Instead, connect a real client, which gives us the ability to exercise the listener portion of the code too.

Closes #35625

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35625 from ctiller:shush-connect b8f78993c6
PiperOrigin-RevId: 600836565
2024-01-23 10:40:03 -08:00
Esun Kim af95eafb34 [CI] Using clang-17 for clang tidy & format (#35595)
Clang-17 is now better at formatting. Clang-16 used to do some questionable formatting.

Closes #35595

PiperOrigin-RevId: 600829055
2024-01-23 10:19:25 -08:00
Esun Kim 1a20f21b6b Fixed multi-line comments warning (#35351)
Adding more stuff on top of https://github.com/grpc/grpc/pull/35127

Closes #35351

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35351 from veblush:fix-line 1b25e5df49
PiperOrigin-RevId: 600810979
2024-01-23 09:20:33 -08:00
Craig Tiller 562bc9b363 [fuzzing] better fallback rng (#35621)
`ProtoBitGen` provides a random number generator that returns values directly from fuzzer selected values, which allows us to test-into random selection algorithms deterministically.

Since the list of values provided by the fuzzer is limited, we need a fallback implementation. Previously we'd used something that was very correlated, and some of the distribution algorithms get into a very slow convergence mode when we do that (so we repeatedly return the same value for billions of iterations and cause timeouts in fuzzers).

Instead, when we run out of fuzzer supplied values, seed an mt19937 generator with the fuzzer selected values and use that from there on. Said generator will then produce values deterministically (for a given fuzzer input), but with a better distribution to allow convergence for fiddly algorithms.

Closes #35621

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35621 from ctiller:cg-timeout 6c9ef9cac5
PiperOrigin-RevId: 600607424
2024-01-22 16:45:31 -08:00
Craig Tiller e93f2dfbef [fuzzer] Separate scheduling from schedule creation for network input (#35618)
Closes #35618

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35618 from ctiller:shush ed7afaa4e8
PiperOrigin-RevId: 600557159
2024-01-22 13:43:52 -08:00
Yijie Ma 5bf0971972 [EventEngine] Fix issues found when enabling `event_engine_dns` experiment in OSS (#35530)
Using `AF_UNSPEC` for both IPv4 and IPv6 queries does not work in all cases. Specifically, for `localhost:<>`, c-ares only returns the IPv6 record i.e. `::1`.

<!--

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.

-->

Closes #35530

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35530 from yijiem:enable-oss-ee-dns-posix 452b5a2d81
PiperOrigin-RevId: 599989537
2024-01-19 18:42:26 -08:00
Mark D. Roth b440474655 [XdsClient] Clean up mechanism used to store XdsServer in map keys.
For background, see #32826 and b/276944116.

PiperOrigin-RevId: 599876499
2024-01-19 12:45:01 -08:00
Craig Tiller 1751f1043e [transport] Add a transport test suite for promise based transports (#35476)
Implemented for inproc & chaotic-good

Closes #35476

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35476 from ctiller:v3-svall 5358538d54
PiperOrigin-RevId: 599701775
2024-01-18 20:09:21 -08:00
Craig Tiller 67d6b8ea74 [promise] Context improvements (#35592)
A few improvements to the promise context system (more coming)

Allow subclassed contexts:
If we have multiple different kinds of a base context, allow `GetContext<Derived>()` to mean `down_cast<Derived*>(GetContext<Base>())` everywhere for brevity.

Allow custom context lookup:
For a base context type, allow customization of how that context is looked up.

These two together allow:
1. normalization of activity lookup and context lookup to the same syntax (so we can write `GetContext<Activity>()` everywhere now
2. Party & Activity to share a context, so that anywhere we need to do a party specific operation we can write `GetContext<Party>()->...` and safely know that it's the current activity *and* it's a party.

Closes #35592

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35592 from ctiller:contextual-types 37ef948a36
PiperOrigin-RevId: 599651708
2024-01-18 16:03:46 -08:00
Craig Tiller 98472179fb [promises] Add an observer type (#35552)
We've got a few situations coming up with promises that will want a "broadcast new value to everywhere" situation.

Closes #35552

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35552 from ctiller:obs 30fd697ae3
PiperOrigin-RevId: 599609399
2024-01-18 13:35:49 -08:00
Craig Tiller eb17c1f7de [filters] Optimize construction/destruction (#35591)
Only call constructors when absolutely necessary (empty trivially constructible types don't need construction!!)
Similarly for destructors, if the destructor is trivial it means C++ will do no work destructing it... let's not even do the virtual function call to get there.

(also fix a bug where we weren't calling this stuff anyway, and add a test that would have caught that)

Closes #35591

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35591 from ctiller:filter-min 2933152d61
PiperOrigin-RevId: 599521371
2024-01-18 08:55:04 -08:00
Craig Tiller 584c0c0c98 [call-v3] Filter executor (#35533)
A call execution environment for the V3 runtime.

The `CallFilters` class will ultimately be a (private) member of `CallSpine`, and the `StackBuilder` component will be used by a channel when all of the filters it needs are known to allow the call spine to start processing a call.

This is accompanied by a reasonably extensive test suite.

I expect to fine tune semantics, implementation, and tests over the coming weeks/months as we iterate to bring up the rest of the pieces.

Closes #35533

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35533 from ctiller:filters 689c7b527b
PiperOrigin-RevId: 599220150
2024-01-17 10:39:37 -08:00
Craig Tiller c77ba326e9 [gprpp] Implement down_cast - a debug-time checked down cast (#35548)
Closes #35548

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35548 from ctiller:down_cast cd7501dadd
PiperOrigin-RevId: 599176414
2024-01-17 08:09:02 -08:00
Craig Tiller 9f6789e2b2 [chttp2] Rework settings management to be a c++ type (#35449)
Closes #35449

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35449 from ctiller:h2-settings f67e542a8b
PiperOrigin-RevId: 597970333
2024-01-12 15:21:05 -08:00
Craig Tiller 8a5f659c66 [chaotic-good] Fix fuzzer bug (#35537)
We were getting errors due to insane amounts of padding: enforce limits, fix b/319533934.

Closes #35537

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35537 from ctiller:fff 9f5f31ef27
PiperOrigin-RevId: 597899598
2024-01-12 11:30:22 -08:00
ericsalo a6823b6e97 Fix deprecation warnings from upb (#35510)
Replace "upb:collections" with "upb:message"
Replace "upb/collections" with "upb/message"
Replace "upb:upb" with "upb:mem" and/or "upb:base"
Replace "upb/upb.hpp" with "upb/mem/arena.hpp" and/or "upb/base/status.hpp"

Closes #35510

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35510 from ericsalo:master 112392a050
PiperOrigin-RevId: 597872730
2024-01-12 10:15:56 -08:00
Craig Tiller 02c10df298 [api-fuzzer] Fix inproc channels (#35538)
Closes #35538

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35538 from ctiller:fff2 52b69968a0
PiperOrigin-RevId: 597848114
2024-01-12 08:43:34 -08:00
Yijie Ma 77ad5a786e [CSM O11Y] CSM Service Label Plumbing from LB Policies to CallAttemptTracer (#35210)
<!--

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.

-->

Closes #35210

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35210 from yijiem:csm-service-label 6a6a7d1774
PiperOrigin-RevId: 597641393
2024-01-11 13:37:44 -08:00
Mark D. Roth a446df61f4 [xDS] remove unnecessary string from XdsConfig struct (#35503)
I realized that this field wasn't actually necessary, since the string is already present in the map key.

Closes #35503

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35503 from markdroth:xds_config_remove_cluster_name 94d5edc133
PiperOrigin-RevId: 597375018
2024-01-10 15:42:43 -08:00
Mark D. Roth 6a4b5ccea3 [SSA] change xds_override_host policy to manage subchannels based on last-used time rather than EDS health state (#35397)
Part of the work needed for in-progress gRFC A75 (https://github.com/grpc/proposal/pull/405).

Closes #35397

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35397 from markdroth:xds_ssa_subchannel_management_revamp 8902deafad
PiperOrigin-RevId: 597288930
2024-01-10 10:28:49 -08:00
Mark D. Roth 20e5b2c4bb [xDS] read connection idle timeout from CDS resource (#35395)
Part of the work needed for in-progress gRFC A75 (https://github.com/grpc/proposal/pull/405).

Closes #35395

PiperOrigin-RevId: 597064473
2024-01-09 15:41:22 -08:00
Yash Tibrewal 5888738c5a [OTel] Add a PluginOption API (#35434)
Closes #35434

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35434 from yashykt:OTelPluginOption 1db870bed4
PiperOrigin-RevId: 596966190
2024-01-09 18:28:43 +00:00
Mark D. Roth 0df505d9db [api_fuzzer] Cap the number of comma-delimited strings in the target URI to 1K.
PiperOrigin-RevId: 596739224
2024-01-08 16:54:43 -08:00
Craig Tiller 86522af60d [chaotic-good] Client & server transport (#35400)
Adapts work from https://github.com/grpc/grpc/pull/34728 and previous changes from @nanahpang, implements new v3 filter/transport interface, and brings up the core of the chaotic good transport.

The next change will bring a more complete test suite (for this and inproc).

Closes #35400

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35400 from ctiller:v3-server 737ca5431a
PiperOrigin-RevId: 596621152
2024-01-08 09:46:16 -08:00
Craig Tiller fede9051e1 [call-v3] Begin migration of channel_init to templates.
Eventually for call-v3 we're going to want to have registration of filters generate the appropriate glue into the channel runtime to execute a call.

Begin that process now and gradually by introducing the new syntax and allowing a piecemeal migration to it - by the time we're done converting filters to the v3 APIs we'll also have the registration piece done.

PiperOrigin-RevId: 596013927
2024-01-05 09:34:36 -08:00