logfile_interval 2.1.0 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 704912eefe0f7a801ed450cf303e2fa9ef7fe4d1
4
- data.tar.gz: 08108c223fd1d1cbf1069963289a360d5691b302
3
+ metadata.gz: 39928b6833d0ca8c626a982ce27793e46cd56e09
4
+ data.tar.gz: 5f439c3e89fdae163a11c2554e2ad0fb7db0bd9c
5
5
  SHA512:
6
- metadata.gz: 318f6ca2c18baf0d3155051d37d1de8a406d8b631bba9ffe50067e31230369178992bd089808899ba96e476f9a76b2373b14feb41eb31717446bee3e36bfe24a
7
- data.tar.gz: 88d9243b530a0bf9dbff4ec81dadefe05bce00c14d8e61841c04e6f096be7960b398ed37719ffa61421dff21c91f5c101bb9d6a10129f6743d955fff881d8ccc
6
+ metadata.gz: 1cf9f1135d847234001e625a8141e27bd930ea2e56d2f3806d4fe1b97e771adc2274fd54e6c2ef472144b823a33e9dd11b19a3b9d68e8615fe7c6e481b2a8e86
7
+ data.tar.gz: 5045943977e66bc7ac8a5cc24776edcb71dd15c2dd4b85914025406a7bc62094d0b7f82a6cba85f7c3e2212345b44b5b70323ef36d5db4abf3d1007c082d7238
data/README.md CHANGED
@@ -38,11 +38,9 @@ class AccessLog < LogfileInterval::LineParser::Base
38
38
  end
39
39
  end
40
40
 
41
- parser = AccessLog
42
- file = LogfileInterval::Logfile.new('path_to_logfile', parser)
43
- parsed_line_enum = file.each_parsed_line
41
+ logfile = LogfileInterval::Logfile.new('path_to_logfile', AccessLog)
44
42
 
45
- builder = LogfileInterval::IntervalBuilder.new(parsed_line_enum, parser, 300)
43
+ builder = LogfileInterval::IntervalBuilder.new(logfile, AccessLog, 5*60)
46
44
  builder.each_interval do |interval|
47
45
  next unless interval.size > 0
48
46
 
data/bin/readme.rb CHANGED
@@ -21,14 +21,13 @@ class AccessLogParsedLine < LogfileInterval::ParsedLine::Base
21
21
  end
22
22
 
23
23
  path = ENV['ACCESS_LOG_PATH']
24
- file = LogfileInterval::Logfile.new(path, AccessLogParsedLine)
25
- unless file.exist?
24
+ logfile = LogfileInterval::Logfile.new(path, AccessLogParsedLine)
25
+ unless logfile.exist?
26
26
  puts "#{path} is not found"
27
27
  exit 1
28
28
  end
29
- parsed_line_enum = file.each_parsed_line
30
29
 
31
- builder = LogfileInterval::IntervalBuilder.new(parsed_line_enum, AccessLogParsedLine, 300)
30
+ builder = LogfileInterval::IntervalBuilder.new(logfile, AccessLogParsedLine, 5*60)
32
31
  builder.each_interval do |interval|
33
32
  next unless interval.size > 0
34
33
 
@@ -1,3 +1,3 @@
1
1
  module LogfileInterval
2
- VERSION = "2.1.0"
2
+ VERSION = "2.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logfile_interval
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philippe Le Rohellec
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-08 00:00:00.000000000 Z
11
+ date: 2014-06-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler