apache-loggen 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -117,7 +117,7 @@ class MyGen < LogGenerator::Apache
117
117
  if config[:json] then
118
118
  return record.to_json + "\n"
119
119
  else
120
- return %[#{record['host']} - #{record['user']} [#{Time.now.strftime('%d/%b/%Y:%H:%M:%S %z')}] "#{record['method']} #{record['path']} HTTP/1.1" #{record['code
120
+ return %[#{record['host']} - #{record['user']} [#{Time.now.strftime('%d/%b/%Y:%H:%M:%S %z')}] "#{record['method']} #{record['path']} HTTP/1.1" #{record['code']} #{record['size']} "#{record['referer']}" "#{record['agent']}" #{record['process_time']}\n]
121
121
  end
122
122
  end
123
123
  end
@@ -147,6 +147,7 @@ end
147
147
 
148
148
 
149
149
  # 履歴
150
+ - 0.0.3 Rate=1くらいの低速度の場合、Flushが走らないので明示的にFlushするようにした。
150
151
  - 0.0.2 RubyGemsに登録。コマンドを用意した。クラスの再利用ができるようにした。
151
152
  - 0.0.1 はじめてのリリース
152
153
 
@@ -11,8 +11,9 @@ Gem::Specification.new do |gem|
11
11
  gem.description = %q{dummy apache-log generator}
12
12
  gem.summary = %q{dummy apache-log generator}
13
13
  gem.homepage = "https://github.com/tamtam180/apache_log_gen"
14
+ gem.license = 'Apache 2.0'
14
15
 
15
- gem.files = `git ls-files`.split($/)
16
+ gem.files = `git ls-files`.split($/) - %w[.gitignore]
16
17
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
17
18
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
18
19
  gem.require_paths = ["lib"]
@@ -296,6 +296,9 @@ module LogGenerator
296
296
  def write(str)
297
297
  return @io.write(str)
298
298
  end
299
+ def flush()
300
+ @io.flush()
301
+ end
299
302
  def close()
300
303
  if @filename != nil && @io != nil && !@io.closed? then
301
304
  @io.close
@@ -336,6 +339,7 @@ module LogGenerator
336
339
 
337
340
  # 出力
338
341
  writer.write(record)
342
+ writer.flush()
339
343
 
340
344
  not (config[:limit] > 0 && config[:limit] <= context[:total_count])
341
345
 
@@ -1,3 +1,3 @@
1
1
  module LogGenerator
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apache-loggen
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-11-15 00:00:00.000000000 Z
12
+ date: 2012-12-06 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: dummy apache-log generator
15
15
  email:
@@ -19,7 +19,6 @@ executables:
19
19
  extensions: []
20
20
  extra_rdoc_files: []
21
21
  files:
22
- - .gitignore
23
22
  - Gemfile
24
23
  - LICENSE.txt
25
24
  - README.md
@@ -31,7 +30,8 @@ files:
31
30
  - lib/apache-loggen/base.rb
32
31
  - lib/apache-loggen/version.rb
33
32
  homepage: https://github.com/tamtam180/apache_log_gen
34
- licenses: []
33
+ licenses:
34
+ - Apache 2.0
35
35
  post_install_message:
36
36
  rdoc_options: []
37
37
  require_paths:
data/.gitignore DELETED
@@ -1,17 +0,0 @@
1
- *.gem
2
- *.rbc
3
- .bundle
4
- .config
5
- .yardoc
6
- Gemfile.lock
7
- InstalledFiles
8
- _yardoc
9
- coverage
10
- doc/
11
- lib/bundler/man
12
- pkg
13
- rdoc
14
- spec/reports
15
- test/tmp
16
- test/version_tmp
17
- tmp