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

add support for simplified legends #1243

Merged
merged 1 commit into from
Jan 27, 2021

Conversation

brharrington
Copy link
Contributor

The default legends just summarize the expression and are
often hard to read and get truncated. This change adds a
helper that tries to generate a simplified legend if the
user has not set the legend explicitly. It will look at
the full set of expressions being rendered and try to
emphasize differences where possible.

Example:

  Expr:
       nf.cluster,www-main,:eq,
       name,apache.http.request,:eq,:and,
       :dist-stddev

Before:
       sqrt(
         (
           (
             (
               (statistic=count) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
               *
               (statistic=totalOfSquares) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
             )
             -
             (
               (statistic in (totalAmount,totalTime)) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
               *
               (statistic in (totalAmount,totalTime)) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
             )
           )
           /
           (
             (statistic=count) and (
               (nf.cluster=www-main) and (name=apache.http.request)
             )
             *
             (statistic=count) and (
               (nf.cluster=www-main) and (name=apache.http.request)
             )
           )
         )
       )

 After:
       apache.http.request

This can be disabled by setting:

atlas.eval.graph.simple-legends-enabled = false

The default legends just summarize the expression and are
often hard to read and get truncated. This change adds a
helper that tries to generate a simplified legend if the
user has not set the legend explicitly. It will look at
the full set of expressions being rendered and try to
emphasize differences where possible.

Example:

```
  Expr:
       nf.cluster,www-main,:eq,
       name,apache.http.request,:eq,:and,
       :dist-stddev

Before:
       sqrt(
         (
           (
             (
               (statistic=count) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
               *
               (statistic=totalOfSquares) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
             )
             -
             (
               (statistic in (totalAmount,totalTime)) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
               *
               (statistic in (totalAmount,totalTime)) and (
                 (nf.cluster=www-main) and (name=apache.http.request)
               )
             )
           )
           /
           (
             (statistic=count) and (
               (nf.cluster=www-main) and (name=apache.http.request)
             )
             *
             (statistic=count) and (
               (nf.cluster=www-main) and (name=apache.http.request)
             )
           )
         )
       )

 After:
       apache.http.request
```

This can be disabled by setting:

```
atlas.eval.graph.simple-legends-enabled = false
```
@brharrington brharrington added this to the 1.7.0 milestone Jan 27, 2021
@brharrington brharrington requested a review from jfz January 27, 2021 20:51
@brharrington brharrington merged commit 547e511 into Netflix:master Jan 27, 2021
@brharrington brharrington deleted the simple-legend branch January 27, 2021 23:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants