Commit Graph

112 Commits

Author SHA1 Message Date
Jan Tattermusch eae3082829
[RBE windows] Use bazel 6.3.2 on windows RBE (after regenerating toolchain) (#34216)
- Upgrade windows RBE builds to bazel 6.3.2 (supersedes
https://github.com/grpc/grpc/pull/33880). To be able to do that, the RBE
toolchain needed to be regenerated and
- Also added "--dynamic_mode=off" option for windows build since it
seemed necessary for bazel 6.x builds to pass.
- Wrote instructions for generating windows RBE toolchain using the
`rbe_configs_gen` tool (the original windows RBE toolchain was out of
data and also it was generated by a custom script from
go/rbe-windows-user-guide - using a standard tool is better)
- Wrote instructions for rebuilding the windows RBE docker image.

This addresses the problem where windows RBE is stuck on bazel 5.x
(unlike the rest of the repository) and also documents the steps for
making changes to the RBE docker image (e.g. upgrading the visual studio
version used by RBE).

Since we were planning on adding testing for VS2022 (for which we don't
have any test ATM), this will definitely come handy. With the
documentation the process should now be relatively straightforward.
2023-09-01 10:35:15 +02:00
Esun Kim 1a1124903c
[Deps] Upgrade Protobuf and Upb to 24.x (#34123)
On top of https://github.com/grpc/grpc/pull/34120
2023-08-29 10:58:48 -07:00
Jan Tattermusch 5d405b2314
[bazel RBE] add direct link to Fusion UI in bazel rbe invocations (#34101)
Currently the bazel invocations provide a link back to the original
kokoro jobs for resultstore and sponge UIs.
This adds another back link to Fusion UI, which has the advantage of 
- being able to navigate to the kokoro job overview
- there is a button to trigger a new build (in case the job needs to be
re-run).


![image](https://github.com/grpc/grpc/assets/9939684/42f0bbc2-14f5-45db-89f7-73e48e32e7c9)
2023-08-21 09:33:20 +02:00
Jan Tattermusch 2b0a9d3916
[bazel] Teach bazel how to run non-bazel test suites under docker locally and on RBE (#33707)
Add "bazelified" non-bazel tests. See tools/bazelify_tests/README.md for
the core idea.
- add a bunch of test targets that run under docker and execute tests
that correspond to `run_tests.py -l LANG ...`
- many more tests can be added in the future
- to enable running some of the C/C++ portability tests easily, added
support for `--cmake_extra_configure_args` in run_tests.py (the change
is fairly small).

Example passing build that shows how test results are structured:

https://source.cloud.google.com/results/invocations/21295351-a3e3-4be1-b6e9-aaf52195a044/targets
2023-08-02 14:15:19 +02:00
Vignesh Babu f85b7c79ee
[experiments] Fix processing of platform specific test tags (#33749)
Also adds a unit test: experiments_tag_test which should fail if the
appropriate tags are not set for it.
2023-07-21 16:06:01 -07:00
Jan Tattermusch 19414da96d
[bazel rbe] RBE config: update names of some deprecated bazel option flags (#33759)
just a bit of cleanup
2023-07-21 16:28:04 +02:00
Jan Tattermusch 30b3d5061a
[test-infra] Switch RBE linux build to a new custom image rbe_ubuntu2004. (#32748)
- Add a new docker image "rbe_ubuntu2004" that is built in a way that's
analogous to how our other testing docker images are built (this gives
us control over what exactly is contained in the docker image and
ability to fine-tune our RBE configuration)
- Switch RBE on linux to the new image (which gives us ubuntu20.04-based
builds)

For some reason, RBE seems to have trouble pulling the docker image from
Google Artifact Registry (GAR), which is where our public testing images
normally live, so for now, I used a workaround and I upload a copy of
the rbe_ubuntu2004 docker image to GCR as well, and that makes RBE works
just fine (see comment in the `renerate_linux_rbe_configs.sh` script).

More followup items (config cleanup, getting local sanitizer builds
working etc.) are in go/grpc-rbe-tech-debt-2023
2023-05-01 11:47:27 -07:00
Jan Tattermusch 5fb25fdfe6
Revert "Invalidate RBE linux cache by setting a new cache silo key" (#32793)
Reverts grpc/grpc#32706

Looks like this isn't helping at all with the original issue.
2023-04-13 16:29:20 +02:00
Jan Tattermusch 4ef9844750
Invalidate RBE linux cache by setting a new cache silo key (#32706)
An attempt to fix b/275035917 (but I have no idea if this helps or not).
2023-03-24 17:35:26 +01:00
Jan Tattermusch a27b86fb95
Switch linux RBE to ubuntu18.04, get rid of rbe_autoconfig (#32559)
First step in the modernization of our RBE stack (see
go/rbe-tech-debt-notes).

- Get rid of the deprecated rbe_autoconfig and start using
[rbe_configs_gen](https://github.com/bazelbuild/bazel-toolchains#rbe_configs_gen---cli-tool-to-generate-configs)
+ check in the generated toolchain configs.
- Switch from marketplace.gcr.io/google/rbe-ubuntu16-04 to
marketplace.gcr.io/google/rbe-ubuntu18-04 (this image is still not owned
by us, but at least it's newer and demonstrates how a switch to a newer
docker image is done).
- provide script for generating the linux RBE toolchain configs.
- cleanup RBE configuration in the bazelrc files used for remote build
2023-03-10 09:34:53 +01:00
Yijie Ma b9d566fac5
Update tools/remote_build/README.md (#31727)
* Update tools/remote_build/README.md

* fix
2022-11-22 13:16:20 -08:00
Craig Tiller bc5db5395a
[experiments] Allow specifying experiments defaults to be different for debug/release builds (#30895)
* cpp-codegen

* bazel-gen

* Automated change: Fix sanity tests

* Update grpc_build_system.bzl

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2022-09-08 13:44:55 -07:00
Jan Tattermusch 99a7f2995e
Update win RBE docker image to VS2019 (#30072)
* update win RBE docker image and toolchain

and switch win RBE builds to using it.

* delete legacy RBE windows toolchain config

* switching to VS2019 makes #28544 obsolete
2022-06-28 10:23:12 +02:00
Jan Tattermusch c64d6f3f57
Better bazel C++ iOS tests (with structured test results) (#29354)
* introduce bazelrc for tests with resultstore-uploaded results

* modernize bazel cpp ios tests

* simplify bazel invocation in bazel_cpp_ios_tests

* remove unused bazel core ios tests
2022-04-12 13:16:48 +02:00
Jan Tattermusch 1973b4f9b1
Cleanup bazel RBE configs (#29281)
* refactor RBE configs

* better naming for linux specific RBE configs

* update names of RBE configs elsewhere

* move partial configs to tools/remote_build/include
2022-04-04 09:47:43 +02:00
Jan Tattermusch f40fe16aab
enable bazel remote cache for macos C/C++ CI tests (#29272) 2022-04-01 18:29:43 +02:00
Esun Kim f1e79853ed
Revert "Revert "Buildify Envoy upb (#28558)" (#28648)" (#28649)
This reverts commit 01011ab259.
2022-01-25 11:19:41 -08:00
Esun Kim 01011ab259
Revert "Buildify Envoy upb (#28558)" (#28648)
This reverts commit 97584d8346.
2022-01-21 08:35:13 -08:00
Esun Kim 97584d8346
Buildify Envoy upb (#28558)
* Buildigy xds

* Generate project

* Buildify envoy

* Added new upb files

* Removed unused upb targets

* Fix grpc_cel_engine

* Update envoy-api to the latest

* Regen upb

* Regen projects

* Fix bazel build on MacOS

* More fix on bazel mac

* Disable grpc_tool_test on Mac

* Regen projects
2022-01-20 22:29:58 -08:00
Esun Kim c6f96d687f
Re-enabling RBE ubsan (#27861)
* Cherry-pick #27439

* Fix StatusGetTime misalignment

* Fix memcpy with nullptr

* Fix boringssl ubsan issue

* Fix slice ubsan issue

* Ignore msan errors for ubsan

* Add upb UBSAN exception

* Add local ubsan run comment

* Revert "Fix StatusGetTime misalignment"

This reverts commit a1d0c34e8ea6933d09386867e8d4836d9e1b4e1c.

* Fix status_helper

* Added alignas

* Fix fuzzer_corpus_test

* Removed binder_transport_test from ubsan
2021-12-16 17:33:24 -08:00
Jan Tattermusch 0042c2b86f
Upgrade bazel to 4.2.1 (LTS), upgrade bazel toolchain to 4.1.0 (#27410)
* update bazel to 4.2.1

* add bazel 4.2.1 to update_mirror.sh

* regenerate dockerfiles

* upgrade bazel toolchains to 4.1.0

* use create_rbe_exec_properties_dict instead of the deprecated create_exec_properties_dict

* RBE ubsan doesnt require the crosstool_top hack anymore

* update rules_apple and build_bazel_apple_support
2021-09-23 16:20:25 +02:00
Esun Kim 470c0472c2 Add use_strict_warning=true for mac-os bazel rbe build 2021-02-09 09:06:32 -08:00
Jan Tattermusch cdb3d823fd migrate windows RBE to win2019 pool 2020-05-13 14:39:59 +02:00
Jan Tattermusch 30e078f122
Improve bazel RBE documentation 2020-04-01 10:11:26 +02:00
Jan Tattermusch 94354b2b26 get rid of the long deprecated --incompatible_windows_native_test_wrapper flag 2020-03-23 16:21:18 +01:00
Jan Tattermusch f8d90ef897 port server must be used for mac bazel tests 2020-03-19 18:29:20 +01:00
Vijay Pai 0c0f3f0556 Declare microbenchmarks as tests rather than binaries, fix issues 2020-02-13 09:34:15 -08:00
Donna Dionne bf3ea2e3a5 Adding GRPC_PORT_ISOLATED_RUNTIME=1 to mac.bazelrc.
Since remote builds do not use port server, GRPC_PORT_ISOLATED_RUNTIME
is needed and it is missing from mac.bazelrc.

Before this fix
tools/bazel --bazelrc=tools/remote_build/mac.bazelrc test --config=opt test/cpp/end2end/...
failed with errors like
D0117 00:38:28.961089757      16 port_server_client.cc:139]  failed port pick from server: retrying

After this fix
build and test succeeded
2020-01-16 16:52:52 -08:00
Jan Tattermusch aa40b1c8b8
Merge pull request #20510 from jtattermusch/bazel_test_on_mac
Start running bazel C/C++ tests on mac
2019-11-27 12:09:43 +01:00
Jan Tattermusch 674b1f6f52 use more reasonable timeouts for sanitizer tests 2019-11-26 13:03:40 -05:00
Jan Tattermusch 7e6defd394 use default test timeouts for RBE opt and dbg tests 2019-11-26 13:03:40 -05:00
Jan Tattermusch 5bb72e0a47 introduce mac.bazelrc 2019-11-25 13:35:26 +01:00
Jan Tattermusch 8bf200752f avoid occasional timeout uploading RBE results 2019-11-15 03:02:37 -05:00
Eytan Kidron c97ce9057b Simplify the platform and constraints settings for remote execution
* Remove the toolchains //third_party/toolchains:local and //third_party/toolchains:local_large.
* Remove the platforms :rbe_ubuntu1604, :rbe_ubuntu1604_large, :local and :local_large.
* No longer inherit from @rbe_default//config:platform but instead use it directly. It is now the only non-windows platform.
* When creating @rbe_default//config:platform directly with rbe_autoconfig, set dockerAddCapabilities and dockerPrivileged directly in the exec_properties field. No need to set dockerNetwork to "off" and dockerSiblingContainers to false since these are the defaults.
* Also set gceMachineType = "n1-highmem-2" on the default platform. This value can be overridden by specific targets that want to use LARGE_MACHINE.
* Use create_exec_properties_dict where appropriate.
* Use custom_exec_properties to define LARGE_MACHINE.

I wasn't able to test thoroughly that this PR does not break any existing targets. I was not able to run anything on windows/mac and I also don't have access to gRPC's RBE setup.
2019-10-29 15:40:28 -04:00
Jan Tattermusch e5e3f70a1a Revert "Revert "Upgrade to bazel 1.0.0"" 2019-10-29 06:31:38 -04:00
Jan Tattermusch dddcb8dbd8 set high --remote_timeout
This reverts commit 65b184d30a.
2019-10-24 09:40:10 +02:00
Jan Tattermusch 65b184d30a no need to set --remote_timeout 2019-10-23 12:55:02 +02:00
Jan Tattermusch 4ecfab1488 increase remote_timeout to avoid "Unevaluated target" problems 2019-10-23 11:44:49 +02:00
Nicolas Noble 04d7e0d11f
Revert "Upgrade to bazel 1.0.0" 2019-10-15 14:26:32 -07:00
Jan Tattermusch 17529437b7 upgrade ubsan RBE toolchain 2019-10-14 12:11:29 -04:00
Jan Tattermusch d10fb3ba99 fix win RBE opt build 2019-10-07 07:55:44 -04:00
Jan Tattermusch 2262e2b8e8 add extra kokoro build info to Win RBE runs 2019-10-04 11:38:30 +02:00
Jan Tattermusch 6a8cf38137 use more parallel jobs workers for windows RBE 2019-10-02 08:19:04 -04:00
Jan Tattermusch f81ef767d3 filter out non-linux tests 2019-09-30 18:05:40 +02:00
Jan Tattermusch 1ba59b879e update windows RBE instructions 2019-09-30 13:28:00 +02:00
Jan Tattermusch c6f18ce6c5 make Win RBE test pass 2019-09-30 13:27:59 +02:00
Jan Tattermusch 84f555bfd8 simplify and unify manual builds 2019-09-16 16:31:21 +02:00
Jan Tattermusch e14212b9a5 fix windows RBE manual build instructions 2019-09-16 15:35:20 +02:00
Jan Tattermusch 5cd37064cb try fix win RBE build 2019-09-10 12:08:12 -04:00
Jan Tattermusch 4e8ecb9fe6
Revert "Upgrade to Bazel 0.29 (including Windows RBE)" 2019-09-06 12:31:45 +02:00