when logstash be started, the data of first jdbc input indexed by value of gdate, but data of second jdbc input indexed as word "a2_%{gdate}" instead of value of gdate
actually, it seems , when data in second jdbc is selecting, it has no information of gdate's value.
now, how can i handle this issue? i want that output data of second jdbc input be indexed same as first jdbc input. could you please advise me about this?
Each input is run independently. I do not think there is any order-of-execution guarantee. You might be able to add gdate to the events from the second jdbc input with either a jdbc_static or jdbc_streaming filter.
but it give me following error: [2019-02-24T17:42:55,369][ERROR][logstash.outputs.elasticsearch] Could not index event to Elasticsearch. {:status=>400, :action=>["index", {:_id=>nil, :_index=>"a6_{gdate=2019/02/23}", :_type=>"doc", :routing=>nil}, #<LogStash::Event:0x2342cdee>], :response=>{"index"=>{"_index"=>"a6_{gdate=2019/02/23}", "_type"=>"doc", "_id"=>nil, "status"=>400, "error"=>{"type"=>"invalid_index_name_exception", "reason"=>"Invalid index name [a6_{gdate=2019/02/23}], must not contain the following characters [ , \", *, \\, <, |, ,, >, /, ?]", "index_uuid"=>"_na_", "index"=>"a6_{gdate=2019/02/23}"}}}}
I am using tracking_column to have a query checkpoint. it is expected to save the last value of "basedate_accept_setel" in the sql_last_value, but in the .logstash_jdbc_last_run , i can just see the value "--- 0" while it should have value fore example as "20190101". how can i handle this issue?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.