logstash-plugins / logstash-output-elasticsearch_java

Java API Implementation of Elasticsearch Output
Apache License 2.0
0 stars 8 forks source link

network_host is not configured in tests #6

Open talevy opened 9 years ago

talevy commented 9 years ago

Currently, the network_host parameters is set to :required, but some tests do not set this.

spec ./spec/unit/outputs/elasticsearch_spec.rb:5 # outputs/elasticsearch_java registration should register
rspec ./spec/unit/outputs/elasticsearch_spec.rb:69 # outputs/elasticsearch_java transport protocol sniffing => false should set the sniffing property to true
rspec ./spec/unit/outputs/elasticsearch_spec.rb:23 # outputs/elasticsearch_java transport protocol host not configured should set host to localhost
rspec ./spec/unit/outputs/elasticsearch_spec.rb:48 # outputs/elasticsearch_java transport protocol sniffing => true should set the sniffing property to true
jordansissel commented 9 years ago

Relevant history: https://github.com/logstash-plugins/logstash-output-elasticsearch_java/pull/1#issuecomment-138633960

talevy commented 9 years ago

@jordansissel thanks, missed that

jordansissel commented 9 years ago

@talevy I suspect we shouldn't need network_host for TransportClient (because nothing connects directly to the transport client), so I think this is a bug/misconfiguration we should fix, but it may be low priority.

andrewvc commented 9 years ago

@jordansissel I believe this is required in ES2.0 when interacting with remote servers (not localhost). I'm not yet sure as to why however.

I came across this in my benchmarking, I could not connect to a remote ES2.0 cluster with transport without that being set.