cisco_node_utils 1.0.1 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (114) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +4 -0
  3. data/.rubocop.yml +81 -1
  4. data/.travis.yml +9 -0
  5. data/CHANGELOG.md +72 -6
  6. data/CONTRIBUTING.md +32 -7
  7. data/README.md +70 -7
  8. data/Rakefile +17 -0
  9. data/bin/check_metric_limits.rb +109 -0
  10. data/bin/git/hooks/commit-msg/enforce_style +81 -0
  11. data/bin/git/hooks/hook_lib +108 -0
  12. data/bin/git/hooks/hooks-wrapper +38 -0
  13. data/bin/git/hooks/post-flow-hotfix-start/update-version +24 -0
  14. data/bin/git/hooks/post-flow-release-finish/update-version +29 -0
  15. data/bin/git/hooks/post-flow-release-start/update-version +19 -0
  16. data/bin/git/hooks/post-merge/update-hooks +6 -0
  17. data/bin/git/hooks/post-rewrite/update-hooks +6 -0
  18. data/bin/git/hooks/pre-commit/rubocop +20 -0
  19. data/bin/git/hooks/pre-commit/validate-diffs +31 -0
  20. data/bin/git/hooks/pre-push/check-changelog +24 -0
  21. data/bin/git/hooks/pre-push/rubocop +7 -0
  22. data/bin/git/update-hooks +65 -0
  23. data/cisco_node_utils.gemspec +9 -3
  24. data/docs/README-develop-best-practices.md +404 -0
  25. data/docs/README-develop-node-utils-APIs.md +215 -365
  26. data/docs/README-maintainers.md +33 -3
  27. data/docs/template-router.rb +89 -91
  28. data/docs/template-test_router.rb +52 -55
  29. data/lib/.rubocop.yml +18 -0
  30. data/lib/cisco_node_utils.rb +2 -19
  31. data/lib/cisco_node_utils/README_YAML.md +1 -9
  32. data/lib/cisco_node_utils/bgp.rb +664 -0
  33. data/lib/cisco_node_utils/bgp_af.rb +530 -0
  34. data/lib/cisco_node_utils/bgp_neighbor.rb +425 -0
  35. data/lib/cisco_node_utils/bgp_neighbor_af.rb +709 -0
  36. data/lib/cisco_node_utils/cisco_cmn_utils.rb +59 -25
  37. data/lib/cisco_node_utils/command_reference.rb +72 -74
  38. data/lib/cisco_node_utils/command_reference_common.yaml +174 -9
  39. data/lib/cisco_node_utils/command_reference_common_bgp.yaml +535 -0
  40. data/lib/cisco_node_utils/command_reference_n7k.yaml +4 -0
  41. data/lib/cisco_node_utils/command_reference_n9k.yaml +0 -9
  42. data/lib/cisco_node_utils/configparser_lib.rb +152 -147
  43. data/lib/cisco_node_utils/dns_domain.rb +79 -0
  44. data/lib/cisco_node_utils/domain_name.rb +71 -0
  45. data/lib/cisco_node_utils/interface.rb +167 -161
  46. data/lib/cisco_node_utils/interface_ospf.rb +78 -81
  47. data/lib/cisco_node_utils/name_server.rb +64 -0
  48. data/lib/cisco_node_utils/node.rb +154 -198
  49. data/lib/cisco_node_utils/node_util.rb +61 -0
  50. data/lib/cisco_node_utils/ntp_config.rb +65 -0
  51. data/lib/cisco_node_utils/ntp_server.rb +76 -0
  52. data/lib/cisco_node_utils/platform.rb +174 -165
  53. data/lib/cisco_node_utils/radius_global.rb +146 -0
  54. data/lib/cisco_node_utils/radius_server.rb +295 -0
  55. data/lib/cisco_node_utils/router_ospf.rb +59 -63
  56. data/lib/cisco_node_utils/router_ospf_vrf.rb +226 -210
  57. data/lib/cisco_node_utils/snmpcommunity.rb +52 -58
  58. data/lib/cisco_node_utils/snmpgroup.rb +22 -23
  59. data/lib/cisco_node_utils/snmpserver.rb +99 -103
  60. data/lib/cisco_node_utils/snmpuser.rb +294 -274
  61. data/lib/cisco_node_utils/syslog_server.rb +92 -0
  62. data/lib/cisco_node_utils/syslog_settings.rb +69 -0
  63. data/lib/cisco_node_utils/tacacs_server.rb +137 -133
  64. data/lib/cisco_node_utils/tacacs_server_host.rb +84 -87
  65. data/lib/cisco_node_utils/version.rb +2 -1
  66. data/lib/cisco_node_utils/vlan.rb +28 -31
  67. data/lib/cisco_node_utils/vrf.rb +80 -0
  68. data/lib/cisco_node_utils/vtp.rb +100 -97
  69. data/lib/cisco_node_utils/yum.rb +15 -17
  70. data/tests/.rubocop.yml +15 -0
  71. data/tests/basetest.rb +81 -36
  72. data/tests/ciscotest.rb +38 -78
  73. data/{lib/cisco_node_utils → tests}/platform_info.rb +12 -8
  74. data/{lib/cisco_node_utils → tests}/platform_info.yaml +1 -1
  75. data/tests/test_bgp_af.rb +920 -0
  76. data/tests/test_bgp_neighbor.rb +403 -0
  77. data/tests/test_bgp_neighbor_af.rb +589 -0
  78. data/tests/test_command_config.rb +65 -62
  79. data/tests/test_command_reference.rb +31 -45
  80. data/tests/test_dns_domain.rb +113 -0
  81. data/tests/test_domain_name.rb +86 -0
  82. data/tests/test_interface.rb +424 -548
  83. data/tests/test_interface_ospf.rb +248 -432
  84. data/tests/test_interface_svi.rb +56 -79
  85. data/tests/test_interface_switchport.rb +196 -272
  86. data/tests/test_name_server.rb +85 -0
  87. data/tests/test_node.rb +7 -6
  88. data/tests/test_node_ext.rb +133 -186
  89. data/tests/test_ntp_config.rb +49 -0
  90. data/tests/test_ntp_server.rb +74 -0
  91. data/tests/test_platform.rb +58 -37
  92. data/tests/test_radius_global.rb +78 -0
  93. data/tests/test_radius_server.rb +185 -0
  94. data/tests/test_router_bgp.rb +838 -0
  95. data/tests/test_router_ospf.rb +49 -80
  96. data/tests/test_router_ospf_vrf.rb +274 -392
  97. data/tests/test_snmpcommunity.rb +128 -172
  98. data/tests/test_snmpgroup.rb +12 -14
  99. data/tests/test_snmpserver.rb +160 -189
  100. data/tests/test_snmpuser.rb +568 -717
  101. data/tests/test_syslog_server.rb +88 -0
  102. data/tests/test_syslog_settings.rb +54 -0
  103. data/tests/test_tacacs_server.rb +113 -148
  104. data/tests/test_tacacs_server_host.rb +108 -161
  105. data/tests/test_vlan.rb +63 -79
  106. data/tests/test_vrf.rb +92 -0
  107. data/tests/test_vtp.rb +108 -126
  108. data/tests/test_yum.rb +47 -41
  109. metadata +92 -56
  110. data/.rubocop_todo.yml +0 -293
  111. data/docs/.rubocop.yml +0 -13
  112. data/docs/template-feature.rb +0 -45
  113. data/docs/template-test_feature.rb +0 -51
  114. data/tests/test_all_cisco.rb +0 -46
@@ -1,6 +1,3 @@
1
- #
2
- # NXAPI implementation of RouterOspfVrf class
3
- #
4
1
  # Mike Wiebe, March 2015
5
2
  #
6
3
  # Copyright (c) 2015 Cisco and/or its affiliates.
@@ -17,254 +14,273 @@
17
14
  # See the License for the specific language governing permissions and
18
15
  # limitations under the License.
19
16
 
20
- require File.join(File.dirname(__FILE__), 'node')
21
- require File.join(File.dirname(__FILE__), 'router_ospf')
17
+ require_relative 'node_util'
18
+ require_relative 'router_ospf'
22
19
 
23
20
  module Cisco
24
- class RouterOspfVrf
25
- attr_reader :name, :parent
26
-
27
- OSPF_AUTO_COST = {
28
- :mbps => "Mbps",
29
- :gbps => "Gbps",
30
- }
31
-
32
- OSPF_LOG_ADJACENCY = {
33
- :none => "none",
34
- :log => "",
35
- :detail => "detail",
36
- }
37
-
38
- @@node = Cisco::Node.instance
39
-
40
- def initialize(router, name, instantiate=true)
41
- raise TypeError if router.nil?
42
- raise TypeError if name.nil?
43
- raise ArgumentError unless router.length > 0
44
- raise ArgumentError unless name.length > 0
45
- @router = router
46
- @name = name
47
- @parent = {}
48
- @get_args = @set_args = (@name == "default") ?
49
- { :name => @router } : { :name => @router, :vrf => @name }
50
-
51
- create if instantiate
52
- end
21
+ # RouterOspfVrf - node utility class for per-VRF OSPF config management
22
+ class RouterOspfVrf < NodeUtil
23
+ attr_reader :name, :parent
24
+
25
+ OSPF_AUTO_COST = {
26
+ mbps: 'Mbps',
27
+ gbps: 'Gbps',
28
+ }
29
+
30
+ OSPF_LOG_ADJACENCY = {
31
+ none: 'none',
32
+ log: '',
33
+ detail: 'detail',
34
+ }
35
+
36
+ def initialize(router, name, instantiate=true)
37
+ fail TypeError if router.nil?
38
+ fail TypeError if name.nil?
39
+ fail ArgumentError unless router.length > 0
40
+ fail ArgumentError unless name.length > 0
41
+ @router = router
42
+ @name = name
43
+ @parent = {}
44
+ if @name == 'default'
45
+ @get_args = @set_args = { name: @router }
46
+ else
47
+ @get_args = @set_args = { name: @router, vrf: @name }
48
+ end
49
+
50
+ create if instantiate
51
+ end
53
52
 
54
- # Create a hash of all router ospf vrf instances
55
- def RouterOspfVrf.vrfs
56
- hash_final = {}
57
- RouterOspf.routers.each do |instance|
58
- name = instance[0]
59
- vrf_ids = @@node.config_get("ospf", "vrf", { :name => name })
60
- hash_tmp = { name =>
61
- { 'default' => RouterOspfVrf.new(name, 'default', false) } }
62
- unless vrf_ids.nil?
63
- vrf_ids.each do |vrf|
64
- hash_tmp[name][vrf] = RouterOspfVrf.new(name, vrf, false)
53
+ # Create a hash of all router ospf vrf instances
54
+ def self.vrfs
55
+ hash_final = {}
56
+ RouterOspf.routers.each do |instance|
57
+ name = instance[0]
58
+ vrf_ids = config_get('ospf', 'vrf', name: name)
59
+ hash_tmp = { name =>
60
+ { 'default' => RouterOspfVrf.new(name, 'default', false) } }
61
+ unless vrf_ids.nil?
62
+ vrf_ids.each do |vrf|
63
+ hash_tmp[name][vrf] = RouterOspfVrf.new(name, vrf, false)
64
+ end
65
65
  end
66
+ hash_final.merge!(hash_tmp)
66
67
  end
67
- hash_final.merge!(hash_tmp)
68
+ hash_final
68
69
  end
69
- hash_final
70
- end
71
70
 
72
- # Create one router ospf vrf instance
73
- def create
74
- @parent = RouterOspf.new(@router)
75
- @@node.config_set("ospf", "vrf", { :name => @router,
76
- :state => "",
77
- :vrf => @name }) if
78
- @name != "default"
79
- end
71
+ # Create one router ospf vrf instance
72
+ def create
73
+ @parent = RouterOspf.new(@router)
74
+ config_set('ospf', 'vrf',
75
+ name: @router, state: '', vrf: @name) if @name != 'default'
76
+ end
80
77
 
81
- # Destroy one router ospf vrf instance
82
- def destroy
83
- raise RuntimeError if @name == "default"
84
- @@node.config_set("ospf", "vrf", { :name => @router,
85
- :state => "no",
86
- :vrf => @name })
87
- end
78
+ # Destroy one router ospf vrf instance
79
+ def destroy
80
+ fail RuntimeError if @name == 'default'
81
+ config_set('ospf', 'vrf', name: @router, state: 'no', vrf: @name)
82
+ end
88
83
 
89
- # Helper method to delete @set_args hash keys
90
- def set_args_keys_delete(list)
91
- list.each { |key| @set_args.delete(key) }
92
- end
84
+ # Helper method to delete @set_args hash keys
85
+ def delete_set_args_keys(list)
86
+ list.each { |key| @set_args.delete(key) }
87
+ end
93
88
 
94
- def auto_cost
95
- match = @@node.config_get("ospf", "auto_cost", @get_args)
96
- return default_auto_cost if match.nil?
97
- # Multiple matches are possible but the first match is used.
98
- # This can be removed when rally defect DE3614 is resolved.
99
- match[0].last.nil? ?
100
- [match[0].first.to_i, OSPF_AUTO_COST[:mbps]] :
101
- [match[0].first.to_i, match[0].last]
102
- end
89
+ def auto_cost
90
+ match = config_get('ospf', 'auto_cost', @get_args)
91
+ return default_auto_cost if match.nil?
92
+ # Multiple matches are possible but the first match is used.
93
+ # This can be removed when rally defect DE3614 is resolved.
94
+ if match[0].last.nil?
95
+ [match[0].first.to_i, OSPF_AUTO_COST[:mbps]]
96
+ else
97
+ [match[0].first.to_i, match[0].last]
98
+ end
99
+ end
103
100
 
104
- def auto_cost_set(cost, type)
105
- @set_args[:cost], @set_args[:type] = cost, OSPF_AUTO_COST[type]
106
- @@node.config_set("ospf", "auto_cost", @set_args)
107
- set_args_keys_delete([:cost, :type])
108
- end
101
+ def auto_cost_set(cost, type)
102
+ @set_args[:cost] = cost
103
+ @set_args[:type] = OSPF_AUTO_COST[type]
104
+ config_set('ospf', 'auto_cost', @set_args)
105
+ delete_set_args_keys([:cost, :type])
106
+ end
109
107
 
110
- def default_auto_cost
111
- @@node.config_get_default("ospf", "auto_cost")
112
- end
108
+ def default_auto_cost
109
+ config_get_default('ospf', 'auto_cost')
110
+ end
113
111
 
114
- def default_metric
115
- match = @@node.config_get("ospf", "default_metric", @get_args)
116
- match.nil? ? default_default_metric : match.first.to_i
117
- end
112
+ def default_metric
113
+ match = config_get('ospf', 'default_metric', @get_args)
114
+ match.nil? ? default_default_metric : match.first.to_i
115
+ end
118
116
 
119
- def default_metric=(metric)
120
- if metric == default_default_metric
121
- @set_args[:state], @set_args[:metric] = "no", ""
122
- else
123
- @set_args[:state], @set_args[:metric] = "", metric
117
+ def default_metric=(metric)
118
+ if metric == default_default_metric
119
+ @set_args[:state] = 'no'
120
+ @set_args[:metric] = ''
121
+ else
122
+ @set_args[:state] = ''
123
+ @set_args[:metric] = metric
124
+ end
125
+ config_set('ospf', 'default_metric', @set_args)
126
+ delete_set_args_keys([:state, :metric])
124
127
  end
125
- @@node.config_set("ospf", "default_metric", @set_args)
126
- set_args_keys_delete([:state, :metric])
127
- end
128
128
 
129
- def default_default_metric
130
- @@node.config_get_default("ospf", "default_metric")
131
- end
129
+ def default_default_metric
130
+ config_get_default('ospf', 'default_metric')
131
+ end
132
132
 
133
- def log_adjacency
134
- match = @@node.config_get("ospf", "log_adjacency", @get_args)
135
- return default_log_adjacency if match.nil?
136
- # Multiple matches are possible but the first match is used.
137
- # This can be removed when rally defect DE3614 is resolved.
138
- match[0].flatten.last.nil? ? :log : :detail
139
- end
133
+ def log_adjacency
134
+ match = config_get('ospf', 'log_adjacency', @get_args)
135
+ return default_log_adjacency if match.nil?
136
+ # Multiple matches are possible but the first match is used.
137
+ # This can be removed when rally defect DE3614 is resolved.
138
+ match[0].flatten.last.nil? ? :log : :detail
139
+ end
140
140
 
141
- def log_adjacency=(type)
142
- case type
143
- when :none
144
- @set_args[:state], @set_args[:type] = "no", ""
145
- when :log, :detail
146
- @set_args[:state], @set_args[:type] = "", OSPF_LOG_ADJACENCY[type]
141
+ def log_adjacency=(type)
142
+ case type
143
+ when :none
144
+ @set_args[:state] = 'no'
145
+ @set_args[:type] = ''
146
+ when :log, :detail
147
+ @set_args[:state] = ''
148
+ @set_args[:type] = OSPF_LOG_ADJACENCY[type]
149
+ end
150
+ config_set('ospf', 'log_adjacency', @set_args)
151
+ delete_set_args_keys([:state, :type])
147
152
  end
148
- @@node.config_set("ospf", "log_adjacency", @set_args)
149
- set_args_keys_delete([:state, :type])
150
- end
151
153
 
