java - Get MYSQL last updated data or lastly inserted data -


i have problem this.

i accessing database having on 100,000 data in new entry table.

now want write listener, means if new record insert table somewhere else have notification.

my question is: best , fastest way this? because day there should have around 500 new data in new entry table. is suitable check database every time using thread?

im using java mysql.

please advice me.

i not sure whether there listener exists mysql changes. wouldn't straight forward these details.

but there called 'the binary log' in mysql, contains “events” describe database changes such table creation operations or changes table data.

so 1 way track changes can polling these logs. challenge these logs written in binary format. mysql provides utility called mysqlbinlog process these logs in text format.

here 1 java parser rescue, can read mysql binary logs:

https://github.com/tangfl/jbinlog

integrating bits , pieces , may able need.


Comments

Popular posts from this blog

javascript - Count length of each class -

What design pattern is this code in Javascript? -

hadoop - Restrict secondarynamenode to be installed and run on any other node in the cluster -