Skip to content

Commit

Permalink
Add all producers to updater when using prdcr_listen if "producers" i…
Browse files Browse the repository at this point in the history
…s not defined in the updater dictionary
  • Loading branch information
nick-enoent committed Jan 17, 2025
1 parent 4f105db commit d29029a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ldms/man/ldmsd_yaml_parser.man
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ The permissions to modify the producer in the future. String of octal number or
.TP
.BR [producers]
.br
Optional regular expression matching zero or more producers to add to this updater. If omitted, all producers in the parent dictionary will be added to this updater.
Optional regular expression matching zero or more producers to add to this updater. If omitted with prdcr_listen, all producers will be added to the updater.
.TP
.BR [sets]
.br
Expand Down
6 changes: 5 additions & 1 deletion ldms/python/ldmsd/parser_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,11 @@ def build_updaters(self, config):
if type(prod_regex) is not str and prod_regex is not None:
raise TypeError(f'Error: Configuration error in keyword "producers". Only regex string values are valid.')
if prod_regex is None:
prod_regex = expand_names(prod['endpoints'])
if 'endpoints' in prod:
prod_regex = expand_names(prod['endpoints'])
else:
# When using producer listen, if "producers" is not specified in the updaters dictionary, all producers will be added
prod_regex = '.*'
updtr = {
'name' : updtr_name,
'interval' : check_intrvl_str(updtr_spec['interval']),
Expand Down

0 comments on commit d29029a

Please sign in to comment.