Commit Graph

53218 Commits

Author SHA1 Message Date
Sergii Tkachenko 02ceb72fcf
[Release] Add grpc-java 1.56.0 to client_matrix.py (#33433) 2023-06-14 16:38:44 -07:00
Craig Tiller 1bfcca66fe
Revert "[testing] Adjust port selection algorithm on RBE" (#33448)
Reverts grpc/grpc#33429
2023-06-14 14:51:23 -07:00
Mark D. Roth 76919dc699
[xDS] require EDS resource name in CDS resources with xdstp names (#33425)
Implements the change described in
https://github.com/grpc/proposal/pull/377.
2023-06-14 13:53:16 -07:00
Eugene Ostroukhov 6451beba8e
Revert "Revert "Revert "Revert "[xDS LB] Override cluster with value … (#33424)
Previous attempt: #33416

This reverts commit 19460ea82f.
2023-06-14 13:42:59 -07:00
Craig Tiller 6d60d17b47
[experiments] Log constraints when they are used (#33381) 2023-06-14 13:22:56 -07:00
Craig Tiller 95151a3dea
[promises] run finalizers in destruction path (#33434)
Previously we were running these at call termination, but internally we
have things that want to access finalizer cleaned up data after that
point.

<!--

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-06-14 13:22:25 -07:00
Sergii Tkachenko 181a24f546
[PSM Interop] Pip freeze breaks down into requirements and their deps (#33426)
This is a no-op, just reordering `requirements.lock`.

By providing `-r requirements.txt` to `pip freeze` it's able to break up
dependencies required via `requirements.txt`, and sub-dependencies
installed to satisfy them.
2023-06-14 13:15:29 -07:00
suryadev99 6413a31306
[requirements.bazel.txt] :updating wheel package to 0.38.1 to fix the vulnerability input: lang/python, release notes: no (#33338)
[requirements.bazel.txt] :updating wheel package to 0.38.1 to fix the
vulnerability
input: lang/python
release notes: no
settings: release notes:no
updating wheel package to 0.38.1 to fix the vulnerability

![image](https://github.com/grpc/grpc/assets/81183603/67212ab5-e67e-475a-938a-acc23ca4428b)

#python
please do fix it quickly



<!--

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-06-14 13:12:54 -07:00
April Kyle Nassi 48b496793b
[maintainers] Update MAINTAINERS.md (#33441)
adding myself to the maintainers list
2023-06-14 12:39:31 -07:00
Craig Tiller 2055cce132
[fuzzing] Fix bug on endpoint shutdown whereby we leave read requests dangling (#33406)
Fix fuzzer found bug b/286716972

Follows up on https://github.com/grpc/grpc/pull/33266 but gets the edge
case right of when there's a read queued before the peer closes - in
that case we weren't waking up the read.
2023-06-14 12:22:44 -07:00
Craig Tiller 969c228934
[testing] Adjust port selection algorithm on RBE (#33429)
I've got a hypothesis that we're losing isolation between test shards
right now for "some reason".

This is a change to reflect test sharding in the port distribution that
we use, in an attempt to alleviate that.

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-06-14 12:21:59 -07:00
Mark D. Roth f34a39af74
[xDS e2e tests] add 1K RPCs to try to work around statistical problem (#33409) 2023-06-14 10:58:15 -07:00
Craig Tiller 51a6857fa1
[end2end] Shard some longer running tests a little more to reduce timeout risk (#33439)
<!--

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-06-14 09:05:04 -07:00
Craig Tiller 80dbe90c18
Revert "[resource quota] Fix bugs in iomgr and event engine endpoint interactions with resource quota" (#33417)
Reverts grpc/grpc#33375

Breaks import
2023-06-13 08:11:53 -07:00
Craig Tiller 7e6606f5a6
[windows] Add a check for too long path names (#33418)
We should probably cap this so that our customers have a chance of
cloning the repository.

---------

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2023-06-13 07:41:06 -07:00
Craig Tiller 19460ea82f
Revert "Revert "Revert "[xDS LB] Override cluster with value from cookie"" (#33379)" (#33416)
Reverts grpc/grpc#33388

Breaks import
2023-06-13 07:23:46 -07:00
github-actions[bot] e20e7a1198
Automated fix for refs/heads/master (#33415)
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: ctiller <ctiller@users.noreply.github.com>
2023-06-12 20:59:15 -07:00
Craig Tiller dc2b9dbba1
[logging] Peer should be set before common entries are filled in (#33403)
Otherwise when we fill in peer in `SetCommonEntryFields` it will be
empty/invalid.

<!--

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-06-12 17:29:40 -07:00
Vignesh Babu e6c1b13aed
[resource quota] Fix bugs in iomgr and event engine endpoint interactions with resource quota (#33375)
The following bugs are fixed:

* Missing ExecCtx in event engine endpoints and listeners
* Ref counting issue with iomgr endpoint which causes crashes in
overloaded situations

The PR includes a test which triggers these bugs by simulating an
overloaded system.
2023-06-12 16:20:08 -07:00
Eugene Ostroukhov 57bb6fb65c
Revert "Revert "[xDS LB] Override cluster with value from cookie"" (#33388)
Reapplying #32973
2023-06-12 16:12:17 -07:00
Mark D. Roth 6a04e9c7e5
[subchannel interface] add method for cancelling data watches (#33359)
This paves the way for cases where we handle health watches in wrapped
subchannels, which we'll need as part of the dualstack backend design.
2023-06-12 15:28:48 -07:00
Craig Tiller 8e137e524a
[end2end] Reduce likelihood of two tests opening the same UDS socket (#33410) 2023-06-12 15:03:33 -07:00
Florian Ferstl fa32eb36b3
[bazel] Auto-generate .pyi files in py_proto_library rule (#32872)
With some delay, this is a PR for
https://github.com/grpc/grpc/issues/32564 (and previously
https://github.com/grpc/grpc/pull/31791).

I looked into adding a regular `py_test` for this change [as
suggested](https://github.com/grpc/grpc/pull/31791#issuecomment-1423245116)
but I am not aware of any effect that the presence of a .pyi stub file
would have at runtime and where some sort of type-checking in a .py
script would be affected. Stub files are only for use by type checkers &
IDE's. I mean, something like this would work:

```
import helloworld_pb2
py_file = helloworld_pb2.__file__ 
pyi_file = py_file + 'i’
self.assertTrue(os.path.exists(pyi_file))
```

But that seems really hacky to me. Instead I created a simple rule test
for `py_proto_library` with Bazel Skylib which tests the declared
outputs for an example `py_proto_library` target. Indirectly, this also
tests that the declared output files are actually generated. Please let
me know if this is sufficient.
2023-06-12 14:36:24 -07:00
apolcyn 017786f151
[c-ares] Upgrade c-ares dependency to 1.19.1 (#33392)
WIP
2023-06-12 13:38:20 -07:00
Craig Tiller 14c63c70af
[fuzzing] Fix recursive mutex acquisition in fuzzing event engine (#33404)
Fixes internal fuzzing bug b/286717107
2023-06-12 16:31:35 +00:00
Yash Tibrewal 20f1dbcc3f
[Governance] Update maintainers list (#33074)
Maintainers being moved to emeritus status -
* @dapengzhang0
* @medinandres
* @Vizerai
* @yihuazhang
* @ZhenLian

If there are no disagreements, this PR will be merged on May 24, 2023 as
per
https://github.com/grpc/grpc-community/blob/main/governance.md#losing-maintainer-status

<!--

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-06-12 09:27:18 -07:00
Craig Tiller 495bcbcb74
[fuzzing] Increase timeout to accomodate slow internal callbacks (#33407)
Fixes b/286780969
2023-06-12 15:46:30 +00:00
Craig Tiller eba6cecdcb
[fuzzing] Remove ambiguity in test case, make fuzzer pass (#33405)
Here the recv message batch 103 was returning end of stream.

Per the reasoning in
https://github.com/grpc/proposal/blob/master/L104-core-ban-recv-with-send-status.md
Sending status is the final thing for a call on the server, so requiring
a recv message to complete when we've sent status is getting into at
best a gray area in out spec.

Add a strict ordering between that recv and the sending of status to
make a more deterministic test.

fixes b/286708835, b/286727273
2023-06-12 15:02:56 +00:00
Matt Fowles Kulukundis d63c4709d1
[PHP] Fix path munging when package is absent (#33124)
fixes #33114
2023-06-10 21:50:03 -07:00
AJ Heller 74273d0bda
[EventEngine] Correct the TimerList documentation (#33397)
Timers are not run on cancellation.
2023-06-09 17:04:37 -07:00
Sergii Tkachenko 243720e934
[git] Ignore python style LSC #33138 in git blame (#33396)
PR #33138 is the Large Scale Change in which python style is changed
from yapf to black. Nearly all python files were reformatted. This PR
configures git clients supporting `.git-blame-ignore-revs` feature to
show the original author in `git blame`.

Details:
https://black.readthedocs.io/en/stable/guides/introducing_black_to_your_project.html
GitHub uses this feature by default:
https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#ignore-commits-in-the-blame-view
Local git clients can enable this feature with `git config
blame.ignoreRevsFile .git-blame-ignore-revs`.
2023-06-09 17:00:22 -07:00
Esun Kim 076f719286
Revert "Revert "[Test] Dedup vs2019 test in the Windows test" (#33393)" (#33394) 2023-06-09 16:10:29 -07:00
Yash Tibrewal c450a9d4eb
[xds] Fix test compilation (#33373)
Fix #33308
<!--

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-06-09 15:44:27 -07:00
Sergii Tkachenko de6ed9ba9f
[Python] Migrate from yapf to black (#33138)
- Switched  from yapf to black
- Reconfigure isort for black
- Resolve black/pylint idiosyncrasies 

Note: I used `--experimental-string-processing` because black was
producing "implicit string concatenation", similar to what described
here: https://github.com/psf/black/issues/1837. While currently this
feature is experimental, it will be enabled by default:
https://github.com/psf/black/issues/2188. After running black with the
new string processing so that the generated code merges these `"hello" "
world"` strings concatenations, then I removed
`--experimental-string-processing` for stability, and regenerated the
code again.

To the reviewer: don't even try to open "Files Changed" tab 😄 It's
better to review commit-by-commit, and ignore `run black and isort`.
2023-06-09 15:08:55 -07:00
Esun Kim e9e5dc0cf6
Revert "[Test] Dedup vs2019 test in the Windows test" (#33393)
Reverts grpc/grpc#33385

Temporary revert to unblock https://github.com/grpc/grpc/pull/33138
2023-06-09 15:08:20 -07:00
Peter Zhu a4ab4d0033
[Ruby] Fix memory leak in grpc_rb_call_run_batch (#33368)
The function grpc_rb_call_run_batch has many places that could raise
errors, including in child functions. Since a raised error will longjump
out of the function, it will cause memory leaks since the function
cannot perform any clean up. This commit fixes the issue by wrapping the
whole function in an rb_ensure, which will ensure that a cleanup
function is ran before the error is propagated upwards.
2023-06-09 14:30:23 -07:00
Peter Zhu 4fd6dc2066
[Ruby] Fix memory leak in grpc_rb_server_request_call (#33371)
The function grpc_rb_server_request_call has many places that could
raise errors, including in child functions. Since a raised error will
longjump out of the function, it will cause memory leaks since the
function cannot perform any clean up. This commit fixes the issue by
wrapping the whole function in an rb_ensure, which will ensure that a
cleanup function is ran before the error is propagated upwards.
2023-06-09 14:30:05 -07:00
Esun Kim 6b3949593d
[Test] Dedup vs2019 test in the Windows test (#33385)
`cmake_ninja_vs2019` and `default` are using the same
`cmake_ninja_vs2019` so having two tests are waste so this is removing
`cmake_ninja_vs2019` leaving `default` which does `cmake_ninja_vs2019`.

This change can cut the space consumption by half and with 250GB disc, 

- Pre-test: 267,770,322,944 bytes free 
- Post-test: 134,499,295,232 bytes free
2023-06-09 13:52:58 -07:00
Craig Tiller a63849bd39
[ios] damage control (#33391)
~Something about the additional load from #33374 has caused some
entirely unrelated ios tests to fail sporadically. I'd prefer not to
roll back that however as it's discovered real bugs that had been
previously masked.~

These tests have been failing sporadically for some time.

We can track these on the daily flakiness reports, but whilst we
investigate let's just universally mark them as flaky so we don't
confuse folks trying to submit.
2023-06-09 12:37:34 -07:00
AJ Heller f974491065
[EventEngine] Return work stealing experiment to CI-only (#33389)
There is potential for a long shutdown process under load (seconds
instead of milliseconds).
2023-06-09 12:37:20 -07:00
Craig Tiller 82534bab24
[end2end] Shard some longer running tests a little more to reduce timeout risk (#33387)
Also drop a few deadlines so that tests can run faster (where that's
safe)


<!--

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-06-09 12:17:29 -07:00
Sergii Tkachenko a95e8c4ff4
[PSM Interop] Improve assertRpcStatusCodes before/after stats logging (#33360)
Do not clutter the final error we see at the end with the before/after
stats.

#### Examples

###### Expected only status A, but found status B for method M:

```
[  FAILED  ] CustomLbTest.test_custom_lb_config
======================================================================
FAIL: test_custom_lb_config (__main__.CustomLbTest)
CustomLbTest.test_custom_lb_config
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/sergiitk/Development/grpc/tools/run_tests/xds_k8s_test_driver/tests/custom_lb_test.py", line 113, in test_custom_lb_config
    self.assertRpcStatusCodes(test_client,
  File "/Users/sergiitk/Development/grpc/tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_testcase.py", line 345, in assertRpcStatusCodes
    found_status = helpers_grpc.status_from_int(found_status_int)
AssertionError: Expected only status (15, DATA_LOSS), but found status (0, OK) for method UNARY_CALL.
Diff stats:
- method: UNARY_CALL
  rpcs_started: 251
  result:
    (0, OK): 251
```

###### Expected non-zero RPCs with status A for method M.
```
[  FAILED  ] AuthzTest.test_plaintext_allow
======================================================================
FAIL: test_plaintext_allow (__main__.AuthzTest)
AuthzTest.test_plaintext_allow
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/sergiitk/Development/grpc/tools/run_tests/xds_k8s_test_driver/tests/authz_test.py", line 224, in test_plaintext_allow
    self.configure_and_assert(test_client, 'host-wildcard',
  File "/Users/sergiitk/Development/grpc/tools/run_tests/xds_k8s_test_driver/tests/authz_test.py", line 204, in configure_and_assert
    self.assertRpcStatusCodes(test_client,
  File "/Users/sergiitk/Development/grpc/tools/run_tests/xds_k8s_test_driver/framework/xds_k8s_testcase.py", line 355, in assertRpcStatusCodes
    self.assertGreater(stats.result[expected_status_int],
AssertionError: 0 not greater than 0 : Expected non-zero completed RPCs with status (0, OK) for method EMPTY_CALL.
Diff stats:
- method: EMPTY_CALL
  rpcs_started: 13
  result: {}
```
2023-06-08 22:27:13 -07:00
Eugene Ostroukhov 6f685274a1
Revert "[xDS LB] Override cluster with value from cookie (#32973)" (#33379)
This reverts #32973 that causes breakages in internal CI.
2023-06-08 16:50:47 -07:00
Craig Tiller d8f3dab96c
[end2end] Binary & fuzzer per test .cc (#33374)
<!--

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-06-08 15:38:53 -07:00
Eugene Ostroukhov 8fe3472e53
[xDS LB] Override cluster with value from cookie (#32973) 2023-06-08 13:52:13 -07:00
Yousuk Seung c03cd744b2
[WRR] Prefer application_utilization to cpu_utilization (#33355)
<!--

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-06-07 17:38:29 -07:00
Yadong 18c42a21af
[core] Add support for vsock transport (#33309)
Revert "Revert "[core] Add support for vsock transport"
(https://github.com/grpc/grpc/pull/33276)"
This reverts commit
c5ade3011a.

And fix the issue which broke the python build.

@markdroth @drfloob please review this PR. Thank you very much.

---------

Co-authored-by: AJ Heller <hork@google.com>
2023-06-07 13:55:53 -07:00
Xuan Wang d00e043982
[Python o11y] Fix python distribtests (#33365)
Fix for Cython build issue in aarch64.

We're seeing this error in aarch64 distribution test:
```
In file included from ./src/core/lib/slice/slice.h:36,
                 from ./src/core/lib/slice/slice_buffer.h:29,
                 from ./src/core/lib/transport/transport.h:60,
                 from ./src/core/lib/channel/channel_stack.h:75,
                 from ./src/core/lib/channel/call_tracer.h:32,
                 from src/python/grpcio/grpc/_cython/cygrpc.cpp:2230:
./src/core/lib/slice/slice_refcount.h: In member function 'void grpc_slice_refcount::Ref(grpc_core::DebugLocation)':
./src/core/lib/slice/slice_refcount.h:55:25: error: expected ')' before 'PRIdPTR'
               "REF %p %" PRIdPTR "->%" PRIdPTR, this, prev_refs, prev_refs + 1);
                         ^~~~~~~~
                         )
```

Based on [this
post](https://stackoverflow.com/questions/26182336/priuptr-preprocessor-bug-in-gcc),
it's caused by including `<inttypes.h>` before define
`__STDC_FORMAT_MACROS` marco.

`<inttypes.h>` was included in `core/lib/channel/call_tracer.h` and this
macro should already be defined in `grpc/grpc.h` through
`port_platform.h`, but we're still having issue in aarch64, so we
manually define the macro in this PR.
2023-06-07 12:46:15 -07:00
Craig Tiller a90239f381
[logging] fix spelling (#33362) 2023-06-06 23:18:09 -07:00
AJ Heller 28692fdcae
[EventEngine] Enable work stealing thread pool in debug builds (#33333) 2023-06-06 15:50:31 -07:00