152
- def default_log_adjacency
153
- @@node.config_get_default("ospf", "log_adjacency")
154
- end
154
+ def default_log_adjacency
155
+ config_get_default('ospf', 'log_adjacency')
156
+ end
155
157
 
156
- def router_id
157
- match = @@node.config_get("ospf", "router_id", @get_args)
158
- match.nil? ? default_router_id : match.first
159
- end
158
+ def router_id
159
+ match = config_get('ospf', 'router_id', @get_args)
160
+ match.nil? ? default_router_id : match.first
161
+ end
160
162
 
161
- def router_id=(router_id)
162
- router_id == default_router_id ?
163
- (@set_args[:state], @set_args[:router_id] = "no", "") :
164
- (@set_args[:state], @set_args[:router_id] = "", router_id)
163
+ def router_id=(router_id)
164
+ if router_id == default_router_id
165
+ @set_args[:state] = 'no'
166
+ @set_args[:router_id] = ''
167
+ else
168
+ @set_args[:state] = ''
169
+ @set_args[:router_id] = router_id
170
+ end
165
171
 
166
- @@node.config_set("ospf", "router_id", @set_args)
167
- set_args_keys_delete([:state, :router_id])
168
- end
172
+ config_set('ospf', 'router_id', @set_args)
173
+ delete_set_args_keys([:state, :router_id])
174
+ end
169
175
 
170
- def default_router_id
171
- @@node.config_get_default("ospf", "router_id")
172
- end
176
+ def default_router_id
177
+ config_get_default('ospf', 'router_id')
178
+ end
173
179
 
174
- def timer_throttle_lsa
175
- match = @@node.config_get("ospf", "timer_throttle_lsa", @get_args)
176
- (match.nil? or match.first.nil?) ? default_timer_throttle_lsa :
177
- match.first.collect(&:to_i)
178
- end
180
+ def timer_throttle_lsa
181
+ match = config_get('ospf', 'timer_throttle_lsa', @get_args)
182
+ if match.nil? || match.first.nil?
183
+ default_timer_throttle_lsa
184
+ else
185
+ match.first.collect(&:to_i)
186
+ end
187
+ end
179
188
 
180
- def timer_throttle_lsa_start
181
- start, hold, max = timer_throttle_lsa
182
- return default_timer_throttle_lsa_start if start.nil?
183
- start
184
- end
189
+ def timer_throttle_lsa_start
190
+ start, _hold, _max = timer_throttle_lsa
191
+ return default_timer_throttle_lsa_start if start.nil?
192
+ start
193
+ end
185
194
 
186
- def timer_throttle_lsa_hold
187
- start, hold, max = timer_throttle_lsa
188
- return default_timer_throttle_lsa_hold if hold.nil?
189
- hold
190
- end
195
+ def timer_throttle_lsa_hold
196
+ _start, hold, _max = timer_throttle_lsa
197
+ return default_timer_throttle_lsa_hold if hold.nil?
198
+ hold
199
+ end
191
200
 
192
- def timer_throttle_lsa_max
193
- start, hold, max = timer_throttle_lsa
194
- return default_timer_throttle_lsa_max if max.nil?
195
- max
196
- end
201
+ def timer_throttle_lsa_max
202
+ _start, _hold, max = timer_throttle_lsa
203
+ return default_timer_throttle_lsa_max if max.nil?
204
+ max
205
+ end
197
206
 
198
- def timer_throttle_lsa_set(start, hold, max)
199
- @set_args[:start], @set_args[:hold], @set_args[:max] = start, hold, max
200
- @@node.config_set("ospf", "timer_throttle_lsa", @set_args)
201
- set_args_keys_delete([:start, :hold, :max])
202
- end
207
+ def timer_throttle_lsa_set(start, hold, max)
208
+ @set_args[:start] = start
209
+ @set_args[:hold] = hold
210
+ @set_args[:max] = max
211
+ config_set('ospf', 'timer_throttle_lsa', @set_args)
212
+ delete_set_args_keys([:start, :hold, :max])
213
+ end
203
214
 
204
- def default_timer_throttle_lsa
205
- [default_timer_throttle_lsa_start,
206
- default_timer_throttle_lsa_hold,
207
- default_timer_throttle_lsa_max]
208
- end
215
+ def default_timer_throttle_lsa
216
+ [default_timer_throttle_lsa_start,
217
+ default_timer_throttle_lsa_hold,
218
+ default_timer_throttle_lsa_max]
219
+ end
209
220
 
210
- def default_timer_throttle_lsa_start
211
- @@node.config_get_default("ospf", "timer_throttle_lsa_start")
212
- end
221
+ def default_timer_throttle_lsa_start
222
+ config_get_default('ospf', 'timer_throttle_lsa_start')
223
+ end
213
224
 
214
- def default_timer_throttle_lsa_hold
215
- @@node.config_get_default("ospf", "timer_throttle_lsa_hold")
216
- end
225
+ def default_timer_throttle_lsa_hold
226
+ config_get_default('ospf', 'timer_throttle_lsa_hold')
227
+ end
217
228
 
218
- def default_timer_throttle_lsa_max
219
- @@node.config_get_default("ospf", "timer_throttle_lsa_max")
220
- end
229
+ def default_timer_throttle_lsa_max
230
+ config_get_default('ospf', 'timer_throttle_lsa_max')
231
+ end
221
232
 
222
- def timer_throttle_spf
223
- match = @@node.config_get("ospf", "timer_throttle_spf", @get_args)
224
- (match.nil? or match.first.nil?) ? default_timer_throttle_spf :
225
- match.first.collect(&:to_i)
226
- end
233
+ def timer_throttle_spf
234
+ match = config_get('ospf', 'timer_throttle_spf', @get_args)
235
+ if match.nil? || match.first.nil?
236
+ default_timer_throttle_spf
237
+ else
238
+ match.first.collect(&:to_i)
239
+ end
240
+ end
227
241
 
228
- def timer_throttle_spf_start
229
- start, hold, max = timer_throttle_spf
230
- return default_timer_throttle_spf_start if start.nil?
231
- start
232
- end
242
+ def timer_throttle_spf_start
243
+ start, _hold, _max = timer_throttle_spf
244
+ return default_timer_throttle_spf_start if start.nil?
245
+ start
246
+ end
233
247
 
234
- def timer_throttle_spf_hold
235
- start, hold, max = timer_throttle_spf
236
- return default_timer_throttle_spf_hold if hold.nil?
237
- hold
238
- end
248
+ def timer_throttle_spf_hold
249
+ _start, hold, _max = timer_throttle_spf
250
+ return default_timer_throttle_spf_hold if hold.nil?
251
+ hold
252
+ end
239
253
 
240
- def timer_throttle_spf_max
241
- start, hold, max = timer_throttle_spf
242
- return default_timer_throttle_spf_max if max.nil?
243
- max
244
- end
254
+ def timer_throttle_spf_max
255
+ _start, _hold, max = timer_throttle_spf
256
+ return default_timer_throttle_spf_max if max.nil?
257
+ max
258
+ end
245
259
 
246
- def timer_throttle_spf_set(start, hold, max)
247
- @set_args[:start], @set_args[:hold], @set_args[:max] = start, hold, max
248
- @@node.config_set("ospf", "timer_throttle_spf", @set_args)
249
- set_args_keys_delete([:start, :hold, :max])
250
- end
260
+ def timer_throttle_spf_set(start, hold, max)
261
+ @set_args[:start] = start
262
+ @set_args[:hold] = hold
263
+ @set_args[:max] = max
264
+ config_set('ospf', 'timer_throttle_spf', @set_args)
265
+ delete_set_args_keys([:start, :hold, :max])
266
+ end
251
267
 
252
- def default_timer_throttle_spf
253
- [default_timer_throttle_spf_start,
254
- default_timer_throttle_spf_hold,
255
- default_timer_throttle_spf_max]
256
- end
268
+ def default_timer_throttle_spf
269
+ [default_timer_throttle_spf_start,
270
+ default_timer_throttle_spf_hold,
271
+ default_timer_throttle_spf_max]
272
+ end
257
273
 
258
- def default_timer_throttle_spf_start
259
- @@node.config_get_default("ospf", "timer_throttle_spf_start")
260
- end
274
+ def default_timer_throttle_spf_start
275
+ config_get_default('ospf', 'timer_throttle_spf_start')
276
+ end
261
277
 
262
- def default_timer_throttle_spf_hold
263
- @@node.config_get_default("ospf", "timer_throttle_spf_hold")
264
- end
278
+ def default_timer_throttle_spf_hold
279
+ config_get_default('ospf', 'timer_throttle_spf_hold')
280
+ end
265
281
 
266
- def default_timer_throttle_spf_max
267
- @@node.config_get_default("ospf", "timer_throttle_spf_max")
282
+ def default_timer_throttle_spf_max
283
+ config_get_default('ospf', 'timer_throttle_spf_max')
284
+ end
268
285
  end
269
286
  end
270
- end