Commit Graph

1225 Commits

Author SHA1 Message Date
AJ Heller c9fdef1317 [logging] Centralize configuration for trace flags (#36576)
All TraceFlags are now configured in `src/core/lib/debug/trace_flags.yaml`. The format is:

```
my_flag:
  default: false                   # the default value; default=false
  description: Some Description
  debug_only: false                # debug_only flags only work in debug builds; default=false
  internal: false                  # internal flags will not show up in documentation; default=false
```

To regenerate the trace flag source code, run `tools/codegen/core/gen_trace_flags.py` (requires mako). This script is also run when sanity checking.

This PR also adds two new features:

### Glob-based flag configuration

Trace flag configuration now supports `?` (single wildcard character) and `*` (one or more wildcard characters).  For example, using `GRPC_TRACE='event_engine*'` will enable all flags that match that glob. It expands to:

* event_engine
* event_engine_client_channel_resolver
* event_engine_dns
* event_engine_endpoint
* event_engine_endpoint_data
* event_engine_poller

### A cleaner trace-logging macro in abseil logging format

If your goal is only to add log statements when the `fault_injection_filter` trace flag is enabled, you can use the macro:

```
GRPC_TRACE_LOG(fault_injection, INFO) << "Filtered:" << 42;
```

When the trace flag is enabled, the the log will show something like this:
```
I0000 00:00:1715733657.430042      16 file.cc:174] Filtered:42
```

----

Note: just like with the gpr_log to abseil logging conversion, the pre-existing trace logging usages can be replaced with the new tracing macro across multiple PRs.

Closes #36576

PiperOrigin-RevId: 641295215
2024-06-07 10:47:38 -07:00
Craig Tiller 90a649fd3f [call-v3] Client call implementation (#36724)
Closes #36724

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36724 from ctiller:transport-refs-8 51cf92ab82
PiperOrigin-RevId: 640558652
2024-06-05 09:57:33 -07:00
Mark D. Roth e4daabc8bc [reorg] move ext/gcp/metadata_query.* -> util/gcp_metadata_query.* (#36789)
Also rename the class from `MetadataQuery` to `GcpMetadataQuery`.

Closes #36789

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36789 from markdroth:reorg_gcp_metadata_query d2b84f46be
PiperOrigin-RevId: 639256546
2024-05-31 22:40:20 -07:00
Mark D. Roth 34ac4ee5de [grpc_error] remove unnecessary status attributes (#36523)
The following attributes were completely unused:
- kOffset
- kIndex
- kSize
- kFilename
- kKey
- kValue

The following attributes were added but never programmatically accessed, and I've moved them into the status messages themselves, which is another step toward #22883:
- kErrorNo
- kTsiCode
- kWsaError
- kHttpStatus
- kOsError
- kSyscall
- kTargetAddress
- kRawBytes
- kTsiError

Closes #36523

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36523 from markdroth:grpc_error_attribute_cleanup b289c399fe
PiperOrigin-RevId: 639147583
2024-05-31 14:11:42 -07:00
Mark D. Roth 82756e9ce0 Automated rollback of commit fbd8ebe7cd.
PiperOrigin-RevId: 638821486
2024-05-30 16:23:47 -07:00
gRPC Team Bot fbd8ebe7cd Automated rollback of commit db2d775ffc.
PiperOrigin-RevId: 638442984
2024-05-29 16:09:03 -07:00
Craig Tiller 34871fafa3 [call-v3] New client channel implementation (#36723)
Closes #36723

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36723 from ctiller:transport-refs-7 e019b8f5ea
PiperOrigin-RevId: 638424601
2024-05-29 15:06:01 -07:00
Mark D. Roth db2d775ffc [reorg] move src/core/lib/http -> src/core/util/http_client (#36710)
Closes #36710

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36710 from markdroth:reorg_httpcli 6c751e34b2
PiperOrigin-RevId: 638358691
2024-05-29 11:42:19 -07:00
Xuan Wang ecdb5caf83 [BoringSSL] Update third_party/boringssl-with-bazel (#36716)
Change was created by the release automation script. See go/grpc-release.

Closes #36716

PiperOrigin-RevId: 638337588
2024-05-29 10:46:22 -07:00
Mark D. Roth fe817c8ab1 [reorg] move lib/json -> util/json (#36645)
Closes #36645

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36645 from markdroth:reorg_json 5b6434dd44
PiperOrigin-RevId: 636757495
2024-05-23 19:51:49 -07:00
Mark D. Roth 6c08d36c3b [reorg] move telemetry code to src/core/telemetry (#36644)
Closes #36644

PiperOrigin-RevId: 636702732
2024-05-23 15:54:07 -07:00
Mark D. Roth 58a4b9c922 [reorg] move src/core/lib/gpr -> src/core/util (#36543)
Closes #36543

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36543 from markdroth:reorg_util_gpr ba84e186be
PiperOrigin-RevId: 634113744
2024-05-15 16:32:20 -07:00
Craig Tiller 0ecee5ad3f [call-v3] Server path (#36509)
<!--

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 #36509

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36509 from ctiller:transport-refs-3 2771a2b0e1
PiperOrigin-RevId: 633240374
2024-05-13 09:45:09 -07:00
Yash Tibrewal 87b71907d6 [Release] Bump version to 1.65.0-dev (on master branch) (#36544)
Change was created by the release automation script. See go/grpc-release.

Closes #36544

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36544 from yashykt:bump_dev_version_202405061956 69ee5c869e
PiperOrigin-RevId: 631187829
2024-05-06 14:41:36 -07:00
Mark D. Roth 32e03171e7 [reorg] move xds code to src/core/xds (#36521)
Also do some cleanup in CODEOWNERS.

Closes #36521

PiperOrigin-RevId: 631137895
2024-05-06 11:57:32 -07:00
Mark D. Roth 1e5fc3df8b [reorg] move server code to src/core/server (#36475)
Closes #36475

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36475 from markdroth:reorg_server 30edc04c0f
PiperOrigin-RevId: 629776917
2024-05-01 11:16:02 -07:00
Craig Tiller e614dafd89 [woah] Remove deadline filter (#36477)
Also begin to eliminate `CallContext` in favor of just exposing `Call` - ultimately there's not really a need to introduce two types here, so I'm going to wind that idea back over a few PRs.

I've avoided making this an experiment as the changes required were quite structural.

Closes #36477

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36477 from ctiller:deadline-time 9856eeebe6
PiperOrigin-RevId: 629599230
2024-04-30 19:45:22 -07:00
Yash Tibrewal a0bee78a28 [BoringSSL] Update third_party/boringssl-with-bazel (#36435)
Change was created by the release automation script. See go/grpc-release.

Closes #36435

PiperOrigin-RevId: 629574967
2024-04-30 17:28:00 -07:00
Mark D. Roth 6e981d7460 [reorg] move handshaker code to src/core/handshaker (#36375)
Closes #36375

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36375 from markdroth:reorg_handshaker d1ed49f4df
PiperOrigin-RevId: 629497065
2024-04-30 12:42:01 -07:00
Tanvi Jagtap f68f8e8fa3 [grpc][Gpr_To_Absl_Logging] Migrating from gpr to absl logging GPR_ASSERT (#36466)
[grpc][Gpr_To_Absl_Logging] Migrating from gpr to absl logging GPR_ASSERT
Replacing GPR_ASSERT with absl CHECK.
These changes have been made using string replacement and regex.
Will not be replacing all instances of CHECK with CHECK_EQ , CHECK_NE etc because there are too many callsites. Only ones which are doable using very simple regex with least chance of failure will be replaced.
Given that we have 5000+ instances of GPR_ASSERT to edit, Doing it manually is too much work for both the author and reviewer.

<!--

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 #36466

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36466 from tanvi-jagtap:tjagtap_src_core_lob_event_engine d101d5f701
PiperOrigin-RevId: 629105415
2024-04-29 10:15:57 -07:00
Craig Tiller d52779da52 [call-v3] Interception chain (#36414)
Introduce the interception chain type.
Also introduces the real call-v3 call spine based atop CallFilters.

Closes #36414

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36414 from ctiller:interception-chain 90c8e96973
PiperOrigin-RevId: 627784183
2024-04-24 11:03:13 -07:00
Mark D. Roth 08f56b3a74 [reorg] move channelz code to src/core/channelz (#36380)
Closes #36380

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36380 from markdroth:reorg_channelz f186e53f70
PiperOrigin-RevId: 626447939
2024-04-19 13:05:23 -07:00
Yijie Ma cd30592193 [release] Bump dev version 202404101721 (#36333)
<!--

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 #36333

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36333 from yijiem:bump_dev_version_202404101721 0a7cc5b4b7
PiperOrigin-RevId: 623878150
2024-04-11 11:04:35 -07:00
Esun Kim 34a7e76359 [Deps] Rollfoward Protobuf upgrade to v26.1 (#36323)
This reverts commit 78b9d84fd3.

Closes #36323

PiperOrigin-RevId: 623547891
2024-04-10 11:07:26 -07:00
Esun Kim 78b9d84fd3 [Dep] Rollback Protobuf upgrade to v25.1 (#36247)
This is for gRPC Python that has an issue with Protobuf Python v26

Closes #36247

PiperOrigin-RevId: 621629528
2024-04-03 13:56:36 -07:00
Mark D. Roth 0aebe1c7b6 [authz] get endpoint local/peer addresses via a handshaker (#36237)
This paves the way for removing `GetEndpoint()` from the transport API, which is a prereq for removing `grpc_endpoint_shutdown()`.

Closes #36237

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36237 from markdroth:endpoint_filter_cleanup_rbac 46a41400e0
PiperOrigin-RevId: 621537397
2024-04-03 08:55:15 -07:00
Craig Tiller e78ec82a2c [call-v3] Remove CallFactory (#36226)
This was a concept that I thought we'd need, but as work has continued it's clear that the right api is CallDestination (or variants thereof)

Closes #36226

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36226 from ctiller:call_factory c30a893f3a
PiperOrigin-RevId: 621255162
2024-04-02 12:11:11 -07:00
Craig Tiller adf6c7b644 [idle] Remove v3 channel idle filter experiment (#36213)
It looks like we're settling on moving this functionality into the channel itself - so removing the filter makes sense (especially since it had some significant bugs)

Closes #36213

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36213 from ctiller:x-ex 3040dcec95
PiperOrigin-RevId: 620996358
2024-04-01 17:15:27 -07:00
Esun Kim 03312884dc [Deps] Upgraded protobuf to v26.1 (#35796)
This is to upgrade Protobuf to v26.1 along with upb, and utf8_range.

Closes #35796

PiperOrigin-RevId: 620259696
2024-03-29 09:19:06 -07:00
Mark D. Roth e715261ac6 [slice] remove absl_base64 experiment (#36178)
Closes #36178

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36178 from markdroth:b64_remove 0139e3bce8
PiperOrigin-RevId: 619288082
2024-03-26 13:16:27 -07:00
Craig Tiller ca478bd429 [experiments] Remove some, extend some (#36166)
Remove rolled out experiments v3_compression_filter, v3_server_auth_filter; Extend WIP v3_channel_idle_filter for a bit, and extend work_serializer_clears_time_cache until OSS issues with work_serializer_dispatch are resolved.

Closes #36166

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36166 from ctiller:updat3 2c7223f63b
PiperOrigin-RevId: 619057925
2024-03-25 21:35:03 -07:00
Tanvi Jagtap 2c49416713 [grpc][Gpr_To_Absl_Logging] Using absl from within gpr logging (#36108)
![Config_Vars_Absl (1)](https://github.com/grpc/grpc/assets/139093547/04d9b75c-dd1c-42ee-81a3-d20e2bbd5672)

<!--

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 #36108

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36108 from tanvi-jagtap:tjagtap_config_vars c48a3524f0
PiperOrigin-RevId: 615652000
2024-03-13 22:04:47 -07:00
Vignesh Babu 7533328075 [server] Allow configuring max incoming connections at the server (#36088)
Closes #36088

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36088 from Vignesh2208:server-fix e62a8f7ae7
PiperOrigin-RevId: 614729878
2024-03-11 11:17:34 -07:00
Mark D. Roth c43f1a63b0 [RLS] implement non-per-call metrics (#36001)
Closes #36001

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36001 from markdroth:non_per_call_metrics_rls b713980f21
PiperOrigin-RevId: 612532005
2024-03-04 11:58:31 -08:00
Mark D. Roth 0213523907 [build] move channel out of grpc_base (#35924)
This adds the following new targets:
- `channel`: A virtual interface for a channel.
- `legacy_channel`: A channel implementation that supports the filter stack and call v2.
- `channel_create`: A standalone function to create a channel.
- `server_interface`: A base class with a few accessor methods used in surface/call.cc.
- `server`: The actual server implementation.
- `api_trace`, `call_tracer`, `server_call_tracer_filter`, `call_finalization`: These were split out of `grpc_base` to avoid various dependency problems.
- `compression`: This is a combination of the previously existing `compression_internal` target and the compression code that was part of `grpc_base`.

Closes #35924

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35924 from markdroth:channel_interface 94a7fffddb
PiperOrigin-RevId: 612512438
2024-03-04 11:07:17 -08:00
Alisha Nanda fa2bae473a [metadata] Expose metadata limits and annotation info to filter stack (#35970)
<!--

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 #35970

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35970 from ananda1066:client_metadata b62a9ae146
PiperOrigin-RevId: 610830228
2024-02-27 12:07:35 -08:00
Mark D. Roth 40577dd585 [WRR] implement non-per-call metrics (#35977)
As per gRFC A78 (https://github.com/grpc/proposal/pull/419).

Note that these new metrics are populated only if the `wrr_delegate_to_pick_first` experiment is enabled, which is the case by default.

Closes #35977

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35977 from markdroth:non_per_call_metrics_wrr 7acea32fc4
PiperOrigin-RevId: 610760874
2024-02-27 08:32:09 -08:00
Matthew Stevenson 51bccbdcf9 [ssl] Support Windows system roots. (#34874)
This PR is copied from #34276, since I did not have permissions to add commits to it. That PR has been verified to work (see the top-level description). This PR just makes the gRPC tests pass (e.g. adding includes, clang formatting).

Closes #34874

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34874 from matthewstevenson88:pull_34276 d5fb73e5b2
PiperOrigin-RevId: 609107146
2024-02-21 13:40:46 -08:00
Mark D. Roth cfcbb0a535 [build] move parts of the `grpc_client_channel` BUILD target out into their own targets (#35879)
This breaks the following pieces out of the `grpc_client_channel` BUILD target:
- backend_metric_parser
- oob_backend_metric
- child_policy_handler
- backup_poller
- service_config_channel_arg_filter
- client_channel_channelz
- client_channel_internal_header
- subchannel_connector
- subchannel_pool_interface
- config_selector
- client_channel_service_config_parser
- retry_service_config_parser
- retry_throttle

The code left in the `grpc_client_channel` target will need more work to pull apart.

Closes #35879

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35879 from markdroth:client_channel_build_split f388a37edc
PiperOrigin-RevId: 608806548
2024-02-20 18:06:37 -08:00
Mark D. Roth 179e0f952f [build] move parts of the `grpc_base` BUILD target out into their own targets (#35846)
This breaks the following pieces out of the `grpc_base` BUILD target:
- channelz
- call_trace
- dynamic_annotations
- call_combiner
- resource_quota_api
- iomgr

More work is still needed to pull apart the remaining parts of `grpc_base`.

Closes #35846

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35846 from markdroth:client_channel_build_dep_cycle_fix f1a9b6c2b2
PiperOrigin-RevId: 608680098
2024-02-20 11:36:46 -08:00
Esun Kim 34be0d84a9 [Core] Remove wrap_memcpy (#35826)
gRPC has been having the `wrap_memcpy` workaround to handle the breaking change of `memcpy` on glibc 2.14 ([ref1](https://www.win.tue.nl/~aeb/linux/misc/gcc-semibug.html), [ref2](https://stackoverflow.com/questions/35656696/explanation-of-memcpy-memmove-glibc-2-14-2-2-5)). This was necessary to build more portable artifacts which are expected to run on most linux distributions and we manged to have https://github.com/grpc/grpc/pull/5007 years ago for this.

Since we started to use manylinux2010-based docker images for artifacts, however, this became unnecessary since CentOS 6 has glibc 2.12 which is older than 2.14 so it doesn't have memcpy issue, which is another benefit of using manylinux2010.

Superseding https://github.com/grpc/grpc/pull/23385
Changes after the original PR was made; Ruby is using manylinux images (manylinux2014) enabling this change, no more old docker images in our test env.

Closes #35826

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35826 from veblush:del-wrap-memcpy-2 71e6718356
PiperOrigin-RevId: 607499060
2024-02-15 16:53:19 -08:00
Eugene Ostroukhov 6c157f9128 [Release] Bump version to 1.63.0-dev (on master branch) (#35899)
Change was created by the release automation script. See go/grpc-release.

Closes #35899

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35899 from eugeneo:bump_dev_version_202402131133 73950425c9
PiperOrigin-RevId: 606777850
2024-02-13 16:09:36 -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
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
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
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
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
Craig Tiller 610f439342 [channel] Add CallFactory, CallDestination (#35766)
Closes #35766

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35766 from ctiller:chan3 ea9a3260e3
PiperOrigin-RevId: 603437058
2024-02-01 11:58:14 -08:00
Esun Kim 1f979d2a83 [BoringSSL] Update third_party/boringssl-with-bazel (#35768)
Change was created by the release automation script. See go/grpc-release.

On top of changes made by the script, `setup.py` had to be updated to have `/std:c11` option for MSVC to use c11 features for boringssl.

Closes #35768

PiperOrigin-RevId: 603403329
2024-02-01 10:06:33 -08:00