Skip to content

Commit

Permalink
Merge pull request #73 from ripienaar/72
Browse files Browse the repository at this point in the history
(#72) stop parsing registration related settings
  • Loading branch information
ripienaar authored Oct 22, 2020
2 parents 069701f + 8c3a7b9 commit ee0dc52
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
10 changes: 1 addition & 9 deletions lib/mcollective/config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,6 @@ def loadconfig(configfile) # rubocop:disable Metrics/MethodLength

begin
case key
when "registration"
@registration = val.capitalize
when "registration_collective"
@registration_collective = val
when "registerinterval"
@registerinterval = Integer(val)
when "registration_splay"
@registration_splay = Util.str_to_bool(val)
when "collectives"
@collectives = val.split(",").map(&:strip)
when "main_collective"
Expand Down Expand Up @@ -128,7 +120,7 @@ def loadconfig(configfile) # rubocop:disable Metrics/MethodLength
@default_batch_size = Integer(val)
when "default_batch_sleep_time"
@default_batch_sleep_time = Float(val)
when "topicprefix", "topicsep", "queueprefix", "rpchelptemplate", "helptemplatedir"
when "topicprefix", "topicsep", "queueprefix", "rpchelptemplate", "helptemplatedir", "registration_splay", "registerinterval", "registration_collective", "registration"
Log.warn("Use of deprecated '#{key}' option. This option is ignored and should be removed from '#{configfile}'")
else
raise("Unknown config parameter '#{key}'")
Expand Down
3 changes: 1 addition & 2 deletions spec/unit/mcollective/config_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,7 @@ module MCollective
PluginManager.stubs(:loadclass)
PluginManager.stubs("<<")

["registerinterval", "max_log_size", "direct_addressing_threshold", "publish_timeout",
"fact_cache_time", "ttl"].each do |key|
["max_log_size", "direct_addressing_threshold", "publish_timeout", "fact_cache_time", "ttl"].each do |key|
File.expects(:readlines).with("/nonexisting").returns(["#{key} = nan"])
File.expects(:exist?).with("/nonexisting").returns(true)

Expand Down

0 comments on commit ee0dc52

Please sign in to comment.