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

Issue1104 msg rate cpu #1105

Merged
merged 5 commits into from
Jun 13, 2024
Merged

Issue1104 msg rate cpu #1105

merged 5 commits into from
Jun 13, 2024

Conversation

petersilva
Copy link
Contributor

close #1104

adds a metric to understand how expensive routing each message is.
currently only deals with received messages. Should we fold in transmitted messages also?
same metric? other metric?

Typically the complexity is not on transmission, but rather reception (filtering is there.)

sample output (during a static flow test) look at the... nth column... um... titled msg/scpu

SSC-5CD2310S60% sr3 --full status
status:
Component/Config                         Processes   Connection        Lag                              Rates                                                   Counters (per housekeeping)                                                    Data Counters                                           Memory                             CPU Time
                                         State   Run Retry  msg data   Queued  LagMax LagAvg  Last  %rej     pubsub messages   RxData     TxData       Msg/scpu   subBytes   Accepted   Rejected  Malformed   pubBytes    pubMsgs     pubMal     rxData    rxFiles     txData    txFiles    Since       uss        rss        vms       user     system
                                         -----   --- -----  --- ----   ------  ------ ------  ----  ----     ------ --------   ------     ------        -------   --------   --------  ---------    -------     ------      -----      -----    -------     ------  -------      -----        ---        ---        ---       ----     ------
cpost/pelle_dd1_f04                      stop    0/0     0   0%   0%      0    0.00s    0.00s 0      0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files    0.00s    0 Bytes    0 Bytes    0 Bytes        0.00       0.00
cpost/pelle_dd2_f05                      stop    0/0     0   0%   0%      0    0.00s    0.00s 0      0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files    0.00s    0 Bytes    0 Bytes    0 Bytes        0.00       0.00
cpost/veille_f34                         idle    1/1     0 100%   0%      0    0.00s    0.00s n/a    0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  131.10s    5.1 MiB    8.9 MiB   15.9 MiB        0.22       0.18
cpump/xvan_f14                           idle    1/1     0 100%   0%      0    0.00s    0.00s n/a    0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files   56.61s    5.6 MiB    9.5 MiB   16.8 MiB        0.13       0.16
cpump/xvan_f15                           idle    1/1     0 100%   0%      0    0.00s    0.00s n/a    0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files   92.23s    3.2 MiB    5.0 MiB   16.3 MiB        0.09       0.07
poll/sftp_f62                            cpuS    1/1     0 100%   0%      0    1.26s    0.66s 66.5s 687.2%  7.7 KiB/s  10 msgs/s  0 Bytes/s  0 Bytes/s   227 msgs  500.9 KiB    1.4 Kim    9.5 Kim     0 msgs  500.9 KiB    1.4 Kim     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  129.36s   53.2 MiB   68.1 MiB  235.9 MiB        6.26       0.90
poll/sftp_f63                            wVip    1/1     0 100%   0%      0   20.18s    8.79s 65.7s  0.0%  3.9 KiB/s  10 msgs/s  0 Bytes/s  0 Bytes/s    1.9 Kim  500.9 KiB    1.4 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  129.29s   44.2 MiB   58.5 MiB   82.9 MiB        1.53       0.17
post/shim_f63                            stop    0/0          -          -         -     -     -          -        -        -       -          -          -          -          -          -          -          -          -          -          -          -          -          -          -          -
post/t_dd1_f00                           stop    0/0     0 100%   0%      0   12.24s    7.02s 115.5s  0.0%  3.3 KiB/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs    10 msgs     0 msgs  437.3 KiB    1.0 Kim     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  131.07s    0 Bytes    0 Bytes    0 Bytes        0.00       0.00
post/t_dd2_f00                           stop    0/0     0 100%   0%      0   12.46s    7.15s 115.3s  0.0%  3.4 KiB/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs    10 msgs     0 msgs  445.2 KiB    1.0 Kim     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  131.11s    0 Bytes    0 Bytes    0 Bytes        0.00       0.00
post/test2_f61                           stop    0/0     0 100%   0%      0    0.49s    0.48s 90.6s  0.0% 133 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs   11.9 KiB    25 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files   91.23s    0 Bytes    0 Bytes    0 Bytes        0.00       0.00
report/tsarra_f20                        idle    1/1     0 100%   0%      0    0.00s    0.00s n/a    0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  129.77s   39.3 MiB   53.4 MiB   77.7 MiB        0.87       0.03
sarra/download_f20                       idle    1/1     0 100%   0%      0    0.00s    0.00s 103.8s  0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files    5.68s   41.5 MiB   55.9 MiB   81.2 MiB        4.61       0.73
sender/tsource2send_f50                  cpuS    1/1     0 100%  95%      0    7.82s    4.00s 94.2s  0.0% 31.8 KiB/s  10 msgs/s  0 Bytes/s 12.8 KiB/s   124 msgs    2.0 MiB    1.4 Kim     0 msgs     0 msgs    2.0 MiB    1.4 Kim     0 msgs    0 Bytes    0 Files    1.6 MiB    1.4 KiF  129.61s   42.8 MiB   57.3 MiB  225.6 MiB        9.90       2.32
shovel/rabbitmqtt_f22                    run     1/1     0 100%   0%      0    4.07s    2.46s 99.3s  0.0% 31.9 KiB/s  10 msgs/s  0 Bytes/s  0 Bytes/s    1.0 Kim    2.0 MiB    1.4 Kim     0 msgs     0 msgs    2.0 MiB    1.4 Kim     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files  129.37s   40.2 MiB   54.4 MiB   79.0 MiB        1.91       0.31
subscribe/amqp_f30                       cpuS    1/1     0 100%  95%      0   24.00s   14.87s 103.8s  0.0%  4.5 KiB/s  10 msgs/s 12.8 KiB/s  0 Bytes/s   403 msgs  580.8 KiB    1.4 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    1.4 KiF    0 Bytes    0 Files  129.27s   40.1 MiB   54.6 MiB   79.0 MiB        3.60       0.78
subscribe/cdnld_f21                      cpuS    1/1     0 100%  98%    163   15.21s    9.85s 114.6s  0.1%  4.8 KiB/s  13 msgs/s 12.8 KiB/s  0 Bytes/s   337 msgs  615.4 KiB    1.7 Kim     2 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    1.7 KiF    0 Bytes    0 Files  129.27s   42.3 MiB   62.2 MiB   89.3 MiB        5.18       0.80
subscribe/cfile_f44                      cpuS    1/1     0 100%  98%      1    2.01s    0.95s 112.7s  0.0%  4.6 KiB/s  11 msgs/s 12.8 KiB/s  0 Bytes/s   388 msgs  596.5 KiB    1.5 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    1.5 KiF    0 Bytes    0 Files  129.43s   42.2 MiB   61.8 MiB   89.2 MiB        4.19       0.55
subscribe/cp_f61                         run     1/1     0 100%  89%      0    8.87s    5.71s 93.8s  0.0% 15.8 KiB/s  10 msgs/s  4.7 KiB/s  0 Bytes/s    1.3 Kim    2.0 MiB    1.4 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs  604.8 KiB  321 Files    0 Bytes    0 Files  129.34s   40.2 MiB   54.6 MiB   79.2 MiB        1.66       0.24
subscribe/ftp_f70                        cpuS    1/1     0 100%  87%      0    6.73s    3.51s 84.8s  0.0%  4.3 KiB/s   8 msgs/s 12.8 KiB/s  0 Bytes/s   258 msgs  550.5 KiB    1.1 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    1.1 KiF    0 Bytes    0 Files  129.42s   40.0 MiB   54.6 MiB   78.9 MiB        4.14       1.02
subscribe/mirror_f80                     cpuS    1/1     0 100%  87%      0    3.33s    1.40s 76.5s  0.0%  8.1 KiB/s  21 msgs/s 12.7 KiB/s  0 Bytes/s   445 msgs    1.0 MiB    2.8 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    2.8 KiF    0 Bytes    0 Files  129.64s   42.1 MiB   61.7 MiB   88.2 MiB        5.64       1.53
subscribe/q_f71                          cpuS    5/5     0 100%  11%      0   11.31s    3.54s 45.6s  0.1%  3.9 KiB/s  10 msgs/s 12.8 KiB/s  0 Bytes/s    14 msgs  500.9 KiB    1.4 Kim      1 msg     0 msgs    0 Bytes     0 msgs     0 msgs    1.6 MiB    1.4 KiF    0 Bytes    0 Files  129.34s  218.7 MiB  319.2 MiB    1.5 GiB      100.80       3.16
subscribe/rabbitmqtt_f31                 run     1/1     0 100%  90%      0    7.19s    3.75s 97.9s  0.0% 15.8 KiB/s  10 msgs/s  4.7 KiB/s  0 Bytes/s    1.4 Kim    2.0 MiB    1.4 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs  604.8 KiB  321 Files    0 Bytes    0 Files  129.38s   40.2 MiB   54.7 MiB   78.2 MiB        1.52       0.26
subscribe/u_sftp_f60                     run     1/1     0 100%  89%      0    8.85s    5.65s 93.8s  0.0% 15.8 KiB/s  10 msgs/s  4.7 KiB/s  0 Bytes/s    1.3 Kim    2.0 MiB    1.4 Kim     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs  604.8 KiB  321 Files    0 Bytes    0 Files  129.60s   40.2 MiB   54.7 MiB   79.2 MiB        1.65       0.21
watch/f40                                run     1/1     0 100%   0%      0    0.00s    0.00s 100.0s  0.0%  0 Bytes/s   0 msgs/s  0 Bytes/s  0 Bytes/s     0 msgs    0 Bytes     0 msgs     0 msgs     0 msgs    0 Bytes     0 msgs     0 msgs    0 Bytes    0 Files    0 Bytes    0 Files    7.87s   50.6 MiB   69.7 MiB  307.6 MiB       10.31       3.00
      Total Running Configs:  19 ( Processes: 23 missing: 0 stray: 0 )
                     Memory: uss:871.6 MiB rss:1.2 GiB vms:3.2 GiB
                   CPU Time: User:164.21s System:16.42s
           Pub/Sub Received: 176 msgs/s (167.5 KiB/s), Sent:  49 msgs/s (42.3 KiB/s) Queued: 164 Retry: 0, Mean lag: 4.93s
              Data Received: 106 Files/s (107.6 KiB/s), Sent: 10 Files/s (12.8 KiB/s)
SSC-5CD2310S60%

I set the runStateThrehold_cpuSlow to 1000 ... which is kind of high for this, so a lot of flows show up as cpuS in the second column.

Copy link

github-actions bot commented Jun 7, 2024

Test Results

243 tests   242 ✅  1m 3s ⏱️
  1 suites    1 💤
  1 files      0 ❌

Results for commit 01b8a46.

♻️ This comment has been updated with latest results.

@petersilva petersilva marked this pull request as ready for review June 7, 2024 20:33
@petersilva petersilva merged commit 5b66b38 into development Jun 13, 2024
4 checks passed
@petersilva petersilva deleted the issue1104_msgRateCpu branch June 13, 2024 23:14
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.

add metrics to indicate cpu-time used per file/message
2 participants