caliper icon indicating copy to clipboard operation
caliper copied to clipboard

Collect Prometheus metrics in manager using messages

Open CaptainIRS opened this issue 3 years ago • 1 comments

Alternative implementation that works for both local and remote workers. (This is just a draft implementation, discussions are ongoing in Discord)

Checklist

  • [x] A link to the issue/user story that the pull request relates to
  • [ ] How to recreate the problem without the fix
  • [ ] Design of the fix
  • [ ] How to prove that the fix works
  • [ ] Automated tests that prove the fix keeps on working
  • [ ] Documentation - any JSDoc, website, or Stackoverflow answers?

Issue/User story

#1353

Design of the fix

WIP

Validation of the fix

Approach Results
PushGateway with local workers and mqtt communication image
This PR (metrics communicated using messages) with local workers and mqtt communication image
PR #1434 (metrics communicated using IPC) with local workers and mqtt communication image

Automated Tests

WIP

What documentation has been provided for this pull request

WIP

CaptainIRS avatar Aug 09 '22 15:08 CaptainIRS

Codecov Report

Merging #1438 (87300ff) into main (64f3868) will decrease coverage by 0.78%. The diff coverage is 17.02%.

@@            Coverage Diff             @@
##             main    #1438      +/-   ##
==========================================
- Coverage   55.56%   54.77%   -0.79%     
==========================================
  Files         103      106       +3     
  Lines        4451     4544      +93     
  Branches      676      694      +18     
==========================================
+ Hits         2473     2489      +16     
- Misses       1435     1496      +61     
- Partials      543      559      +16     
Flag Coverage Δ
caliper-core 43.51% <17.02%> (-0.80%) :arrow_down:
caliper-fabric 80.46% <ø> (ø)
generator-caliper 83.62% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ackages/caliper-core/lib/common/utils/constants.js 100.00% <ø> (ø)
...ker/tx-observers/prometheus-manager-tx-observer.js 0.00% <0.00%> (ø)
...re/lib/worker/tx-observers/tx-observer-dispatch.js 19.23% <0.00%> (ø)
...ger/prometheus/prometheus-manager-scrape-target.js 14.28% <14.28%> (ø)
...e/lib/manager/orchestrators/worker-orchestrator.js 20.80% <23.52%> (+0.19%) :arrow_up:
packages/caliper-core/lib/common/messages/parse.js 41.02% <50.00%> (+0.48%) :arrow_up:
...ore/lib/common/messages/prometheusUpdateMessage.js 75.00% <75.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

codecov[bot] avatar Aug 09 '22 15:08 codecov[bot]