I am facing error with invalid URL for below http_poller code.
input {
http_poller{
urls => {
test2 => {
method => get
user => "weblogic"
password => "welcome1"
urls => "http://weblogic:7001/management/wls/latest/servers"
headers => { Accept => "application/json" }
}
}
request_timeout => 420
schedule => { every => "60s" }
codec => "json"
metadata_target => "http_poller_metadata"
}
}
output {
elasticsearch { hosts => [ "localhost:9200" ] }
stdout { codec => rubydebug }
}
============Error =======
[2021-01-27T02:20:10,139][ERROR][logstash.javapipeline ][main] Pipeline error {:pipeline_id=>"main", :exception=>#<LogStash::ConfigurationError: Invalid URL >, :backtrace=>["/u01/app/oracle/product/elk/logstash-7.9.3/vendor/bundle/jruby/2.5.0/gems/logstash-input-http_poller-5.0.2/lib/logstash/inputs/http_poller.rb:103:in validate_request!'", "/u01/app/oracle/product/elk/logstash-7.9.3/vendor/bundle/jruby/2.5.0/gems/logstash-input-http_poller-5.0.2/lib/logstash/inputs/http_poller.rb:95:in
normalize_request'", "/u01/app/oracle/product/elk/logstash-7.9.3/vendor/bundle/jruby/2.5.0/gems/logstash-input-http_poller-5.0.2/lib/logstash/inputs/http_poller.rb:55:in block in setup_requests!'", "org/jruby/RubyHash.java:1415:in
each'", "org/jruby/RubyEnumerable.java:886:in map'", "/u01/app/oracle/product/elk/logstash-7.9.3/vendor/bundle/jruby/2.5.0/gems/logstash-input-http_poller-5.0.2/lib/logstash/inputs/http_poller.rb:55:in
setup_requests!'", "/u01/app/oracle/product/elk/logstash-7.9.3/vendor/bundle/jruby/2.5.0/gems/logstash-input-http_poller-5.0.2/lib/logstash/inputs/http_poller.rb:45:in register'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:228:in
block in register_plugins'", "org/jruby/RubyArray.java:1809:in each'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:227:in
register_plugins'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:386:in start_inputs'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:311:in
start_workers'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:185:in run'", "/u01/app/oracle/product/elk/logstash-7.9.3/logstash-core/lib/logstash/java_pipeline.rb:137:in
block in start'"], "pipeline.sources"=>["/u01/app/oracle/product/elk/logstash-7.9.3/config/pipelines/osb3pipe.conf"], :thread=>"#<Thread:0x15538ad0 run>"}
[2021-01-27T02:20:10,142][INFO ][logstash.javapipeline ][main] Pipeline terminated {"pipeline.id"=>"main"}
[2021-01-27T02:20:10,158][ERROR][logstash.agent ] Failed to execute action {:id=>:main, :action_type=>LogStash::ConvergeResult::FailedAction, :message=>"Could not execute action: PipelineAction::Create, action_result: false", :backtrace=>nil}
[2021-01-27T02:20:10,435][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
[2021-01-27T02:20:15,311][INFO ][logstash.runner ] Logstash shut down.
[2021-01-27T02:20:15,328][ERROR][org.logstash.Logstash ] java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit