Commit Graph

8290 Commits

Author SHA1 Message Date
Craig Tiller 8448d499e2 [promises] Add `AllOk` combinator (#35304)
`AllOk` runs a set of promises concurrently, and like `TryJoin` waits for them all to succeed or one to fail.
Unlike `TryJoin` it returns a single unified status of the composition, so cannot handle member promises that might return `StatusOr` or the like.

Closes #35304

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35304 from ctiller:all-review 30f5f809c6
PiperOrigin-RevId: 591031189
2023-12-14 13:21:35 -08:00
Esun Kim 9677ab7682 Updated zlib to 1.3 (#35147)
Closes #35147

PiperOrigin-RevId: 591028632
2023-12-14 13:12:45 -08:00
Gregory Cooke 12c0058bf2 [Security - Testing] OpenSSL 1.0.2 and 1.1.1 CI Testing (#35236)
Enable OpenSSL 1.0.2 tests and add a container for 1.1.1 so that it is tested during portability testing as well.

Closes #35236

PiperOrigin-RevId: 590345568
2023-12-12 14:52:43 -08:00
Xuan Wang 7f2ecdb3f8 [Python Observability] Building package and add to run_test (#34207)
### Changes in this PR
* Refactor and remove some Core/C++ dependencies to simplify Python Observability package build process.
* Refactored code to read config at Python layer.
* Enable observability build from source.
* Add observability to run_test.
  * Currently it's only enabled in Linux.
* Add error handler in run_test loaders.
  * Current framework will always visit modules in test directory then decide which tests to skip.
  * Since we're not building Observability for MacOS and Windows this step will fail with error `No module named 'grpc_observability'`.
  * After the change we'll just skip those modules.
    * We still have `_sanity_test` to make sure all tests are loaded correctly for each platform.
* Remov OC dependency as we're migrating to OTel.
  * Also removed trace from testing.
  * Note that trace propagation function was also removed because of this.

### Testing
* Passed existing tests.
* Tested locally, able to build observability from source using `GRPC_PYTHON_BUILD_WITH_CYTHON=1 pip install .`.

<!--

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

PiperOrigin-RevId: 590258014
2023-12-12 10:51:35 -08:00
Hannah Shi 42b57fc632 [ObjC] Support use frameworks! (#34921)
1. add swift example configured with `use_frameworks!`.

2. fix [unable to find C++ headers](https://source.cloud.google.com/results/invocations/2100300a-0b61-4e56-8a77-113e362f2c63/targets/grpc%2Fcore%2Fpull_request%2Fmacos%2Fgrpc_basictests_objc_examples/log) by renaming `.m` files to `.mm`.
`/Volumes/BuildData/tmpfs/altsrc/github/grpc/workspace_objc_macos_opt_native/src/objective-c/examples/SwiftUseFrameworks/Build/Build/Build/Products/Debug-iphoneos/gRPC-Core/grpc.framework/Headers/grpc_audit_logging.h:24:10: fatal error: 'memory' file not found #include <memory>`

3. fix [cyclic dependency errors](https://source.cloud.google.com/results/invocations/90972079-eade-4c07-a5c4-20f139c64d4e/targets/github%2Fgrpc%2Frun_tests%2Fobjc_macos_opt_native%2Fios-buildtest-example-switftsample/tests) by making `openssl/time.h` private.
`/Applications/Xcode_14.1.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.1.sdk/usr/include/dispatch/dispatch.h:25:10: error: cyclic dependency in module 'Darwin': Darwin -> openssl_grpc -> UIKit -> Foundation -> CoreFoundation -> Dispatch -> Darwin`

"Basic Tests ObjC Examples" succeeds with this PR:
https://source.cloud.google.com/results/invocations/cff74ec0-43ca-43b9-a2ff-12edabc02896/targets

Closes #34921

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34921 from HannahShiSFB:support-use-frameworks 87ddd23090
PiperOrigin-RevId: 589300261
2023-12-08 18:57:08 -08:00
Leonardo Pistone dfa9d853ff Fix Python DeprecationWarning: 'pipes' (#34941)
Starting from Python 3.11, the pipes module produces this warning:

DeprecationWarning: 'pipes' is deprecated and slated for removal in Python 3.13

Turns out that in this repo the pipes module is only used for the
"quote" function which is turn directly taken from the shlex module [1].

The shlex module is not deprecated as of today and is already used in
other places in this repo. The function shlex.quote has been around
since the ancient Python 3.3.

[1] https://github.com/python/cpython/blob/3.11/Lib/pipes.py#L64-L66

<!--

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

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34941 from lepistone:deprecate-python-pipes 233c54c135
PiperOrigin-RevId: 588883480
2023-12-07 13:02:23 -08:00
Yijie Ma 1abfc97502 [EventEngine] Posix NativeDNSResolver implementation (#35153)
<!--

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

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35153 from yijiem:native_dns_resolver a4107f7d81
PiperOrigin-RevId: 588543137
2023-12-06 14:25:38 -08:00
Sergii Tkachenko b570879010 [PSM Interop] Log on debug level when resource deletion failure is 404 (#35131)
Removes noise from the cleanup/teardown ops.

#### GCP APIs

In GCP APIs, change log level for delete operations that failed because the resource doesn't exist (API 404) from `info` to `debug`.  Framework's logging philosophy is to only log external operations (e.g. APIs, RPCs). If no error logged, the op is assumed successful.
In the deletion case, is still possible to discriminate between whether the op was actually performed by observing the `Waiting %s sec for %s operation id: %s` log message.

#### K8s APIs
In K8s APIs:
- For delete operations that failed because the resource doesn't exist (API 404) the log level is changed from `info` to `debug`
- For delete operations that failed for any other reason, the log level is changed from `info` to `warning`
- When `wait_for_deletion` is enabled (it's the default) the delete operation will be confirmed with `logger.info("<resource_kind> %s deleted", name)`. Previously it logged at the `debug` level.

Closes #35131

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35131 from sergiitk:psm-interop-debug-log-on-delete-404 f6629e5132
PiperOrigin-RevId: 587851692
2023-12-04 15:01:51 -08:00
Tanvi Jagtap 207b881868 [grpc] Remove redundant check (#35161)
We dont need this check anymore .

Deleting the check from the yaml and the sh file.

<!--

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

PiperOrigin-RevId: 587784923
2023-12-04 11:21:42 -08:00
Vignesh Babu 84678829af [EventEngine] Add public methods to allow EventEngine Endpoints to support optional Extensions.
PiperOrigin-RevId: 587071965
2023-12-01 11:43:08 -08:00
Craig Tiller 57d8462aee Remove IWYU requirements for changes
PiperOrigin-RevId: 586404245
2023-11-29 11:34:28 -08:00
Sergii Tkachenko 5281789883 [PSM Interop] Check for active ADS in Security and URL Map tests (#34968)
`test_client.wait_for_server_channel_ready` was not called in `SecurityXdsKubernetesTestCase` and `XdsUrlMapTestCase`.
Initial PR: https://github.com/grpc/grpc/pull/34631.

Closes #34968

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34968 from sergiitk:psm-interop-secure-tests-ads a71b422c1c
PiperOrigin-RevId: 583180208
2023-11-16 15:16:02 -08:00
Craig Tiller f11c010e51 [promises] Add awaitable spawn to Party (#34744)
Add a variant of `Spawn` that returns a promise that can be awaited by another activity.
This allows us to simply implement complex cross-activity synchronization.

(necessary building block for #34740)

Also adds an inter-activity latch as a building block to test this work.

Closes #34744

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/34744 from ctiller:ninteen-ninety-nine 19074b255f
PiperOrigin-RevId: 582450643
2023-11-14 14:59:54 -08:00
Craig Tiller dc41f42073
[promises] Add some status-like types for TrySeq (#34906)
`StatusFlag` acts like a status, but is just a boolean (we don't want to
accidentally treat a boolean as something that indicates failure in case
it's not)

Similarly `ValueOrFailure` looks like `StatusOr` but reduces the failure
space to one value.

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-11-10 09:14:44 -08:00
Xuan Wang b99d63f423
[Python Test] Increase Python Windows build artifact timeout (#34914)
We're seeing timeout errors in our distribution test:
https://fusion2.corp.google.com/invocations/dfa9aaa9-e94b-479e-8c28-a39d98d277bc/targets/github%2Fgrpc%2Fbuild_artifacts_python;config=default/tests.

Sample error:
`2023-11-10 09:12:19,512 TIMEOUT:
build_artifact.python_windows_x86_Python39_32bit [pid=2320,
time=2700.1sec]`

This change increases timeout for windows build artifact jobs to 7200s,
which aligns with all other jobs (except `linux_extra`, which is 3600s).

<!--

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.

-->
2023-11-10 09:10:42 -08:00
Adam Cozzette 016ed921ce
[deps] Upgrade protobuf version to v25.0 (#34513)
This commit upgrades gRPC to protobuf v25.0 and makes some fixes to
account for upb changes. One major change is that upb has been merged
into the protobuf repo, so we can now drop the separate `@upb`
dependency. Another is that `.upb.c` files no longer exist and there are
new `.upb_minitable.h` and `.upb_minitable.c` files. The longer
filenames exceeded a Windows restriction, so to work around that I
renamed the `upb-generated` directory to just `upb-gen`, and likewise
for `upbdefs-generated`.
2023-11-10 00:11:09 -08:00
Craig Tiller 3964acc806
[promises] Add an intra-activity mutex type (#34824)
Modeled after mutexes in the Rust ecosystem: the mutex owns the data
provided, and acquisition of the mutex returns a handle with which to
manipulate that data.

This fits in nicely with the execution environment we've established
whereby we may want to pass the lock from lambda to lambda for some
time.

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-11-08 16:41:26 -08:00
nanahpang 1e15d00ec4
[chaotic-good] Add client transport error handling. (#34611)
This is a follow-up PR of #34191, which handles the error condition of
endpoints failed to write/read in chaotic-good client transport.

This PR needs to be merged after #34191.

<!--

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.

-->
2023-11-08 14:42:20 -08:00
Vignesh Babu 77e9fe49aa
Revert "[security] Support a list of SSL ECs" (#34900)
Breaks internal tests
2023-11-08 14:05:02 -08:00
Yijie Ma d3828ebfbd
[Fork] Add ObjectGroupForkHandler fork-handling system (#33733)
<!--

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: Bradley Hess <bdhess@google.com>
Co-authored-by: AJ Heller <hork@google.com>
2023-11-07 17:48:13 -08:00
Sergii Tkachenko 434a5c8e72
[PMS Interop] ADS detection: minor wording change (#34895)
Now we log pretty much identical message:

```
client_app.py:320] [psm-grpc-client-7768f6597-nvtgl] Detected successful calls to xDS control plane: trafficdirector.googleapis.com:443
client_app.py:292] [psm-grpc-client-7768f6597-nvtgl] ADS: Detected successful calls to xDS control plane trafficdirector.googleapis.com:443
```

This PR will log the latest channel state in the first message, similar
to what we do in `find_server_channel_with_state`:


52c08f4498/tools/run_tests/xds_k8s_test_driver/framework/test_app/client_app.py (L367-L371)

After the change:

```
client_app.py:320] [psm-grpc-client-6566595cff-8wrfd] Detected successful calls to xDS control plane trafficdirector.googleapis.com:443, channel: <Channel channel_id=4 target=trafficdirector.googleapis.com:443 call_started=9 calls_failed=8 state=READY>
client_app.py:292] [psm-grpc-client-6566595cff-8wrfd] ADS: Detected successful calls to xDS control plane trafficdirector.googleapis.com:443
```
2023-11-07 10:54:07 -08:00
Luwei Ge eaa72802a0
[security] Support a list of SSL ECs (#34867)
Addresses #23235
2023-11-03 14:17:28 -07:00
Gregory Cooke 0d4e1ef5df
[Security - Revocation] Crl Directory Watcher Implementation (#34749)
This adds the directory reloader implementation of the CrlProvider. This
will periodically reload CRL files in a directory per [gRFC
A69](https://github.com/grpc/proposal/pull/382)

Included in this is the following:
* A public API to create the `DirectoryReloaderCrlProvider`
* A basic directory interface in gprpp and platform specific impls for
getting the list of files in a directory (unfortunately prior C++17,
there is no std::filesystem, so we have to have platform specific impls)
* The implementation of `DirectoryReloaderCrlProvider` takes an
event_engine and a directory interface. This allows us to test using the
fuzzing event engine for time mocking, and to implement a test directory
interface so we avoid having to make temporary directories and files in
the tests. This is notably not in `include`, and the
`CreateDirectoryReloaderCrlProvider` is the only way to construct one
from the public API, so we don't expose the event engine and directory
details to the user.

---------

Co-authored-by: gtcooke94 <gtcooke94@users.noreply.github.com>
2023-11-03 20:48:05 +00:00
Matthew Stevenson 52f9e011f3
[tls] Allow skipping server cert verification when no default roots are present. (#34859)
This PR fixes a bug identified in #29667, where the TLS channel
credentials still require a trust bundle even if the user has explicitly
opted to not verify the server certificate. This PR is based on #29810.
2023-11-03 10:23:10 -07:00
Stanley Cheung fb5a3fad57
[PSM Interop] Exclude PSM interop test target from being built by cmake (#34836)
We added the `:grpcpp_csm_observability` dependency to the
`test/cpp/interop:xds_interop_<client|server>` target in
https://github.com/grpc/grpc/pull/34832, but those targets cannot be
built by cmake.

Cmake error:
https://source.cloud.google.com/results/invocations/5e30e5f6-684b-4103-b831-b154cb9ad712/targets/%2F%2Ftools%2Fbazelify_tests%2Ftest:runtests_cpp_linux_dbg_build_only/log

So we are trying to see if we can exclude those 2 targets from being
built by cmake
2023-10-31 20:16:17 -07:00
Stanley Cheung 2091d31ccf
[PSM Interop] Add PodMonitoring resource to psm xds interop testing framework (#34752)
Add a `PodMonitoring` resource type to the PSM interop testing
framework. This is needed so that GMP (Google Managed Prometheus) can
scrape the matching GKE pods Prometheus endpoint for Prometheus metrics.
2023-10-31 14:40:06 -07:00
Xuan Wang 341c52e562
[PSM Interop] Changing xds server to xDS control plane in error message (#34808)
<!--

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.

-->
2023-10-27 11:06:07 -07:00
Xuan Wang 942e2b1dfd
[PSM Interop] Log Google Cloud API debug header part 3 (#34755)
In case of test fails, the clean up script will try delete some resource
we didn't create and resulting lots of 404 errors, we should exclude
those status code since we have specific handling for 404.

<!--

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.

-->
2023-10-26 16:00:17 -07:00
AJ Heller 6f0feaa43f
[test] Delete stranded event test (#34784)
This was a regression test for epollex, which was deleted. It
consistently takes 9 to 12 minutes to run.
2023-10-24 11:23:47 -07:00
Yash Tibrewal 77824d8093
[chttp2] Fix outgoing data stats (#34693)
Earlier, the grpc message-length prefix for outgoing data messages was
incorrectly being counted towards `data_bytes` instead of
`framing_bytes`. This PR fixes it.

Note that the incoming stats collection properly attributes the grpc
message-length prefix to `framing_bytes`.

This change will affect all stats plugins (OpenCensus and OpenTelemetry)
that make use of this information for metrics.
2023-10-23 17:04:48 -07:00
Xuan Wang b16fa809e9
[PSM Interop] Add a step to wait for active XDS channel when start test client. (#34631)
* Logs when XDS channel check passed:
```
I1010 22:53:35.013700 140608769881920 client_app.py:278] [psm-grpc-client-9b5756c77-4gv6d] Waiting to report an active channel to trafficdirector.googleapis.com:443
I1010 22:53:38.879174 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=2 calls_failed=2 state=READY>
I1010 22:53:49.002596 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=5 calls_failed=5 state=READY>
I1010 22:53:59.130141 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=6 calls_failed=6 state=READY>
I1010 22:54:09.253418 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=7 calls_failed=7 state=READY>
I1010 22:54:19.386313 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=8 calls_failed=8 state=READY>
I1010 22:54:35.517963 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=8 calls_failed=8 state=READY>
I1010 22:55:00.638522 140608769881920 client_app.py:306] [psm-grpc-client-9b5756c77-4gv6d] xds channel: <Channel channel_id=10 target=trafficdirector.googleapis.com:443 call_started=10 calls_failed=8 state=READY>
I1010 22:55:00.638787 140608769881920 client_app.py:314] [psm-grpc-client-9b5756c77-4gv6d] Found an active XDS channel
I1010 22:55:00.638983 140608769881920 client_app.py:288] [psm-grpc-client-9b5756c77-4gv6d] Channel to trafficdirector.googleapis.com:443 transitioned to active
I1010 22:55:00.639290 140608769881920 client_app.py:240] [psm-grpc-client-9b5756c77-4gv6d] Waiting to report a READY channel to xds:///psm-grpc-server:8080
I1010 22:55:00.749331 140608769881920 client_app.py:347] [psm-grpc-client-9b5756c77-4gv6d] Server channel: <Channel channel_id=5 target=xds:///psm-grpc-server:8080 call_started=2215 calls_failed=1753 state=READY>
```
* Error Message when XDS channel check failed:
```
E1010 23:09:15.111581 140016347227968 base_testcase.py:60] ERROR Traceback in __main__.BaselineTest.test_traffic_director_grpc_setup:
Traceback (most recent call last):
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/tests/baseline_test.py", line 53, in test_traffic_director_grpc_setup
    test_client: _XdsTestClient = self.startTestClient(test_server)
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_testcase.py", line 787, in startTestClient
    return self._start_test_client(test_server.xds_uri, **kwargs)
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_testcase.py", line 798, in _start_test_client
    test_client.wait_for_active_xds_channel(
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/framework/test_app/client_app.py", line 171, in wait_for_active_xds_channel
    return self.wait_for_xds_channel_active(
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/framework/test_app/client_app.py", line 283, in wait_for_xds_channel_active
    channel = retryer(
  File "/usr/local/google/home/xuanwn/.pyenv/versions/310xds/lib/python3.10/site-packages/tenacity/__init__.py", line 423, in __call__
    do = self.iter(retry_state=retry_state)
  File "/usr/local/google/home/xuanwn/.pyenv/versions/310xds/lib/python3.10/site-packages/tenacity/__init__.py", line 369, in iter
    return self.retry_error_callback(retry_state=retry_state)
  File "/usr/local/google/home/xuanwn/workspace/xds/grpc/tools/run_tests/xds_k8s_test_driver/framework/helpers/retryers.py", line 141, in error_handler
    raise RetryError(
framework.helpers.retryers.RetryError: Retry error calling framework.test_app.client_app.XdsTestClient.find_active_xds_channel: timeout 0:05:00 (h:mm:ss) exceeded. Last exception: ChannelNotActive: [psm-grpc-client-755fc5b468-qkh22] Client has no active channel with xds server trafficdirector.googleapis.com:443
```

<!--

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: Sergii Tkachenko <hi@sergii.org>
2023-10-23 09:32:18 -07:00
Craig Tiller 8f14e37b11
Revert "[chaotic-good] Add chaotic good client transport read (roll-forward)" (#34761)
Reverts grpc/grpc#34657
2023-10-20 08:19:56 -07:00
nanahpang a78145514d
[chaotic-good] Add chaotic good client transport read (roll-forward) (#34657)
Roll forward #34191, which is reverted due to error `2023-10-09
22:01:18,569 FAILED: cmake/build/client_transport_test
--gtest_filter=ClientTransportTest.AddMultipleStreams
GRPC_POLL_STRATEGY=none` (Removed uses_event_engine=False,
uses_polling=False in test build).

<!--

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.

-->
2023-10-19 18:01:49 -07:00
Gregory Cooke 9969d820b5
[TLS - Revocation] Crl Provider (#34715)
This reverts commit 7af5efcfd3.
2023-10-19 11:33:41 -07:00
Xuan Wang 43661ab364
[Python run_test] Revert "Revert "[Python run_test] Fix run_test"" (#34671)
Reverts grpc/grpc#34667

The change was reverted because it failed to import to g3, after some
changes, now it's safe to reapply those changes.

Tested by importing this PR internally, it passed presubmit:
cl/573836270
2023-10-19 09:47:17 -07:00
Sergii Tkachenko 6d741ca724
[PSM Interop] README.md typo fix (#34576)
`baseline tests` should've been an anchor, not a directory.
2023-10-18 12:34:15 -07:00
Sergii Tkachenko 0cdcb2a2bf
[PSM Interop] Support --noenable_workload_identity in helper scripts (#34619)
Example:

```
./run.sh bin/run_test_client.py --noenable_workload_identity
```
2023-10-18 12:08:37 -07:00
apolcyn 7af5efcfd3
Revert "[TLS - Revocation] Crl Provider (#33786)" (#34713)
This reverts commit 0f0396ae92.
2023-10-17 13:53:36 -07:00
Craig Tiller 975184f04b
[channel-stack] Make ordering explicit (#32852)
Ditch the old priority scheme for ordering filters, instead explicitly
mark up before/after constraints.

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-10-17 13:52:58 -07:00
Gregory Cooke 0f0396ae92
[TLS - Revocation] Crl Provider (#33786)
The basic APIs for the CRL Reloading features.
This adds external types to represent CRL Providers, CRLs, and
CertificateInfo.
Internally we will use `CrlImpl` - this layer is needed to hide OpenSSL
details from the user.

GRFC - https://github.com/grpc/proposal/pull/382

Things Done
* Add external API for `CrlProvider`, `Crl`, `CertInfo` (`CertInfo` is
used during CRL lookup rather than passing the entire certificate).
* Add code paths in `ssl_transport_security` to utilize CRL providers
* Add `StaticCrlProvider`
* Refactor `crl_ssl_transport_security_test.cc` so it is more extensible
and can be used with providers
2023-10-17 13:03:52 -04:00
Sergii Tkachenko 1c4da38d40
[PSM Interop] New cleanup script (#33460)
1. Changes the resource retention period to 2 days for all resources
(previously 7 days for TD resources, 6 hours for k8s). This solved a
problem with k8s resources being stuck because corresponding TD
resources weren't deleted.
2. Resume on namespace cleanup failures
3. Add secondary lb cluster cleanup logic
4. Modularize `grpc_xds_resource_cleanup.sh`
5. Make `KubernetesNamespace`'s methods `pretty_format_status` and
`pretty_format_metadata` public
6. `pretty_format_status`: also print resource kind, creation and
deletion requested dates

ref b/259724370, cl/517235715
2023-10-16 15:44:51 -07:00
Xuan Wang 997c73a6a4
[PSM Interop] Log Google Cloud API debug header part 2 (#34687)
We're seeing too many debug headers, change it to only log header in
case of error.

<!--

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.

-->
2023-10-16 15:17:30 -07:00
Craig Tiller bfb98d89ec
[testing] Add a test of server handling of calls that expired in the request matcher (#34679)
Also expand core_end2end_test suite to allow testing of server
registered methods

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-10-13 13:44:53 -07:00
Craig Tiller 7c59c09f43
[chttp2] Bound write sizes based on observed write performance (#34665)
Instead of fixing a target size for writes, try to adapt it a little to
observed bandwidth.

The initial algorithm tries to get large writes within 100-1000ms
maximum delay - this range probably wants to be tuned, but let's see.

The hope here is that on slow connections we can not back buffer so much
and so when we need to send a ping-ack it's possible without great
delay.
2023-10-12 16:48:55 -07:00
Eugene Ostroukhov 4d61e4d59e
[test] Update gTest (#34629)
gTest added some minor improvements around output since it was last
imported. I suggest we update the version.
2023-10-12 16:47:38 -07:00
Craig Tiller c9df0ca470
[cpp] Reland removal of channel_filter code (#34598)
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-10-12 09:44:11 -07:00
Craig Tiller 0496589405
Revert "[Python run_test] Fix run_test" (#34667)
Reverts grpc/grpc#34292
2023-10-11 17:46:20 -07:00
Yijie Ma bae0c705aa
[Deps] Update to Clang-16 (#34492)
<!--

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.

-->
2023-10-11 16:26:32 -07:00
Xuan Wang 11d9b083f3
[Python run_test] Fix run_test (#34292)
We're not running any test at all from `run_test.py` because of the way
we filter test cases:

1d136fd05f/src/python/grpcio_tests/tests/_runner.py (L137)

* `testcase_filter` is read from a json file (like [this
one](https://github.com/grpc/grpc/blob/master/src/python/grpcio_tests/tests/tests.json))
and test name is similar to `unit._metadata_test.MetadataTest`.
* `case.id()` is loaded by `iterate_suite_cases` and will always have a
prefix of `tests`, an example of case id will be:
`tests.unit._metadata_test.MetadataTest`.

Because of the prefix, none of the test case will be matched thus we're
not running any of the tests.

This PR fixes the prefix issue and all the regressions comes from not
running tests using `run_test.py`.

#### Other Changes
* Added couple of `__init__.py` file since it's required to load tests.
* Added `py_status_code` to Aio rpc state.
* `code()` is expecting to return a python gRPC code but current
`status_code` is a Cython code.
* Added `libsqlite3-dev` to our dockers because it's required for
`coverage==7.2.0`.
* Renamed csds and admin test because test case file have to end with
`_test`:
1d136fd05f/src/python/grpcio_tests/tests/_loader.py (L26)
* Removed gevent test from `run_test.py` because Bazel gevent tests
should be good enough for us.

<!--

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.

-->
2023-10-11 09:50:53 -07:00
Mark D. Roth be1cf357ba
[FuzzingEventEngine] fix TickForDuration() bug and add test (#34633)
The `TickForDuration()` method was using `grpc_core::Timestamp::Now()`
to get the current time, but that was not in sync with the `now_` value
inside the Fuzzing EE itself, with the result that after two subsequent
250ms increments, timers were not being properly fired. I've added a
test that demonstrates this failure without the fix.
2023-10-11 08:25:57 -07:00