elasticsearch.rake revision daa05c1ca31894d2bcba80bea773829908efbef8
require 'elasticsearch/rails/tasks/import'
namespace :elasticsearch do
desc 'Wipe the Ontology Index from ElasticSearch'
task :wipe => [:environment] do
end
task :start_cluster do
ENV['TEST_CLUSTER_NODES'] ||= '1'
env_timeout = ENV['TEST_CLUSTER_TIMEOUT']
timeout = env_timeout && !env_timeout.empty? ? env_timeout.to_i : 120
Elasticsearch::Extensions::Test::Cluster.start timeout: timeout
end
end