mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 22:57:16 -04:00
- delay require until the register method
This commit is contained in:
parent
fc4bb3af9e
commit
c2ea10ed5d
1 changed files with 7 additions and 2 deletions
|
@ -7,8 +7,10 @@ Dir["/home/jls/build/elasticsearch-0.15.0//lib/*.jar"].each do |jar|
|
|||
require jar
|
||||
end
|
||||
|
||||
gem "jruby-elasticsearch", ">= 0.0.3"
|
||||
require "jruby-elasticsearch"
|
||||
jarpath = File.join(File.dirname(__FILE__), "../../../vendor/**/*.jar")
|
||||
Dir[jarpath].each do |jar|
|
||||
require jar
|
||||
end
|
||||
|
||||
|
||||
class LogStash::Outputs::Elasticsearch < LogStash::Outputs::Base
|
||||
|
@ -22,6 +24,9 @@ class LogStash::Outputs::Elasticsearch < LogStash::Outputs::Base
|
|||
|
||||
public
|
||||
def register
|
||||
gem "jruby-elasticsearch", ">= 0.0.3"
|
||||
require "jruby-elasticsearch"
|
||||
|
||||
@pending = []
|
||||
@callback = self.method(:receive_native)
|
||||
# TODO(sissel): host/port? etc?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue