fluent-plugin-norikra 0.0.1 → 0.0.2

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: aa64957f7aa640bcb15c8bf4ac747e01617ecac0
4
- data.tar.gz: cc7f497f0fda85c0dd5b45fb70d5470d631d4317
3
+ metadata.gz: 9c5a70a877e6907756117c024c6b0f612ca3d2e7
4
+ data.tar.gz: 7e0eeb416adb35f3a9814908b5d1fa78409b9433
5
5
  SHA512:
6
- metadata.gz: 0e9ecc0d5c4eda53f6426e82991dcea65c9152f03b1a7846ad202428a315b1dcc91502460f4b405e6a57bd543457d177b6b24c87441846302e118f31e67fa422
7
- data.tar.gz: c81c72fba462086810c65f45dd2d29fd6fbb042d78185052ab0fd92fbec2b706f0a7f217c4b6aacd7f8e85ce4b2a1be1d19353c903b9ccb2ded4417de9eff85f
6
+ metadata.gz: 71749b60e7162ed99424c5e28085d0d8ce511b5bd844a20dab791e76fd7169e46f48ab4bfe7661131d2d8681d9e2e43660a02c6e96191d3f597d0964b96ea6c1
7
+ data.tar.gz: 61db6abf7f640eb87b0493c489da02577637f3780e071272410401dc8cb6692a25a629b62f3dfd14f7e6e9a87c9060245f0d33f72342e2a3c7244af69a8897d1
data/README.md CHANGED
@@ -19,8 +19,9 @@ At first, install JRuby and Norikra on your host if you are not using stand-alon
19
19
  * or other tools you want.
20
20
  2. swith to jruby, and install Norikra
21
21
  * `gem install norikra`
22
- 3. check norikra path
23
- * `which norikra`
22
+ 3. check and note `jruby` and `norikra-server`
23
+ * `which jruby`
24
+ * `which norikra-server`
24
25
  4. switch CRuby (with Fluentd), and install this plugin
25
26
  * `gem install fluent-plugin-norikra` (or use `fluent-gem`)
26
27
  5. configure Fluentd, and execute.
@@ -39,7 +40,9 @@ With built-in Norikra server, to receive tags like `event.foo` and send norikra'
39
40
  norikra localhost:26571 # this is default
40
41
  <server>
41
42
  execute yes
43
+ jruby /home/user/.rbenv/versions/jruby-1.7.4/bin/jruby
42
44
  path /home/user/.rbenv/versions/jruby-1.7.4/bin/norikra
45
+ opts -Xmx2g
43
46
  </server>
44
47
 
45
48
  remove_tag_prefix event
@@ -68,7 +71,9 @@ If you know some field's types of records, you can define types of these fields.
68
71
  norikra localhost:26571 # this is default
69
72
  <server>
70
73
  execute yes
74
+ jruby /home/user/.rbenv/versions/jruby-1.7.4/bin/jruby
71
75
  path /home/user/.rbenv/versions/jruby-1.7.4/bin/norikra
76
+ opts -Xmx2g
72
77
  </server>
73
78
 
74
79
  remove_tag_prefix event
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "fluent-plugin-norikra"
5
- spec.version = "0.0.1"
5
+ spec.version = "0.0.2"
6
6
  spec.authors = ["TAGOMORI Satoshi"]
7
7
  spec.email = ["tagomoris@gmail.com"]
8
8
  spec.description = %q{process events on fluentd with SQL like query, with built-in Norikra server if needed.}
@@ -72,7 +72,9 @@ module Fluent
72
72
  @config_targets[c.target] = c
73
73
  when 'server'
74
74
  @execute_server = Fluent::Config.bool_value(element['execute'])
75
+ @execute_jruby_path = element['jruby']
75
76
  @execute_server_path = element['path']
77
+ @execute_server_opts = element['opts']
76
78
  when 'event'
77
79
  event_section = element
78
80
  else
@@ -168,9 +170,13 @@ module Fluent
168
170
 
169
171
  def server_starter
170
172
  $log.info "starting Norikra server process #{@host}:#{@port}"
173
+ options = [@execute_server_path, 'start', '-H', @host, '-P', @port.to_s]
174
+ if @execute_server_opts
175
+ options.unshift(*@execute_server_opts.split(/ +/).map{|opt| '-J' + opt})
176
+ end
171
177
  @norikra_pid = fork do
172
178
  ENV.keys.select{|k| k =~ /^(RUBY|GEM|BUNDLE|RBENV|RVM|rvm)/}.each {|k| ENV.delete(k)}
173
- exec [@execute_server_path, 'norikra(fluentd)'], 'start', '-H', @host, '-P', @port.to_s
179
+ exec([@execute_jruby_path, 'norikra(fluentd)'], *options)
174
180
  end
175
181
  connecting = true
176
182
  $log.info "trying to confirm norikra server status..."
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-norikra
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - TAGOMORI Satoshi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-05-29 00:00:00.000000000 Z
11
+ date: 2013-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: norikra-client