REST API or Logstash for add/update/delete records in Elastic Index?


#1

We have a MySQL database and are using Elastic 5.4 and wanted to know out of the below two options of getting data from MySQL into our ES index which is preferred and why (if possible)

  1. As records are added, updated, and deleted in our MySQL transactional database, in turn use the REST API and index those documents in ES so they can be easily searched.

  2. Setup logstash to upsert (not sure if delete works too?) into our ES index every 5 minutes as an example using a scheduled interval in a logstash config.

We are thinking of going wtih option 1 as it seems it will give us the most control and also allow use to add/update/delete documents at a more granular level than if we setup logstash, but we are not 100% certain. Option 1 seems like it would also allow us to only insert/update/delete records when it actually happens in our transacational database versus a scheduled process that just sort of runs in the background

Any advice or thoughts?

Thanks in advance!


(David Pilato) #2

I shared my thoughts here: http://david.pilato.fr/blog/2015/05/09/advanced-search-for-your-legacy-application/


#3

Thank you @dadoonet - this was super helpful and makes sense. I plan on going the same route.


(system) #4

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