Merged
Conversation
Signed-off-by: Rafal Augustyniak <raugustyniak@lyft.com>
This fixes #9784 and re-enables vhds_integration_test Risk Level: Low, but will most likely increase memory usage Signed-off-by: Dmitri Dolguikh <ddolguik@redhat.com>
Signed-off-by: Rafal Augustyniak <raugustyniak@lyft.com>
Signed-off-by: Michael Rebello <me@michaelrebello.com> Co-authored-by: Jose Nino <jnino@lyft.com>
After #11670, the CSRF filter started failing for us. This change fixes 3 issues that were uncovered after moving to gURL for parsing URLs: 1) the hostAndPort() utility method, in the CSRF filter, was returning a string view of a stack variable. 2) the Origin header always includes the scheme, so let's ensure this is illustrated in tests (which were missing this and passing due to relaxed checks). 3) the Url::initialize method expects an absolute URL, something that the CSRF filter wasn't complying with. Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
The existing cast-to-void*-then-back method for passing in a context is type-unsafe and can make for hard-to-locate errors. By using a std::function instead of a function pointer, the caller can get compilation error instead of runtime errors, and doesn't have to do any sort of bundling dance with std::pair or a custom struct to pass multiple context items in. Signed-off-by: Alex Konradi <akonradi@google.com>
Add bootstrap config option that allows startup injection of a custom SocketInterface. Risk Level: Low Testing: n/a Docs Changes: n/a Release Notes: n/a Signed-off-by: Florin Coras <fcoras@cisco.com>
…#11831) Currently Opencensus tracer uses grpcService proto to configure its tracing client stub. It uses GoogleGrpcUtil to construct a channel and create client stub with that. However, the channel created there does not take care of initial_metadata from grpcService configure. This change fills in OCprepare_client_context option in export to make it respect initial metadata. Risk level: Low Signed-off-by: Pengyuan Bian <bianpengyuan@google.com>
Pulling out version to a separate package Risk Level: Low Signed-off-by: Lizan Zhou <lizan@tetrate.io>
#12129 (review), to ensure the consistency between api/bazel/*.bzl and generated_api_shadow/bazel/*.bzl Risk Level: Low Signed-off-by: Shikugawa <rei@tetrate.io>
…Test suite (#12143) Remove unit test parameterization for the TapMatcherGenericBodyConfigTest suite. It does not actually use test parameters. Risk Level: Low, test only Testing: Unit Tests Docs Changes: N/A Release Notes: N/A Signed-off-by: Yan Avlasov <yavlasov@google.com>
Commit Message: format: use type alias Additional Description: N/A Risk Level: Low Testing: N/A Docs Changes: N/A Release Notes: N/A Part of #11634 Signed-off-by: tomocy <tomocy.dev@gmail.com>
Signed-off-by: Benjamin Peterson <benjamin@python.org>
Signed-off-by: tomocy <tomocy.dev@gmail.com>
This just introduces plumbing and clones codecs for a legacy versions. There is no changes to the codecs at this point (the files are just duplicated and the namespace Legacy is used). Users can set which codecs are used at runtime via the feature new_codec_behavior. This will be the case for O(4-6 weeks) while the change to new no-exception codecs are pushed (see issue linked) to the new codecs. Signed-off-by: Asra Ali <asraa@google.com>
This PR implements fault injection for Redis; specifically delay and error faults (which themselves can have delays added). I chose not to implement a separate filter after discussing with Henry; we concluded that the faults we felt were useful didn't need many levels- just a delay on top of the original fault, if any. In addition, as the Redis protocol doesn't support headers that makes it a bit different again from Envoy's http fault injection. Signed-off-by: FAYiEKcbD0XFqF2QK2E4viAHg8rMm2VbjYKdjTg <nflacco@lyft.com>
Commit Message: changes for http and access_log folders Risk Level:NA Testing: Unit and format testing Docs Changes: NA part of #10843 Signed-off-by: Abhay Narayan Katare <abhay.katare@india.nec.com>
test: fix typos and make cleanups in router tests Risk Level: low Testing: bazel test //test/... Docs Changes: n/a Release Notes: n/a Signed-off-by: Martin Matusiak <numerodix@gmail.com>
Commit Message: Add `bazel.fuzz_coverage` to CI. Publishes fuzz coverage report in `coverage_publish` Risk Level: Medium Testing: Local testing of `./ci/run_envoy_docker.sh './ci/do_ci.sh bazel.fuzz_coverage'`, as well as `FUZZ_COVERAGE=true test/run_envoy_bazel_coverage.sh` with single test args/directory, VALIDATE on/off. Fixes: #9573 Docs: Updated bazel/README.md and fuzz/README.md for docs about running local coverage. Signed-off-by: Asra Ali <asraa@google.com>
Signed-off-by: Rama Chavali <rama.rao@salesforce.com>
Signed-off-by: Rama Chavali <rama.rao@salesforce.com>
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Moved generic listener filter fuzzer into common/fuzz for consistency with other (network, http) filter fuzzers. Updated dependencies in related files Signed-off-by: Arthur Yan <arthuryan@google.com>
Note that Bazel's toolchain for 3.4.1 is tagged 3.4.0: https://github.com/bazelbuild/bazel-toolchains/releases/tag/3.4.0. Depends on envoyproxy/envoy-build-tools#85. Signed-off-by: Michael Rebello me@michaelrebello.com Risk Level: Medium Testing: CI Docs Changes: N/A Release Notes: N/A Signed-off-by: Michael Rebello <me@michaelrebello.com>
* fix filter fuzzer crash from OSS fuzz by checking for non-implemented proto fields This will raise an exception that will be caught and abort the test run when an unimplemented oneof field is hit by the fuzzer Signed-off-by: Sam Flattery <samflattery@google.com>
Commit Message: format: use type alias Additional Description: N/A Risk Level: N/A Testing: N/A Docs Changes: N/A Release Notes: N/A Part of #11634 Signed-off-by: tomocy <tomocy.dev@gmail.com>
Risk Level: High (roll back first, ask questions later) Testing: cloned all unit tests and all integration tests. Docs Changes: n/a Release Notes: inline Runtime guard: envoy.reloadable_features.new_tcp_connection_pool Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
Signed-off-by: Nick Grifka <nigri@microsoft.com>
As you know that the envoy build system has a functionality that can choose some tests to do test manually. But now, to do that, I need to add a dummy argument when I execute the do_ci.sh like as following: /ci/run_envoy_docker.sh "./ci/do_ci.sh bazel.dev '' //test/common/network:udp_listener_impl_test". So, this patch fixes that selective testing works like as previous behavior. Signed-off-by: DongRyeol Cha <dr83.cha@samsung.com>
Commit Message: Remove warming listeners in xDS SOTW updates Additional Description: - my xDS fuzzer timed out on OSS fuzz here because Envoy does not remove warming listeners when they are left out of a SOTW update like it removes active ones - changes LdsApiImpl::onConfigUpdate to use a new function in ListenerManagerImpl, allListeners() instead of the old listeners() which just returns active listeners to compute the diff between the update and the current SOTW - changed lds_api_test.cc to use this new function Signed-off-by: Sam Flattery <samflattery@google.com>
Commit Message: Remove all throw statements from H/1 codec This change removed all uses of C++ exceptions from H/1 codec. I modeled the flow after Yan's H/2 work (#11575). Codec status are set in uniform helper methods. This is the only change from the previous PR (#11101), besides merging newer exceptions. This change replaces all throw statements with a return of corresponding error Status and adds plumbing to return the status to codec callers. The dispatch() method returns the encountered error to the caller, which will be handled accordingly. The calls to the RequestEncoder::encodeHeaders() NOT called from dispatch() method will RELEASE_ASSERT if an error code is returned. This does not alter the existing behavior of abnormally terminating the process, just the method of termination: RELEASE_ASSERT vs uncaught exception. Risk Level: High (Codec changes) Signed-off-by: Asra Ali <asraa@google.com>
Signed-off-by: Martin Matusiak <numerodix@gmail.com> Commit Message: cleanup: remove unused forward declaration Risk Level: Low Testing: bazel test //test/... Docs Changes: none Release Notes: n/a
Signed-off-by: Lizan Zhou <lizan@tetrate.io> Prevents undefined behavior and let clang-tidy not warn about it.
Add a method to Envoy::Buffer::Instance that may be used to extract the front slice of the implementation's queue (SliceDeque in the case of Buffer::OwnedImpl) without copying the actual payload. A SliceData class is defined to facilitate the extraction process. Signed-off-by: Roelof DuToit <roelof.dutoit@broadcom.com>
) quic::ProofSource:: ComputeTlsSignature() can be called by either ProofSource::GetProof() or directly from QUICHE stack. When it's called from GetProof() the private key is verified while deducing signature algorithm in GetProof(). But when it is called from QUICHE TLS handshake stack directly, we currently don't check the private key used. Fixes #9434 Part of #2557 Signed-off-by: Dan Zhang <danzh@google.com>
* Unset metadata matcher causes crash, since no matcher is set * `encodeHeaders` in HCM requires that the only 1xx header is a 101 upgrade * stream info destructor issue -- this one no longer reproduces Fixes: https://oss-fuzz.com/testcase?key=4863844862918656 https://oss-fuzz.com/testcase-detail/5656400764862464 https://oss-fuzz.com/testcase-detail/5631179290836992 Signed-off-by: Asra Ali <asraa@google.com>
Commit Message: Added fuzz test for listener filter Additional Description: Extended generic listener filter fuzzer library to support mocked dispatcher and system call behavior Created http_inspector_corpus and populated with testcases (valid and invalid headers) Created http_inspector_fuzz_test.cc and updated ListenerFilterFuzzer API Signed-off-by: Arthur Yan <arthuryan@google.com>
Signed-off-by: William A Rowe Jr <wrowe@vmware.com> Co-authored-by: Sunjay Bhatia <sunjayb@vmware.com>
* added generic freamework for testing filters. Signed-off-by: jianwen <jianwendong@google.com> * added code for covering ext_authz filter Signed-off-by: jianwen <jianwendong@google.com> * restore the log output in ext_authz implementation. Signed-off-by: jianwen <jianwendong@google.com> * fixed style problem Signed-off-by: jianwen <jianwendong@google.com> * fixed style problem Signed-off-by: jianwen <jianwendong@google.com> * added comments Signed-off-by: jianwen <jianwendong@google.com> * added ststem time control for local_rate_limit Signed-off-by: jianwen <jianwendong@google.com> * enabled three filters coverage Signed-off-by: jianwen <jianwendong@google.com> * added support for ext_authz response Signed-off-by: jianwen <jianwendong@google.com> * added coverage for tcp_proxy and client_ssl_auth. Increased the coverage for ext_auth by enabling the mocked response. Fixed the validation problem inside client_ssl_auth's protobuf Signed-off-by: jianwen <jianwendong@google.com> * removed test for tcp_proxy filter Signed-off-by: jianwen <jianwendong@google.com> * fix bazel style Signed-off-by: jianwen <jianwendong@google.com> * fixed style Signed-off-by: jianwen <jianwendong@google.com> * found issues in tcp_proxy and direct_response. added test cases for the issues Signed-off-by: jianwen <jianwendong@google.com> * replace raw string names with names from factory Signed-off-by: jianwen <jianwendong@google.com> * added test cases for direct response and sni_cluster Signed-off-by: jianwen <jianwendong@google.com> * cleaned the code Signed-off-by: jianwen <jianwendong@google.com> * deleted some useless comments Signed-off-by: jianwen <jianwendong@google.com> * removed filters with known issues from the fuzzer Signed-off-by: jianwen <jianwendong@google.com> * removed unnecessary corpus Signed-off-by: jianwen <jianwendong@google.com> * fix the style Signed-off-by: jianwen <jianwendong@google.com> * removed unsupported test cases Signed-off-by: jianwen <jianwendong@google.com> * removed unnecessary comments Signed-off-by: jianwen <jianwendong@google.com> * removed the empty destructor of fakeFactoryContext Signed-off-by: jianwen <jianwendong@google.com> * fixed naming problems and removed the constructor of fake class Signed-off-by: jianwen <jianwendong@google.com> * start working on http_connection_manager and solved one potential use-after-free problem. Signed-off-by: jianwen <jianwendong@google.com> * fixed style problems Signed-off-by: jianwen <jianwendong@google.com> * modified ON_CALL to EXPECT_CALL.WillOnce for some unique_ptr. Removed ON_CALL for addr_, instead, directly change the pointer inside connection_ Signed-off-by: jianwen <jianwendong@google.com> * run fix code style Signed-off-by: jianwen <jianwendong@google.com> * added HCM filter and SDFP filter Signed-off-by: jianwen <jianwendong@google.com> * fixed typos and added TODOs Signed-off-by: jianwen <jianwendong@google.com> * fixed a typo Signed-off-by: jianwen <jianwendong@google.com> * separate the fake class definition and the per_filter processing in different files. Cleaned up the deps Signed-off-by: jianwen <jianwendong@google.com> * added comments and assert() Signed-off-by: jianwen <jianwendong@google.com> * fix style Signed-off-by: jianwen <jianwendong@google.com> * fixed the proto definition on ThriftProxy.Route.RouteAction.cluter_header. Signed-off-by: jianwen <jianwendong@google.com> * run proto fix after modification in route.proto Signed-off-by: jianwen <jianwendong@google.com> * added comment on seconds_in_one_day_ Signed-off-by: jianwen <jianwendong@google.com> * added test cases Signed-off-by: jianwen <jianwendong@google.com> * trying to add valid filters Signed-off-by: jianwen <jianwendong@google.com> * added test case for thrift proxy and added deps Signed-off-by: jianwen <jianwendong@google.com> * added comment and log Signed-off-by: jianwen <jianwendong@google.com> * refined the test cases Signed-off-by: jianwen <jianwendong@google.com> * added dict Signed-off-by: jianwen <jianwendong@google.com> * added dict to BUILD Signed-off-by: jianwen <jianwendong@google.com> * added support for rocketmq_proxy Signed-off-by: jianwen <jianwendong@google.com> * refined test cases for kafka and rocketmq Signed-off-by: jianwen <jianwendong@google.com> * added support for RateLimit and a test case for it. Signed-off-by: jianwen <jianwendong@google.com> * renamed the filter fuzzer to readfilter fuzzer Signed-off-by: jianwen <jianwendong@google.com> * fixed code style Signed-off-by: jianwen <jianwendong@google.com> * merged generic fuzzer(rename) Signed-off-by: jianwen <jianwendong@google.com> * added rbac Signed-off-by: jianwen <jianwendong@google.com> * fix nits Signed-off-by: jianwen <jianwendong@google.com> * fixed style Signed-off-by: jianwen <jianwendong@google.com> * fix style Signed-off-by: jianwen <jianwendong@google.com> * removed several test cases Signed-off-by: jianwen <jianwendong@google.com> * removed several test cases Signed-off-by: jianwen <jianwendong@google.com> * adde comments Signed-off-by: jianwen <jianwendong@google.com> * added writefilter fuzzer and a crash testcase for zookeeperproxy Signed-off-by: jianwen <jianwendong@google.com> * covered all the filters Signed-off-by: jianwen <jianwendong@google.com> * added a comment for postgres_proxy Signed-off-by: jianwen <jianwendong@google.com> * fixed style Signed-off-by: jianwen <jianwendong@google.com> * fixed TODO name Signed-off-by: jianwen <jianwendong@google.com> * removed unrelevant changes Signed-off-by: jianwen <jianwendong@google.com> * fixed proto Signed-off-by: jianwen <jianwendong@google.com> * restore the changes Signed-off-by: jianwen <jianwendong@google.com> * trying to add coverage for mongodb Signed-off-by: jianwen <jianwendong@google.com> * fixed style and removed cout Signed-off-by: jianwen <jianwendong@google.com> * added time source Signed-off-by: jianwen <jianwendong@google.com> * added a test case for mongo, fixed style problem Signed-off-by: jianwen <jianwendong@google.com> * fixed a spelling problem Signed-off-by: jianwen <jianwendong@google.com> * removed the test case for postgres_proxy Signed-off-by: jianwen <jianwendong@google.com> * added new lines and made the comment clearer Signed-off-by: jianwen <jianwendong@google.com> * fixed a spelling problem Signed-off-by: jianwen <jianwendong@google.com> * removed a hardcoded debug code, used debug log in writefilter fuzzer. Signed-off-by: jianwen <jianwendong@google.com> * removed unnecessary BUILD deps. Signed-off-by: jianwen <jianwendong@google.com>
This is the second PR to this #12354. This time is in the common/config submodule. Signed-off-by: Yifan Yang <needyyang@google.com>
…dress (#12573) Compared to their superclasses, the MockIp and MockResolvedAddress classes dropp the const qualifier from the pointers they return. Since the non-mock class implementing these methods return const pointers, it’s difficult to use non-mock classes with these mocks without resorting to hacks like const_cast. Signed-off-by: Justin Mazzola Paluska <justinmp@google.com>
Pulls in TSAN mutex fixes as well as works around false detection. Signed-off-by: Matt Klein <mklein@lyft.com>
…e so that two with the same name map to the same histogram object. (#12275) Commit Message: Creates a storage model for thread-local histograms enabling continuity of data across scope reloads. Previously, whenever a Scope was re-created, the counters, gauges, and text-readouts of the same names would retain their previous values. However, fresh histograms were created on every scope reload, and stats dumps would include duplicate histograms with the same name. This change adds an analogous name-based set of histograms, held in ThreadLocalStore, so that we have a single histogram representing all its generations of data. This is somewhat more complex than for the other stats, since there were thread-local buffers, which previously were owned by TlsScope and needed to be made independent. So this introduces a new tls histogram map in the tls-cache to maintain this. This should help unblock #12241. Additional Description: Risk Level: high (not clear whether this is enough testing of histogram usage) Testing: //test/... Docs Changes: n/a Release Notes: n/a Fixes: #3098 Signed-off-by: Joshua Marantz <jmarantz@google.com>
Signed-off-by: Elisha Ziskind <eziskind@google.com>
Commit Message: Revert buffer filter visibility back to public Additional Description: After bringing in #12337, we are unable to build the router check tool as we build it with the buffer filter extension, which is no longer visible to the target we use. This change reverts the visibility change for the buffer filter back to public. Risk Level: Low Testing: N/A Docs Changes: N/A Release Notes: N/A Part of #12444 Signed-off-by: Lisa Lu <lisalu@lyft.com>
Commit Message: add cast for android compilation Risk Level: low using the expected type for the constructor as the static_cast type. Testing: local build of envoy mobile for android. CI Signed-off-by: Jose Nino <jnino@lyft.com>
The log action will be used to set the dynamic metadata key "envoy.log", which can be used to decide whether to log a request. Signed-off-by: davidraskin <draskin@google.com>
* WIP add some header info on baggage Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * messing w/ stuff Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * get a compiling solution Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * lint Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * format again Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * formatting Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * change the test slightly Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * s/std::string/string_view Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add note about baggage and child/parent spans Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in test for OpenTracingDriverTest Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in test for OpenCensus Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in baggage test for xray Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in zipkin tests Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in http tracer impl test Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * fix test for nulltracer Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * Add additional TODO for zipkin impl and add in comments for tests Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * add in draft docs Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * fix doc link Signed-off-by: Matthew Grossman <matthewryangrossman@gmail.com> * Inline empty methods per mklein's nit Signed-off-by: Jake Kaufman <jkaufman@lyft.com> Co-authored-by: Jake Kaufman <jkaufman@lyft.com>
* build: Fix that custom docker image build The do_ci.sh builds the envoy and copies binary to under build-* directories. But recently, the arm64 build system was added but it does not consider the previous custom docker image build. It is very useful to build the custom docker image and test it within k8s environment. So, this patch support previous behavior again so that we can build the custom docker image. If some more cpu architectures are added, we can simple extends more cpu architectures. Signed-off-by: DongRyeol Cha <dr83.cha@samsung.com>
wangfakang
pushed a commit
that referenced
this pull request
May 30, 2022
…yproxy#20170) * test: adding a multi-envoy test (envoyproxy#20016) Functionally this handles the multi-envoy signal handler crash skips instantiating a runtime singleton (off by default, must stay off until remove global runtime: rebase runtime features on ABSL_flags envoyproxy#19847 is closed) Multi-envoy does not correctly support runtime flags or deprecation stats due to envoyproxy#19847 being incomplete. It can still handle proxy traffic client - L1 - L2 - upstream as shown in test. Risk Level: low Testing: yes Docs Changes: n/a Release Notes: n/a Part of envoyproxy/envoy-mobile#2003 Signed-off-by: Alyssa Wilk <alyssar@chromium.org> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * Add a congestionWindowInBytes method to Envoy::Network::Connection (envoyproxy#20105) Signed-off-by: Bin Wu <wub@google.com> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * Update QUICHE from 50f15e7a5 to cf1588207 (envoyproxy#20154) https://github.com/google/quiche/compare/50f15e7a5..cf1588207 $ git log 50f15e7a5..cf1588207 --date=short --no-merges --format="%ad %al %s" 2022-02-28 wub Deprecate --gfe2_reloadable_flag_quic_crypto_noop_if_disconnected_after_process_chlo. 2022-02-27 vasilvv Remove QuicheMemSlice(QuicUniqueBufferPtr, size_t) constructor. 2022-02-26 fayang Use std::string instead of absl::string_view in CryptoBufferMap. 2022-02-25 bnc Ignore incoming HTTP/3 MAX_PUSH_ID frames. 2022-02-25 bnc Remove Http3DebugVisitor::OnMaxPushIdFrameSent(). 2022-02-25 bnc Remove QuicSpdySession::CanCreatePushStreamWithId(). 2022-02-25 fayang Deprecate gfe2_reloadable_flag_quic_single_ack_in_packet2. Signed-off-by: Alyssa Wilk <alyssar@chromium.org> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * build(deps): bump actions/stale from 4.1.0 to 5 (envoyproxy#20159) Bumps [actions/stale](https://github.com/actions/stale) from 4.1.0 to 5. - [Release notes](https://github.com/actions/stale/releases) - [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md) - [Commits](actions/stale@v4.1.0...v5) --- updated-dependencies: - dependency-name: actions/stale dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * admin: improve test coverage and increase the coverage-percent threshold (envoyproxy#20025) Adds a missing test for recent lookups now that there are no more fake symbol tables. Adds tests for a variety of override methods defined in admin.h that were previously hard to hit. Adds a benchmark test to establish a baseline for the speedups in envoyproxy#19693 Signed-off-by: Joshua Marantz <jmarantz@google.com> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * test: removing a bunch of direct runtime singleton access (envoyproxy#19993) Signed-off-by: Alyssa Wilk <alyssar@chromium.org> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * build(deps): bump grpcio-tools in /examples/grpc-bridge/client (envoyproxy#20040) Bumps [grpcio-tools](https://github.com/grpc/grpc) from 1.43.0 to 1.44.0. - [Release notes](https://github.com/grpc/grpc/releases) - [Changelog](https://github.com/grpc/grpc/blob/master/doc/grpc_release_schedule.md) - [Commits](grpc/grpc@v1.43.0...v1.44.0) --- updated-dependencies: - dependency-name: grpcio-tools dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds to spellcheck Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * xray tracer: set subsegment type for child spans (#2) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * Xray subsegment (#3) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates xray subsegment name to use operation name (instead of parent's span name) Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * Xray subsegment (#4) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates xray subsegment name to use operation name (instead of parent's span name) Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds to spell check dictionary Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * fixes spellcheck Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds to spellcheck Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> xray tracer: set subsegment type for child spans (#2) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> Xray subsegment (#3) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates xray subsegment name to use operation name (instead of parent's span name) Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> Xray subsegment (#4) * xray tracer: set subsegment type for child spans Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds test coverage Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates xray subsegment name to use operation name (instead of parent's span name) Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * updates doc Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * adds to spell check dictionary Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> fixes spellcheck Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> * fixes spell check Signed-off-by: Rex Chang <58710378+rexnp@users.noreply.github.com> Co-authored-by: alyssawilk <alyssar@chromium.org> Co-authored-by: Bin Wu <46450037+wu-bin@users.noreply.github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Joshua Marantz <jmarantz@google.com>
wangfakang
pushed a commit
that referenced
this pull request
Sep 15, 2022
…roxy#22689) Commit Message: stream_idle_timer_ is armed to timeout the sending of the bufferred response payload in the quic stream send buffer after the end stream is buffered in the stream. But today this timer is armed even if the the encoding of the payload causes the stream to be closed, in which case the timer can never be cancelled till the stream destruction with ASSERT hit as below: [2022-08-12 22:23:38.843][12][critical][backtrace] [./source/server/backtrace.h:104] Caught Aborted, suspect faulting address 0x50e8d0000000c [2022-08-12 22:23:38.844][12][critical][backtrace] [./source/server/backtrace.h:91] Backtrace (use tools/stack_decode.py to get line numbers): [2022-08-12 22:23:38.844][12][critical][backtrace] [./source/server/backtrace.h:92] Envoy version: 0/1.24.0-dev/test/DEBUG/BoringSSL [2022-08-12 22:23:38.858][12][critical][backtrace] [./source/server/backtrace.h:96] #0: Envoy::SignalAction::sigHandler() [0x3480b28] [2022-08-12 22:23:38.858][12][critical][backtrace] [./source/server/backtrace.h:96] #1: __restore_rt [0x7f94b072c200] [2022-08-12 22:23:38.872][12][critical][backtrace] [./source/server/backtrace.h:96] #2: Envoy::Quic::EnvoyQuicStream::~EnvoyQuicStream() [0x2a2fe98] [2022-08-12 22:23:38.885][12][critical][backtrace] [./source/server/backtrace.h:96] #3: Envoy::Quic::EnvoyQuicServerStream::~EnvoyQuicServerStream() [0x2a78058] [2022-08-12 22:23:38.899][12][critical][backtrace] [./source/server/backtrace.h:96] #4: Envoy::Quic::EnvoyQuicServerStream::~EnvoyQuicServerStream() [0x2a77d30] [2022-08-12 22:23:38.912][12][critical][backtrace] [./source/server/backtrace.h:96] #5: Envoy::Quic::EnvoyQuicServerStream::~EnvoyQuicServerStream() [0x2a77d69] This change check stream close in this case, so that the idle timer will not be armed for closed streams. Risk Level: low Testing: new unit test Docs Changes: N/A Release Notes: N/A Platform Specific Features: N/A Signed-off-by: Dan Zhang <danzh@google.com>
wangfakang
pushed a commit
that referenced
this pull request
Sep 15, 2022
…voyproxy#22856) `//test/integration:tcp_proxy_odcds_integration_test` was observed to fail as follows: ``` ==================== Test output for //test/integration:tcp_proxy_odcds_integration_test: [==========] Running 24 tests from 1 test suite. [----------] Global test environment set-up. [----------] 24 tests from IpVersionsClientType/TcpProxyOdcdsIntegrationTest [ RUN ] IpVersionsClientType/TcpProxyOdcdsIntegrationTest.SingleTcpClient/0 [2022-08-25 20:22:46.750][3969][critical][assert] [test/integration/fake_upstream.cc:832] assert failure: !dispatcher_->isThreadSafe(). [2022-08-25 20:22:46.752][3969][critical][backtrace] [./source/server/backtrace.h:104] Caught Aborted, suspect faulting address 0x6b00000f81 [2022-08-25 20:22:46.752][3969][critical][backtrace] [./source/server/backtrace.h:91] Backtrace (use tools/stack_decode.py to get line numbers): [2022-08-25 20:22:46.752][3969][critical][backtrace] [./source/server/backtrace.h:92] Envoy version: 0/1.24.0-dev/test/DEBUG/BoringSSL [2022-08-25 20:22:46.773][3969][critical][backtrace] [./source/server/backtrace.h:96] #0: Envoy::SignalAction::sigHandler() [0x4c46a78]->[0x2cf2a78] external/com_google_googletest/googlemock/include/gmock/gmock-spec-builders.h:1267 [2022-08-25 20:22:46.773][3969][critical][backtrace] [./source/server/backtrace.h:96] #1: __restore_rt [0x7ffbdaa79420]->[0x7ffbd8b25420] ??:0 [2022-08-25 20:22:46.802][3969][critical][backtrace] [./source/server/backtrace.h:96] #2: Envoy::FakeUpstream::assertPendingConnectionsEmpty() [0x245bf0b]->[0x507f0b] ??:0 [2022-08-25 20:22:46.846][3969][critical][backtrace] [./source/server/backtrace.h:96] #3: Envoy::(anonymous namespace)::TcpProxyOdcdsIntegrationTest_SingleTcpClient_Test::TestBody() [0x1f596cb]->[0x56cb] ??:0 [2022-08-25 20:22:46.877][3969][critical][backtrace] [./source/server/backtrace.h:96] #4: testing::internal::HandleSehExceptionsInMethodIfSupported<>() [0x588b61b]->[0x393761b] ??:0 [2022-08-25 20:22:46.924][3969][critical][backtrace] [./source/server/backtrace.h:96] #5: testing::internal::HandleExceptionsInMethodIfSupported<>() [0x587c2bd]->[0x39282bd] ??:0 [2022-08-25 20:22:46.966][3969][critical][backtrace] [./source/server/backtrace.h:96] #6: testing::Test::Run() [0x5864ba3]->[0x3910ba3] /usr/lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/stl_vector.h:0 [2022-08-25 20:22:47.003][3969][critical][backtrace] [./source/server/backtrace.h:96] #7: testing::TestInfo::Run() [0x586576a]->[0x391176a] external/com_google_absl/absl/container/internal/raw_hash_set.h:1259 [2022-08-25 20:22:47.037][3969][critical][backtrace] [./source/server/backtrace.h:96] #8: testing::TestSuite::Run() [0x5865fbb]->[0x3911fbb] /usr/lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/stl_algo.h:1925 [2022-08-25 20:22:47.089][3969][critical][backtrace] [./source/server/backtrace.h:96] #9: testing::internal::UnitTestImpl::RunAllTests() [0x5874a28]->[0x3920a28] envoy/registry/registry.h:509 [2022-08-25 20:22:47.114][3969][critical][backtrace] [./source/server/backtrace.h:96] #10: testing::internal::HandleSehExceptionsInMethodIfSupported<>() [0x588ddbb]->[0x3939dbb] envoy/registry/registry.h:0 [2022-08-25 20:22:47.160][3969][critical][backtrace] [./source/server/backtrace.h:96] #11: testing::internal::HandleExceptionsInMethodIfSupported<>() [0x587e683]->[0x392a683] /usr/lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/unique_ptr.h:154 [2022-08-25 20:22:47.191][3969][critical][backtrace] [./source/server/backtrace.h:96] #12: testing::UnitTest::Run() [0x5874568]->[0x3920568] envoy/registry/registry.h:508 [2022-08-25 20:22:47.237][3969][critical][backtrace] [./source/server/backtrace.h:96] #13: RUN_ALL_TESTS() [0x4878d51]->[0x2924d51] external/com_google_googletest/googlemock/include/gmock/gmock-spec-builders.h:1203 [2022-08-25 20:22:47.284][3969][critical][backtrace] [./source/server/backtrace.h:96] #14: Envoy::TestRunner::RunTests() [0x48783b1]->[0x29243b1] external/com_google_googletest/googlemock/include/gmock/gmock-actions.h:485 [2022-08-25 20:22:47.316][3969][critical][backtrace] [./source/server/backtrace.h:96] #15: main [0x4874c3a]->[0x2920c3a] external/com_google_googletest/googlemock/include/gmock/gmock-spec-builders.h:1181 [2022-08-25 20:22:47.316][3969][critical][backtrace] [./source/server/backtrace.h:96] #16: __libc_start_main [0x7ffbda897083]->[0x7ffbd8943083] ??:0 ================================================================================ ``` This is due to the race described by envoyproxy#22855. Making sure the dispatcher thread is running before starting the test avoids this problem. Signed-off-by: Benjamin Peterson <benjamin@engflow.com>
hatappi
pushed a commit
to hatappi/envoy-go-extension
that referenced
this pull request
Nov 15, 2022
This test sends a large number of metadata frames in order to trigger a disconnect. However, it was possible for the disconnect to happen and the connection to be torn down before all the metadata frames had been sent. If that happened, ASAN detected a UAF:
```
==95==ERROR: AddressSanitizer: heap-use-after-free on address 0x60700037e5a0 at pc 0x000004811f9e bp 0x7ffc903af990 sp 0x7ffc903af988
READ of size 8 at 0x60700037e5a0 thread T0
#0 0x4811f9d in Envoy::IntegrationCodecClient::sendMetadata(Envoy::Http::RequestEncoder&, Envoy::Http::MetadataMap) /proc/self/cwd/test/integration/http_integration.cc:168:3
#1 0x46ed711 in Envoy::Http2FloodMitigationTest_RequestMetadata_Test::TestBody() /proc/self/cwd/test/integration/http2_flood_integration_test.cc:1486:20
wangfakang#2 0xd380e64 in void testing::internal::HandleExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*) /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2580:10
wangfakang#3 0xd348dc2 in testing::Test::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2655:5
wangfakang#4 0xd34a927 in testing::TestInfo::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2832:11
wangfakang#5 0xd34ccc4 in testing::TestSuite::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2986:28
wangfakang#6 0xd36f07a in testing::internal::UnitTestImpl::RunAllTests() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:5697:44
wangfakang#7 0xd384e63 in bool testing::internal::HandleExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*) /proc/self/cwd/external/com_google_googletest/googletest/src/
gtest.cc:2580:10
wangfakang#8 0xd36dd86 in testing::UnitTest::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:5280:10
wangfakang#9 0xa0e53a4 in Envoy::TestRunner::RunTests(int, char**) /proc/self/cwd/external/com_google_googletest/googletest/include/gtest/gtest.h:2485:46
wangfakang#10 0xa0e0af7 in main /proc/self/cwd/test/main.cc:34:10
wangfakang#11 0x7f442ef69082 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x24082) (BuildId: 1878e6b475720c7c51969e69ab2d276fae6d1dee)
wangfakang#12 0x45ed36d in _start (/mnt/ssd/cas/work/1/exec/bazel-out/k8-dbg/bin/test/integration/http2_flood_integration_test.runfiles/envoy/test/integration/http2_flood_integration_test+0x45ed36d)
0x60700037e5a0 is located 48 bytes inside of 80-byte region [0x60700037e570,0x60700037e5c0)
freed by thread T0 here:
#0 0x466f7d2 in free /local/mnt/workspace/bcain_clang_hu-bcain-lv_22036/final/llvm-project/compiler-rt/lib/asan/asan_malloc_linux.cpp:52:3
#1 0x831dde8 in Envoy::Http::CodecClient::ActiveRequest::~ActiveRequest() /proc/self/cwd/./source/common/http/codec_client.h:220:10
wangfakang#2 0x5aa33f9 in std::__1::unique_ptr<Envoy::Event::DeferredDeletable, std::__1::default_delete<Envoy::Event::DeferredDeletable> >::reset(Envoy::Event::DeferredDeletable*) /opt/llvm/bin/../include/c++/v1/__memory/unique_ptr.h:54:5
wangfakang#3 0xa3218e8 in Envoy::Event::DispatcherImpl::clearDeferredDeleteList() /proc/self/cwd/source/common/event/dispatcher_impl.cc:142:21
wangfakang#4 0xa3348df in void std::__1::__invoke_void_return_wrapper<void, true>::__call<Envoy::Event::DispatcherImpl::DispatcherImpl(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Envoy::Thread::ThreadFactory&, Envoy::TimeSource&
, Envoy::Random::RandomGenerator&, Envoy::Filesystem::Instance&, Envoy::Event::TimeSystem&, std::__1::function<std::__1::unique_ptr<Envoy::Event::ScaledRangeTimerManager, std::__1::default_delete<Envoy::Event::ScaledRangeTimerManager> > (Envoy::Event::Dispatcher&)> const&
, std::__1::shared_ptr<Envoy::Buffer::WatermarkFactory> const&)::$_2&>(Envoy::Event::DispatcherImpl::DispatcherImpl(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Envoy::Thread::ThreadFactory&, Envoy::TimeSource&, Envoy::Rand
om::RandomGenerator&, Envoy::Filesystem::Instance&, Envoy::Event::TimeSystem&, std::__1::function<std::__1::unique_ptr<Envoy::Event::ScaledRangeTimerManager, std::__1::default_delete<Envoy::Event::ScaledRangeTimerManager> > (Envoy::Event::Dispatcher&)> const&, std::__1::s
hared_ptr<Envoy::Buffer::WatermarkFactory> const&)::$_2&) /proc/self/cwd/source/common/event/dispatcher_impl.cc:79:30
wangfakang#5 0xa334603 in std::__1::__function::__func<Envoy::Event::DispatcherImpl::DispatcherImpl(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Envoy::Thread::ThreadFactory&, Envoy::TimeSource&, Envoy::Random::RandomGenerator&,
Envoy::Filesystem::Instance&, Envoy::Event::TimeSystem&, std::__1::function<std::__1::unique_ptr<Envoy::Event::ScaledRangeTimerManager, std::__1::default_delete<Envoy::Event::ScaledRangeTimerManager> > (Envoy::Event::Dispatcher&)> const&, std::__1::shared_ptr<Envoy::Buffe
r::WatermarkFactory> const&)::$_2, std::__1::allocator<Envoy::Event::DispatcherImpl::DispatcherImpl(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, Envoy::Thread::ThreadFactory&, Envoy::TimeSource&, Envoy::Random::RandomGenera
tor&, Envoy::Filesystem::Instance&, Envoy::Event::TimeSystem&, std::__1::function<std::__1::unique_ptr<Envoy::Event::ScaledRangeTimerManager, std::__1::default_delete<Envoy::Event::ScaledRangeTimerManager> > (Envoy::Event::Dispatcher&)> const&, std::__1::shared_ptr<Envoy:
:Buffer::WatermarkFactory> const&)::$_2>, void ()>::operator()() /opt/llvm/bin/../include/c++/v1/__functional/function.h:180:16
wangfakang#6 0x4897039 in std::__1::__function::__value_func<void ()>::operator()() const /opt/llvm/bin/../include/c++/v1/__functional/function.h:507:16
wangfakang#7 0xa8e6aa4 in Envoy::Event::SchedulableCallbackImpl::SchedulableCallbackImpl(Envoy::CSmartPtr<event_base, &(event_base_free)>&, std::__1::function<void ()>)::$_0::__invoke(int, short, void*) /opt/llvm/bin/../include/c++/v1/__functional/function.h:1184:12
wangfakang#8 0xb557c5e in event_process_active_single_queue /mnt/ssd/cas/work/2/exec/external/com_github_libevent_libevent/event.c:1713:4
wangfakang#9 0xb539252 in event_process_active /mnt/ssd/cas/work/2/exec/external/com_github_libevent_libevent/event.c
wangfakang#10 0xb539252 in event_base_loop /mnt/ssd/cas/work/2/exec/external/com_github_libevent_libevent/event.c:2047:12
wangfakang#11 0xa8e1e3c in Envoy::Event::LibeventScheduler::run(Envoy::Event::Dispatcher::RunType) /proc/self/cwd/source/common/event/libevent_scheduler.cc:60:3
wangfakang#12 0xa32bd94 in Envoy::Event::DispatcherImpl::run(Envoy::Event::Dispatcher::RunType) /proc/self/cwd/source/common/event/dispatcher_impl.cc:299:19
wangfakang#13 0x480faad in Envoy::IntegrationCodecClient::flushWrite() /proc/self/cwd/test/integration/http_integration.cc:100:29
wangfakang#14 0x4811e94 in Envoy::IntegrationCodecClient::sendMetadata(Envoy::Http::RequestEncoder&, Envoy::Http::MetadataMap) /proc/self/cwd/test/integration/http_integration.cc:169:3
wangfakang#15 0x46ed711 in Envoy::Http2FloodMitigationTest_RequestMetadata_Test::TestBody() /proc/self/cwd/test/integration/http2_flood_integration_test.cc:1486:20
wangfakang#16 0xd380e64 in void testing::internal::HandleExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*) /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2580:10
wangfakang#17 0xd348dc2 in testing::Test::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2655:5
wangfakang#18 0xd34a927 in testing::TestInfo::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2832:11
wangfakang#19 0xd34ccc4 in testing::TestSuite::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2986:28
wangfakang#20 0xd36f07a in testing::internal::UnitTestImpl::RunAllTests() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:5697:44
wangfakang#21 0xd384e63 in bool testing::internal::HandleExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*) /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:2580:10
wangfakang#22 0xd36dd86 in testing::UnitTest::Run() /proc/self/cwd/external/com_google_googletest/googletest/src/gtest.cc:5280:10
wangfakang#23 0xa0e53a4 in Envoy::TestRunner::RunTests(int, char**) /proc/self/cwd/external/com_google_googletest/googletest/include/gtest/gtest.h:2485:46
wangfakang#24 0xa0e0af7 in main /proc/self/cwd/test/main.cc:34:10
wangfakang#25 0x7f442ef69082 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x24082) (BuildId: 1878e6b475720c7c51969e69ab2d276fae6d1dee)
```
To fix that, write all metadata frames at once.
Signed-off-by: Benjamin Peterson <benjamin@engflow.com>
wangfakang
pushed a commit
that referenced
this pull request
Nov 29, 2022
When building the jni dylib for android, we previously stripped all debug info to decrease the artifact size. With this change we now produce the same stripped binary as before, but before stripping it we create a dump of the debug info suitable for crash reporting. This is made overly difficult for a few reasons: 1. Bazel doesn't support fission for Android bazelbuild/bazel#14765 2. Extra outputs from rules are not propagated up the dependency tree, so just building `android_dist` at the top level, isn't enough to get the extra outputs built as well 3. Building the library manually alongside the android artifact on the command line results in 2 separate builds, one for android as a transitive dependency of `android_dist` and one for the host platform This change avoids #1 fission for now, but the same approach could be used once that change makes its way to a bazel release. This change fixes #2 by using a separate output group that can be depended on by the genrule that writes to dist while avoiding #3 because the custom rule producing these uses the android transition. Signed-off-by: Keith Smiley <keithbsmiley@gmail.com> Signed-off-by: JP Simard <jp@jpsim.com>
wangfakang
pushed a commit
that referenced
this pull request
Nov 30, 2022
When building the jni dylib for android, we previously stripped all debug info to decrease the artifact size. With this change we now produce the same stripped binary as before, but before stripping it we create a dump of the debug info suitable for crash reporting. This is made overly difficult for a few reasons: 1. Bazel doesn't support fission for Android bazelbuild/bazel#14765 2. Extra outputs from rules are not propagated up the dependency tree, so just building `android_dist` at the top level, isn't enough to get the extra outputs built as well 3. Building the library manually alongside the android artifact on the command line results in 2 separate builds, one for android as a transitive dependency of `android_dist` and one for the host platform This change avoids #1 fission for now, but the same approach could be used once that change makes its way to a bazel release. This change fixes #2 by using a separate output group that can be depended on by the genrule that writes to dist while avoiding #3 because the custom rule producing these uses the android transition. Signed-off-by: Keith Smiley <keithbsmiley@gmail.com> Signed-off-by: JP Simard <jp@jpsim.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
For an explanation of how to fill out the fields, please see the relevant section
in PULL_REQUESTS.md
Description:
Risk Level:
Testing:
Docs Changes:
Release Notes:
[Optional Fixes #Issue]
[Optional Deprecated:]