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

Update 'rv' value generation based on randomness flag + editorial changes to improve clarity #261

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

kalyanaj
Copy link

@kalyanaj kalyanaj commented Jun 5, 2024

Update 'r' value generation based on randomness flag + editorial changes to improve clarity.

@kalyanaj kalyanaj changed the title Update 'r' value generation based on randomness flag + editorial changes [DRAFT] Update 'r' value generation based on randomness flag + editorial changes Jun 5, 2024
@kalyanaj kalyanaj changed the title [DRAFT] Update 'r' value generation based on randomness flag + editorial changes Update 'r' value generation based on randomness flag + editorial changes to improve clarity Jun 5, 2024
@kalyanaj kalyanaj marked this pull request as ready for review June 5, 2024 17:52
@kalyanaj kalyanaj requested review from a team June 5, 2024 17:52
@tigrannajaryan
Copy link
Member

We don't typically update OTEPs with any substantial content. Minor editorial changes are fine, but otherwise normally a new OTEP is expected.

@kalyanaj
Copy link
Author

kalyanaj commented Jun 5, 2024

Hi @tigrannajaryan, to give you some context, while the diff looks bigger, there is no change to the proposal or approach itself, so from that perspective there are no changes (substantial or otherwise). This PR is an effort to improve the clarity and change the flow/wording (based on a discussion in the Sampling SIG) to improve the readability for future implementers of this spec.

@jmacd
Copy link
Contributor

jmacd commented Jun 6, 2024

Suggestion from Kent: please try to minimize diffs by keeping to one sentence per line of markdown.

@jmacd
Copy link
Contributor

jmacd commented Jun 11, 2024

@kalyanaj now that I've read this PR in detail, I agree with @tigrannajaryan's suggestion. This PR is difficult to review because of all the editorial changes, which I also appreciate. I think it would be easiest if we open a new PR with a completely new document, with a new OTEP number. Then, update the OTEP 235 document to refer to the new OTEP, along with an explanation of the non-editorial changes relative to 235.

In my words, the only change here is to say:

  • root/head samplers must insert "rv" if random flag is not set
  • child/head samplers must assume trace ID is random if "rv" is not set.

I see this change as a bug fix, but it is still a change. I think readers will be happy to read the edited document either way, but leaving OTEP 235 "as-is" may be easiest here. Thanks!

@jmacd jmacd changed the title Update 'r' value generation based on randomness flag + editorial changes to improve clarity Update 'rv' value generation based on randomness flag + editorial changes to improve clarity Jul 26, 2024
@jmacd
Copy link
Contributor

jmacd commented Jul 29, 2024

I have copied the bulk of this PR into open-telemetry/opentelemetry-specification#4166.

@jmacd
Copy link
Contributor

jmacd commented Aug 15, 2024

We should merge this, just need approvals. The language in this PR is already incorporated into the spec PRs, no reason not to merge.

@@ -80,23 +102,54 @@ The `T` value MUST be derived as follows:

Sampling Decisions MUST be propagated by setting the value of the `th` key in the Tracestate header according to the above.

## Initializing and updating T and R values
This design requires that as a given span progresses along its collection path, `th` is non decreasing (and, in particular, must be increased at stages that apply lower sampling probabilities).
Copy link
Contributor

Choose a reason for hiding this comment

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

This paragraph and the next one seem to imply that increasing T/th is fine, but decreasing it is not, whereas the Head Samplers sections puts this as an actual example.

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