3 ms·
There are a lot of optimization tricks you could do with an app like rescuetime. 1. Buffer inserts on two levels: a. In-memory at the application level (if i
by fleaflicker 19y ago
There are a lot of optimization tricks you could do with an app like rescuetime.
1. Buffer inserts on two levels:
a. In-memory at the application level (if it crashes and you lose a few seconds' worth of data, it is not the end of the world). You can now do bulk inserts.
b. Use MySQL's delayed insert buffer.
2. Split the data into separate tables for each duration interval so that you don't have one massive table.
- denimboy 19y ago1) Delayed inserts do not work with InnoDB tables. 2) This is a great idea for time based data. You age out the tables and create a merge table which is a logical view of all the tables together. You can get tricky and use compressed myisam tables for the older, static data since it will never change.
- deleted 19y ago[deleted]