Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: mark matching API and related features as alpha #16210

Merged
merged 13 commits into from
May 21, 2021

Conversation

snowp
Copy link
Contributor

@snowp snowp commented Apr 28, 2021

Commit Message: Marks the matching API more clearly as experimental and updates the composite filter security posture to reflect this.
Additional Description:
Risk Level: Low, docs only
Testing: n/a
Docs Changes: n/a
Release Notes: n/a
Platform Specific Features: n/a

@repokitteh-read-only
Copy link

CC @envoyproxy/api-shepherds: Your approval is needed for changes made to api/envoy/.
envoyproxy/api-shepherds assignee is @htuch
CC @envoyproxy/api-watchers: FYI only for changes made to api/envoy/.

🐱

Caused by: #16210 was opened by snowp.

see: more, trace.

@@ -22,7 +22,7 @@ option (udpa.annotations.file_status).package_version_status = ACTIVE;
// As an on_no_match might result in another matching tree being evaluated, this process
// might repeat several times until the final OnMatch (or no match) is decided.
//
// This API is a work in progress.
// This API is currently considered experimental and is a work in progress.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a [#experimental: tag and render this as a warning box? @phlax could you help @snowp with this if possible? It should be doable in https://github.com/envoyproxy/envoy/blob/main/tools/protodoc/protodoc.py.

Also, can https://www.envoyproxy.io/docs/envoy/latest/intro/arch_overview/security/threat_model#threat-model be updated to explicitly state anything flagged as experimental is out-of-scope?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is https://github.com/envoyproxy/envoy/pull/16210/files#diff-7e7afbba95a0599ef388b3eb10e44c6cf3520dd65c24ef0f8d77e790d683a537L80-R83 not sufficient for updating the threat model? Anywhere else I should point out that experimental features are not covered?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the cache filter probs wants to be marked as experimental too i think

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

apologies - i misread comment - i can help adding the annotation + parser if its helpful to

snowp added 3 commits April 30, 2021 14:38
Signed-off-by: Snow Pettersen <[email protected]>
Signed-off-by: Snow Pettersen <[email protected]>
Signed-off-by: Snow Pettersen <[email protected]>
it should be hardened with this model in mind. Security issues related to core code will usually
trigger the security release process as described in this document.
Anything in the Envoy core may be used in both untrusted and trusted deployments, with the exception
of features explicitly marked as experimental. As a consequence, it should be hardened with this model
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"marked as experimental; experimental features are only supported in trusted deployments and do not qualify for treatment under the threat model below" or something like that.

