sloe 0.8.0 → 0.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 61017b98561bc3dbd93b0d9076c1464af7b29c07
4
- data.tar.gz: c9d7d11560e9d05f3f1b90c677a83a3e4ee1f7ab
3
+ metadata.gz: 001727166f2e087f2cc852b57700208c18d68a25
4
+ data.tar.gz: 3eece20636d2c0f90d2cb84de939426b770e3910
5
5
  SHA512:
6
- metadata.gz: a198be45e3772a67e498e289a48698b5dda98782700361ea67a456c51bac8829f79472de3ecbc19732c4304852546395ce8d3569e61873e4872c12a0de3f4202
7
- data.tar.gz: 3db695158c963b0e3cc3a3323aa3fedf2941d0e5e04f945efd88892efe2f6a6385dcd16f45478ad209cb25a3dc39b36df045e62e99c97ddf38ed2b01a9c933f4
6
+ metadata.gz: dfa64b5a2750694009726ee23df60c46a444cd5c10680f3518a3e052e7e92459b5796d1694f9918b4213519e4365c1594aa59da6070c1cdb4b94c1c84f204837
7
+ data.tar.gz: 573fc86aec50f16a5a492dd20aede920369d6c3391a742fd79e62c91d8d42da96f96bcdb62ce5ff3a1e2f7a1154cc79d9e6307eb22226d347021e3f23a9e79de
data/lib/sloe/common.rb CHANGED
@@ -15,7 +15,8 @@ module Sloe
15
15
  @snmp_args = {
16
16
  :host => args[:target],
17
17
  :mib_dir => args[:mib_dir],
18
- :mib_modules => args[:mib_modules]
18
+ :mib_modules => args[:mib_modules],
19
+ :community => args[:community]
19
20
  }
20
21
  @snmp = SNMP::Manager.new(@snmp_args)
21
22
 
data/lib/sloe/ixia.rb CHANGED
@@ -10,8 +10,9 @@ module Sloe
10
10
  # @param traffic_duration [FixNum] duration that traffic should run for, in seconds
11
11
  # @param ixia_exe [String] path to shell script that executes TCL
12
12
  # @param clear_stats_after [FixNum] number of seconds to wait after configuring protocols before clearing stats
13
+ # @param ftp_path [String] path on Windows client FTP server to put Ixia traffic stat results. Take care to triple escape back slashes (yes... really!)
13
14
  # @return [Sloe::Ixia] object that can execute IxN config file
14
- def initialize(host: 'localhost', port: 8009, version: nil, ixncfg: nil, traffic_duration: 60, ixia_exe: '/root/ixos/bin/ixia_shell', clear_stats_after: 10)
15
+ def initialize(host: 'localhost', port: 8009, version: nil, ixncfg: nil, traffic_duration: 60, ixia_exe: '/root/ixos/bin/ixia_shell', clear_stats_after: 10, ftp_path: 'c:\\\\inetpub\\\\ftproot\\\\Reports')
15
16
  if ixncfg == nil
16
17
  fail ArgumentError, "missing mandatory IxNetwork script"
17
18
  end
@@ -25,6 +26,7 @@ module Sloe
25
26
  # base csv file name on IxN cfg file name
26
27
  @csv_file = File.basename(ixncfg).sub('.ixncfg','')
27
28
  @clear_stats_after = clear_stats_after
29
+ @ftp_path = ftp_path
28
30
 
29
31
  self
30
32
  end
@@ -183,13 +185,13 @@ module Sloe
183
185
  code = <<-TCL.gsub(/^\s+\|/,'')
184
186
  |set root [ixNet getRoot]
185
187
  |set stats $root/statistics
186
- |set csvWindowsPath "c:\\\\inetpub\\\\ftproot\\\\Reports"
188
+ |set csvWindowsPath "#@ftp_path"
187
189
  |ixNet setAttr $stats -enableCsvLogging "true"
188
190
  |ixNet setAttr $stats -csvFilePath $csvWindowsPath
189
191
  |ixNet setAttr $stats -pollInterval 3
190
192
  |ixNet commit
191
193
  |set li1 [list "Flow Statistics"]
192
- |set csvFileName "#{@csv_file}"
194
+ |set csvFileName "#@csv_file"
193
195
  |set opts [::ixTclNet::GetDefaultSnapshotSettings]
194
196
  |lset opts [lsearch $opts *Location*] [subst {Snapshot.View.Csv.Location: $csvWindowsPath}]
195
197
  |lset opts [lsearch $opts *GeneratingMode*] {Snapshot.View.Csv.GeneratingMode: kAppendCSVFile}
data/lib/sloe/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module Sloe
2
2
  # Current version
3
- VERSION = "0.8.0"
3
+ VERSION = "0.8.1"
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sloe
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.8.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Gethings
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-12 00:00:00.000000000 Z
11
+ date: 2015-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: snmp