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

PLT-1879: enable method level metrics in metastore to show in prometheus #2340

Merged
merged 4 commits into from
Sep 5, 2023

Conversation

n5nk
Copy link

@n5nk n5nk commented Sep 4, 2023

Change description

Enable method level metrics in metastore to show in Prometheus.

  • Use atlas.metrics.method_patterns to include MetricRecorder metric name.
  • Use atlas.metrics.method_level.enable to enable method level metrics.

Atlas properties

atlas.metrics.method_level.enable=true
atlas.metrics.method_patterns=elasticSearchQuery,scrubSearchResults

Logs in ELK:

log:[DEBUG] 2023-09-05 11:16:57,358 METRICS clearCache - X-Atlan-Request-Id: - trace-id:64cab6f5-a014-4647-b773-fb39b2fe5f33 - 
{"elasticSearchQuery":{"count":1,"timeTaken":15},"mapVertexToAtlasEntityHeader":
{"count":144,"timeTaken":1632},"getAllClassifications":{"count":144,"timeTaken":2},"scrubSearchResults":
{"count":1,"timeTaken":91}} @timestamp:Sep 5, 2023 @ 16:46:57.359 logtag:F stream:stdout _id:GhgPZYoBCaT57OuievMs 
_index:atlas-metric-2023-09-05 _score: - _type:_doc
Screenshot 2023-09-05 at 5 42 30 PM

Sample Metrics:

# HELP method_dist_summary_seconds_max  
# TYPE method_dist_summary_seconds_max gauge
method_dist_summary_seconds_max{integration="local",name="scrubSearchResults",service="atlas-metastore",} 0.003
method_dist_summary_seconds_max{integration="local",name="elasticSearchQuery",service="atlas-metastore",} 0.158
# HELP method_dist_summary_seconds  
# TYPE method_dist_summary_seconds summary
method_dist_summary_seconds{integration="local",name="scrubSearchResults",service="atlas-metastore",quantile="0.99",} 0.002883584
method_dist_summary_seconds_count{integration="local",name="scrubSearchResults",service="atlas-metastore",} 1.0
method_dist_summary_seconds_sum{integration="local",name="scrubSearchResults",service="atlas-metastore",} 0.003
method_dist_summary_seconds{integration="local",name="elasticSearchQuery",service="atlas-metastore",quantile="0.99",} 0.150994944
method_dist_summary_seconds_count{integration="local",name="elasticSearchQuery",service="atlas-metastore",} 1.0
method_dist_summary_seconds_sum{integration="local",name="elasticSearchQuery",service="atlas-metastore",} 0.158

Related issues

Fix #1

Checklists

Development

  • Lint rules pass locally
  • Application changes have been tested thoroughly
  • Automated tests covering modified code pass

Security

  • Security impact of change has been considered
  • Code follows company security practices and guidelines

Code review

  • Pull request has a descriptive title and context useful to a reviewer. Screenshots or screencasts are attached as necessary
  • "Ready for review" label attached and reviewers assigned
  • Changes have been reviewed by at least one other contributor
  • Pull request linked to task tracker where applicable

@n5nk n5nk merged commit 4a47ac3 into master Sep 5, 2023
8 checks passed
@checkaayush checkaayush deleted the PLT-1879 branch April 23, 2024 09:43
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