You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Restrict visibility to Envoy internals in consuming projects #827
Today, the Bazel visibility for all targets (from source, to test support to the tests themselves) is public. This means that a project that consumes Envoy and adds its own filters etc., might rely on internal implementation details that are not intended to be stable aspects of the API.
We should restrict visibility outside of Envoy to only its interfaces, well defined library/binary exports (//source/exe:envoy, //source/exe:envoy_main_lib) and common code under ::Api:: that should be explicitly shared and is subject to the same API considerations as the Envoy interfaces in include.
The first step here is to make all of the filters in the tree only use public interfaces, this will force us to go through ::Api:: for access to utilities, which is a good thing to do.
#11618 is an example of where the lack of a stable interface has been a problem for us. I think for most filter authors going forward, Wasm will provide a compelling stable interface (in particular with NullVm), but there will be major consumers who will want better stability guarantees than what exists today.
We met recently to discuss and the following ideas came up:
Using compiler annotations, class finalization and Bazel visibility to provide a build mode that controls which parts of include/envoy that an extension would use.
Adding extra tests with RepoKitteh enforced review labels that validate Api:: behavior (limited set of reviewers).
Looking at device driver API stability policies from Linux and other related projects.
Setup Api:: shepherds to build a cohesive extension API surface.
Activity
mattklein123 commentedon Apr 24, 2017
The first step here is to make all of the filters in the tree only use public interfaces, this will force us to go through ::Api:: for access to utilities, which is a good thing to do.
htuch commentedon Jun 18, 2020
#11618 is an example of where the lack of a stable interface has been a problem for us. I think for most filter authors going forward, Wasm will provide a compelling stable interface (in particular with NullVm), but there will be major consumers who will want better stability guarantees than what exists today.
We met recently to discuss and the following ideas came up:
include/envoythat an extension would use.Api::behavior (limited set of reviewers).Api::shepherds to build a cohesive extension API surface.Fix finding default zone on macOS sierra