Skip to content

stats: add lint error for using Stats::ScopePtr, and mark that nickname as deprecated#20896

Merged
jmarantz merged 3 commits intoenvoyproxy:mainfrom
jmarantz:stats-scope-deprecation
Apr 20, 2022
Merged

stats: add lint error for using Stats::ScopePtr, and mark that nickname as deprecated#20896
jmarantz merged 3 commits intoenvoyproxy:mainfrom
jmarantz:stats-scope-deprecation

Conversation

@jmarantz
Copy link
Copy Markdown
Contributor

@jmarantz jmarantz commented Apr 20, 2022

Commit Message: Prevent further in-repo uses of Stats::ScopePtr with a lint error. Attempt to discourage out-of-repo uses of Stats::ScopePtr with a deprecated flag, though that doesn't seem to cause any warning in our build or clang-tidy when I change a reference in the code. See #19468 for the change to suppress deprecation warnings.
Additional Description:
Risk Level: low
Testing: //test/common/stats/...
Docs Changes: n/a
Release Notes: n/a
Platform Specific Features: n/a

…eprecated.

Signed-off-by: Joshua Marantz <jmarantz@google.com>
@repokitteh-read-only
Copy link
Copy Markdown

As a reminder, PRs marked as draft will not be automatically assigned reviewers,
or be handled by maintainer-oncall triage.

Please mark your PR as ready when you want it to be reviewed!

🐱

Caused by: #20896 was opened by jmarantz.

see: more, trace.

Signed-off-by: Joshua Marantz <jmarantz@google.com>
Signed-off-by: Joshua Marantz <jmarantz@google.com>
@jmarantz jmarantz changed the title WiP stats: add lint error for using Stats::ScopePtr, and mark that nickname as deprecated stats: add lint error for using Stats::ScopePtr, and mark that nickname as deprecated Apr 20, 2022
@jmarantz jmarantz marked this pull request as ready for review April 20, 2022 13:53
@KBaichoo
Copy link
Copy Markdown
Contributor

/retest

@repokitteh-read-only
Copy link
Copy Markdown

Retrying Azure Pipelines:
Retried failed jobs in: envoy-presubmit

🐱

Caused by: a #20896 (comment) was created by @KBaichoo.

see: more, trace.

Copy link
Copy Markdown
Contributor

@KBaichoo KBaichoo left a comment

Choose a reason for hiding this comment

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

lgtm!

// references, once known consumers that might break from this change have a
// chance to do the global replace in their own repos.
using ScopePtr = ScopeSharedPtr;
using ScopePtr ABSL_DEPRECATED("Use ScopeSharedPtr() instead.") = ScopeSharedPtr;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do we have a timeline / a tracking issue for when we'll finally get rid of this?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

#20911. I'll submit this first to get the lint check online before any other refs show up .. then I'll add a ref to that issue here.

@jmarantz jmarantz merged commit fbcfafb into envoyproxy:main Apr 20, 2022
@jmarantz jmarantz deleted the stats-scope-deprecation branch April 20, 2022 20:51
mum4k pushed a commit to envoyproxy/nighthawk that referenced this pull request Apr 26, 2022
- Update the ENVOY_COMMIT and ENVOY_SHA in [bazel/repositories.bzl](https://github.com/envoyproxy/nighthawk/blob/main/bazel/repositories.bzl) to the latest Envoy's commit.
- Log the value when failed to record value into HdrHistogram.
- Replace `Stats::ScopePtr` with preferred term `Stats::ScopeSharedPtr`. This was introduced into format check by envoyproxy/envoy#20896.

Signed-off-by: jiajunye [jiajunye@google.com](mailto:jiajunye@google.com)
ravenblackx pushed a commit to ravenblackx/envoy that referenced this pull request Jun 8, 2022
…me as deprecated (envoyproxy#20896)

Commit Message: Prevent further in-repo uses of Stats::ScopePtr with a lint error. Attempt to discourage out-of-repo uses of Stats::ScopePtr with a deprecated flag, though that doesn't seem to cause any warning in our build or clang-tidy when I change a reference in the code. See envoyproxy#19468 for the change to suppress deprecation warnings.
Additional Description:
Risk Level: low
Testing: //test/common/stats/...
Docs Changes: n/a
Release Notes: n/a
Platform Specific Features: n/a

Signed-off-by: Joshua Marantz <jmarantz@google.com>
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.

2 participants