Hello,
I have two files .conf.
First have 1 input jdbc to taking data from mysql bdd / no filter / output TCP to logstash.
With this data, i build url for API. ex : https://nomapi/var1/var2/var3
This .conf is ok.
input {
jdbc {
jdbc_driver_library => ""
jdbc_driver_class => "com.mysql.jdbc.Driver"
jdbc_connection_string => ""
jdbc_user => "user"
jdbc_password => "pass"
schedule => "* * * * *"
statement => "myrequest"
output {
tcp {
host => ""
port => "5000"
mode => "client"
}
stdout { codec => json }
}
Second have 2 inputs, one is TCP for data, second is http_poller.
I need url builded in http_poller but i dont understand how ?
input {
tcp {
port => 5000
codec => "json_lines"
}
http_poller {
urls => {
myurl => "http://%{datafromtcp}"
}
}
}
output {
stdout {
codec => json
}
}
Thanks you