How can i install jdbc_streaming filter plugin


(Liangxiong Zhu) #1

i want to use jdbc_streaming filter plugin, but i get error, "Cannot create pipeline" reason: Couldn't find any filter plugin named 'jdbc_streaming'.
then i tried logstash-plugin install jdbc_streaming. the result of Validating jdbc_streaming is Plugin jdbc_streaming does not exists.

i am using
windows 10,
logstash 5.5.1
and here is my logstash config file

this configuration file is used to test jdbc_streaming filter plugin

input {

jdbc {#role
jdbc_driver_library => "mssql-jdbc-6.2.1.jre8.jar"
jdbc_driver_class => "Java::com.microsoft.sqlserver.jdbc.SQLServerDriver"
jdbc_connection_string => "jdbc:sqlserver://dbip:dbport;database=dbname;Application Name=logstash-role"
jdbc_user=>"sa"
jdbc_password=>"yes i am password"
schedule => "0 * * * * *"
lowercase_column_names=>false
last_run_metadata_path=>"C:\ElastiscSearch\logstash\ias-conf\last-run-role.txt"
tracking_column=>"PersonId"
use_column_value=>true
statement=>"select top 10 * from dbo.Tp_Person where PersonId>:last_sql_value order by PersonId ASC"
record_last_run=>"true"
sql_log_level=>"warn"
type=>"person"
}

}

filter{
jdbc_streaming {
jdbc_driver_library => "mssql-jdbc-6.2.1.jre8.jar"
jdbc_driver_class => "Java::com.microsoft.sqlserver.jdbc.SQLServerDriver"
jdbc_connection_string => "jdbc:sqlserver://jdbc:sqlserver://dbip:dbport;database=dbname;Application Name=logstash-role"
jdbc_user=>"sa"
jdbc_password=>"yes i am password"
statement => "select * from dbo.tr_role where PersonId=:PersonId"
parameters => { "PersonId" => "%{PersonId}"}
target => "Roles"
}
}

output {
stdout { codec => json }
file {
path => [ "C:\ElastiscSearch\logstash\ias-output\jdbc-log.txt" ]
codec => json_lines
}
}


(Magnus Bäck) #2

then i tried logstash-plugin install jdbc_streaming

That's the wrong command. The full name of the plugin to install is logstash-filter-jdbc_streaming. See https://www.elastic.co/guide/en/logstash/current/working-with-plugins.html#installing-plugins.


(Liangxiong Zhu) #3

thanks. this plugin is installed successfully after i use its full name.


(system) #4

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.