experimental_warning = ''
if annotations.EXPERIMENTAL_ANNOTATION in comment.annotations:
experimental_warning = (
'.. warning::\n This API is experimental and is not covered by the security posture.\n\n'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"not covered by the threat model" (and link back to the RST for this)

Copy link
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a general comment, we now have multiple notions of WiP:

  • This experimental protodoc tag.
  • The not-implemented-hide protodoc tag (sort of overlaps but not exactly).
  • alpha status on the extension.
  • work_in_progress proto annotation.

Is it clear which to use and where?

@snowp
Copy link
Contributor Author

snowp commented May 4, 2021

I think the need for experimental comes in here for core protos that are experimental: the protos live in a file with existing stable protos (maybe it shouldn't have, that way we could have just marked this as alpha/work-in-progress). I also think the WIP tag only works for extension docs, which isn't going to be applicable to these core protos.

Perhaps we should add docs somewhere or attempt to reconcile these variations? For example, we could have a message level WIP annotation instead of this new experimental tag?

@phlax
Copy link
Member

phlax commented May 4, 2021

Perhaps we should add docs somewhere or attempt to reconcile these variations?

seems like a good idea - but it would be good to get something one way or another, so im +1 to adding it for now unless we can resolve upstream quickly

For example, we could have a message level WIP annotation instead of this new experimental tag?

my feeling is that experimental needs to be distinct from WIP

snowp added 2 commits May 4, 2021 20:47
Signed-off-by: Snow Pettersen <[email protected]>
Signed-off-by: Snow Pettersen <[email protected]>
@htuch
Copy link
Member

htuch commented May 5, 2021

Maybe replace WIP annotations with experimental at file level? Docs coverage in api/STYLE.md would be fantastic.

Copy link
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM modulo api/STYLE.md update on the range of experimental/WiP/alpha etc.

api/STYLE.md Outdated
@@ -34,6 +34,10 @@ In addition, the following conventions should be followed:
implementation. These indicate that the entity is not implemented in Envoy and the entity
should be hidden from the Envoy documentation.

* Use a `[#experimental:]` annotation in comments for messages that are considered experimental
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought that generally alpha things weren't considered to be in the threat model. Maybe we should just tag this alpha instead?

@yanavlasov for thoughts

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This gets to my comment above #16210 (review). I think the issue is we can only tag as alpha at file level. @snowp points out that sometimes we want to tag at feature level.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, but can we call them both alpha, rather than alpha and experimental? Unless there are actual differences, but I think the description above could apply to either so I'd lean towards calling it alpha and shipping :-)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I'm good with more consistent terminology here, that helps reduce some of the confusion.

Signed-off-by: Snow Pettersen <[email protected]>
@alyssawilk alyssawilk self-assigned this May 10, 2021
Copy link
Contributor

@alyssawilk alyssawilk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice! Just a few more comments for all the shepherds' reviews matter more here =P

api/STYLE.md Outdated
@@ -34,6 +34,10 @@ In addition, the following conventions should be followed:
implementation. These indicate that the entity is not implemented in Envoy and the entity
should be hidden from the Envoy documentation.

* Use a `[#alpha:]` annotation in comments for messages that are considered alpha
and are not subject to the threat model. This differs from the work-in-progress/alpha tagging
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need to update this comment given it's now alpha tagging :-)

I think also worth calling out that things tagged alpha are not yet subject to the stable API policies and security release policies.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm we still have extension level alpha tagging which differs from this alpha tag which is the only way to mark messages within core as alpha. What kind of change were you thinking about?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was trying to resolve the two, and have alpha tagging for extensions be functionally the same as alpha tagging for messages and fields, which is basically that both are WIP, not stable APIs and less trusted code.

@@ -3,6 +3,11 @@
Composite Filter
================

.. attention::

The composite filter is experimental and is currently under active development.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

optional: experimental -> alpha here and below?

Copy link
Contributor

@alyssawilk alyssawilk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh and PR name/description experimental -> alpha?

Signed-off-by: Snow Pettersen <[email protected]>
@snowp snowp changed the title docs: mark matching API and related features as experimental docs: mark matching API and related features as alpha May 11, 2021
@@ -3,6 +3,11 @@
Matching API
============

.. attention::

The matching API is experimental and is currently under active development.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: s/experimental/alpha/

alpha_warning = ''
if annotations.ALPHA_ANNOTATION in comment.annotations:
experimental_warning = (
'.. warning::\n This API is alpha and is not covered by the :ref:`threat model <arch_overview_threat_model>`.\n\n'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW, we have a broader issue which we can resolve after we land this PR. We have both implementation and API alpha/experimental/unknown robustness status. An API is not really insecure in and of itself, this is an implementation attribute.

We really need a way to mark in the protos client specific implementation status details, since Envoy vs. gRPC support for a feature might have different implementation status.

I started to explore this in #11085, but it's not really something I have b/w for. Maybe @phlax this can be part of the docs/tooling roadmap?

CC @markdroth

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, it would be nice to have some generic solution for this kind of thing. Matt has been saying for a while that we need a way to have client-specific docs in the proto files, not just for API status but for any type of documentation. Although as the number of xDS clients grows, I'm not sure how feasible it will be to document all of the in the same proto files. But this is definitely something we need to come up with a good strategy for.

Copy link
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM modulo nit. Will leave final sign-off/merge to @alyssawilk

Signed-off-by: Snow Pettersen <[email protected]>
@htuch
Copy link
Member

htuch commented May 21, 2021

/lgtm api

@htuch htuch merged commit b603923 into envoyproxy:main May 21, 2021
leyao-daily pushed a commit to leyao-daily/envoy that referenced this pull request Sep 30, 2021
Marks the matching API more clearly as experimental and updates the composite filter security posture to reflect this.

Signed-off-by: Snow Pettersen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants