Skip to content

Commit 5286dae

Browse files
ilyam8cakrit
authored andcommitted
python.d.plugin update (netdata#4936)
<!-- Describe the change in summary section, including rationale and degin decisions. Include "Fixes #nnn" if you are fixing an existing issue. In "Component Name" section write which component is changed in this PR. This will help us review your PR quicker. If you have more information you want to add, write them in "Additional Information" section. This is usually used to help others understand your motivation behind this change. A step-by-step reproduction of the problem is helpful if there is no related issue. --> ##### Summary Fix: netdata#4756 `python.d.plugin` updates: * remove `retries` option * make `penalty` configurable (enabled by default, max is 10 minutes) > penalty indicates whether to apply penalty to update_every in case of failures. > Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes. > penalty: yes ##### Component Name `python.d.plugin` ##### Additional Information
1 parent e096424 commit 5286dae

File tree

117 files changed

+282
-465
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

117 files changed

+282
-465
lines changed

collectors/python.d.plugin/README.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ Every configuration file must have one of two formats:
2121

2222
```yaml
2323
update_every : 2 # update frequency
24-
retries : 1 # how many failures in update() is tolerated
2524
priority : 20000 # where it is shown on dashboard
2625

2726
other_var1 : bla # variables passed to module
@@ -33,7 +32,6 @@ other_var2 : alb
3332
```yaml
3433
# module defaults:
3534
update_every : 2
36-
retries : 1
3735
priority : 20000
3836

3937
local: # job name
@@ -42,11 +40,10 @@ local: # job name
4240

4341
other_job:
4442
priority : 5 # job position on dashboard
45-
retries : 20 # job retries
4643
other_var2 : val # module specific variable
4744
```
4845
49-
`update_every`, `retries`, and `priority` are always optional.
46+
`update_every` and `priority` are always optional.
5047

5148
## How to debug a python module
5249

collectors/python.d.plugin/adaptec_raid/adaptec_raid.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,9 @@
1919
# If unset, the default for python.d.plugin is used.
2020
# priority: 60000
2121

22-
# retries sets the number of retries to be made in case of failures.
23-
# If unset, the default for python.d.plugin is used.
24-
# Attempts to restore the service are made once every update_every
25-
# and only if the module has collected values in the past.
26-
# retries: 60
22+
# penalty indicates whether to apply penalty to update_every in case of failures.
23+
# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes.
24+
# penalty: yes
2725

2826
# autodetection_retry sets the job re-check interval in seconds.
2927
# The job is not deleted if check fails.
@@ -50,6 +48,6 @@
5048
# # JOBs sharing a name are mutually exclusive
5149
# update_every: 1 # the JOB's data collection frequency
5250
# priority: 60000 # the JOB's order on the dashboard
53-
# retries: 60 # the JOB's number of restoration attempts
51+
# penalty: yes # the JOB's penalty
5452
# autodetection_retry: 0 # the JOB's re-check interval in seconds
5553
# ----------------------------------------------------------------------

collectors/python.d.plugin/apache/README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,10 @@ priority : 90100
4646

4747
local:
4848
url : 'http://localhost/server-status?auto'
49-
retries : 20
5049

5150
remote:
5251
url : 'http://www.apache.org/server-status?auto'
5352
update_every : 5
54-
retries : 4
5553
```
5654
5755
Without configuration, module attempts to connect to `http://localhost/server-status?auto`

collectors/python.d.plugin/apache/apache.chart.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
# default module values (can be overridden per job in `config`)
99
# update_every = 2
1010
priority = 60000
11-
retries = 60
1211

1312
# default job configuration (overridden by python.d.plugin)
1413
# config = {'local': {

collectors/python.d.plugin/apache/apache.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,9 @@
2727
# If unset, the default for python.d.plugin is used.
2828
# priority: 60000
2929

30-
# retries sets the number of retries to be made in case of failures.
31-
# If unset, the default for python.d.plugin is used.
32-
# Attempts to restore the service are made once every update_every
33-
# and only if the module has collected values in the past.
34-
# retries: 60
30+
# penalty indicates whether to apply penalty to update_every in case of failures.
31+
# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes.
32+
# penalty: yes
3533

3634
# autodetection_retry sets the job re-check interval in seconds.
3735
# The job is not deleted if check fails.
@@ -58,7 +56,7 @@
5856
# # JOBs sharing a name are mutually exclusive
5957
# update_every: 1 # the JOB's data collection frequency
6058
# priority: 60000 # the JOB's order on the dashboard
61-
# retries: 60 # the JOB's number of restoration attempts
59+
# penalty: yes # the JOB's penalty
6260
# autodetection_retry: 0 # the JOB's re-check interval in seconds
6361
#
6462
# Additionally to the above, apache also supports the following:

collectors/python.d.plugin/beanstalk/beanstalk.chart.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
# default module values (can be overridden per job in `config`)
1616
# update_every = 2
1717
priority = 60000
18-
retries = 60
1918

2019
ORDER = ['cpu_usage', 'jobs_rate', 'connections_rate', 'commands_rate', 'current_tubes', 'current_jobs',
2120
'current_connections', 'binlog', 'uptime']

collectors/python.d.plugin/beanstalk/beanstalk.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,9 @@
2727
# If unset, the default for python.d.plugin is used.
2828
# priority: 60000
2929

30-
# retries sets the number of retries to be made in case of failures.
31-
# If unset, the default for python.d.plugin is used.
32-
# Attempts to restore the service are made once every update_every
33-
# and only if the module has collected values in the past.
34-
# retries: 60
30+
# penalty indicates whether to apply penalty to update_every in case of failures.
31+
# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes.
32+
# penalty: yes
3533

3634
# autodetection_retry sets the job re-check interval in seconds.
3735
# The job is not deleted if check fails.
@@ -68,7 +66,7 @@
6866
# # JOBs sharing a name are mutually exclusive
6967
# update_every: 1 # the JOB's data collection frequency
7068
# priority: 60000 # the JOB's order on the dashboard
71-
# retries: 60 # the JOB's number of restoration attempts
69+
# penalty: yes # the JOB's penalty
7270
# autodetection_retry: 0 # the JOB's re-check interval in seconds
7371
# chart_cleanup: 10 # the JOB's chart cleanup interval in iterations
7472
#

collectors/python.d.plugin/bind_rndc/bind_rndc.chart.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
from bases.FrameworkServices.SimpleService import SimpleService
1313

1414
priority = 60000
15-
retries = 60
1615
update_every = 30
1716

1817
ORDER = ['name_server_statistics', 'incoming_queries', 'outgoing_queries', 'named_stats_size']

collectors/python.d.plugin/bind_rndc/bind_rndc.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,9 @@
2727
# If unset, the default for python.d.plugin is used.
2828
# priority: 60000
2929

30-
# retries sets the number of retries to be made in case of failures.
31-
# If unset, the default for python.d.plugin is used.
32-
# Attempts to restore the service are made once every update_every
33-
# and only if the module has collected values in the past.
34-
# retries: 60
30+
# penalty indicates whether to apply penalty to update_every in case of failures.
31+
# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes.
32+
# penalty: yes
3533

3634
# autodetection_retry sets the job re-check interval in seconds.
3735
# The job is not deleted if check fails.
@@ -58,7 +56,7 @@
5856
# # JOBs sharing a name are mutually exclusive
5957
# update_every: 1 # the JOB's data collection frequency
6058
# priority: 60000 # the JOB's order on the dashboard
61-
# retries: 60 # the JOB's number of restoration attempts
59+
# penalty: yes # the JOB's penalty
6260
# autodetection_retry: 0 # the JOB's re-check interval in seconds
6361
#
6462
# Additionally to the above, bind_rndc also supports the following:

collectors/python.d.plugin/boinc/boinc.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,9 @@
2727
# If unset, the default for python.d.plugin is used.
2828
# priority: 60000
2929

30-
# retries sets the number of retries to be made in case of failures.
31-
# If unset, the default for python.d.plugin is used.
32-
# Attempts to restore the service are made once every update_every
33-
# and only if the module has collected values in the past.
34-
# retries: 60
30+
# penalty indicates whether to apply penalty to update_every in case of failures.
31+
# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes.
32+
# penalty: yes
3533

3634
# autodetection_retry sets the job re-check interval in seconds.
3735
# The job is not deleted if check fails.
@@ -58,7 +56,7 @@
5856
# # JOBs sharing a name are mutually exclusive
5957
# update_every: 1 # the JOB's data collection frequency
6058
# priority: 60000 # the JOB's order on the dashboard
61-
# retries: 60 # the JOB's number of restoration attempts
59+
# penalty: yes # the JOB's penalty
6260
# autodetection_retry: 0 # the JOB's re-check interval in seconds
6361
#
6462
# Additionally to the above, boinc also supports the following:

0 commit comments

Comments
 (0)