The best way to automatically delete data from certain index by list of IDs


Could you please help me with the following.

I have some SQL environment that consists of:

  • Table1. It is main table with data. Here I have unique identifier SKID of each entry.
  • Table2. Accumulates SKIDs of entries that were deleted from table1.
  • SQL procedure that manages these two tables. It inserts/updates/deletes data in table1 and inserts list of deleted SKIDs into table2.

In ElasticSearch I have an index1 that is filled by Logstash with data from table1 via jdbc input plugin.
Now I'm looking for the way to make Logstash get the list of deleted SKIDs from table2 and delete entries with same SKIDs in index1.
How can I reach this?

P.S. If it makes sense, I use ELK stack version 6.1.3.

Any suggestions?

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