how to migrate mysql data to ElasticSearch realtime

I have a mysql database with couple tables, I wanna migrate the mysql data to ElasticSearch. It’s easy to migrate the whole database to ES via a batch job. But how should I update ES from mysql realtime. i.e if there was a update operation in mysql then I should do the same operation in ES.
I researched mysql binLog which can reflect any changes from mysql. But I have to parse binLog to ES syntax, I think it’s really painful. Thanks!
(the same case with Solr)