6 ms·
Your index wouldn't be clustered, is it? For a regular index, insert is O(log n). For a clustered index, insert is O(n). You can also bulk insert records, ra
by fsk 11y ago
Your index wouldn't be clustered, is it? For a regular index, insert is O(log n). For a clustered index, insert is O(n).
You can also bulk insert records, rather than 1 at a time.
We have 2k operations per second on our aws rds.
- pjungwir 11y agoDefinitely agree re bulk inserting, say every 1 minute or 1 hour or whatever. I was paying around recently with Amazon's Kinesis for this, but if you don't want the vendor lock-in you could easily roll your own system that bundles up events and stores a bunch at once.
- fsk 11y agoIf you do open database connection do one insert close database connection That adds up fast. At work, I've been very disappointed in the performance of their Amazon RDS. They had unexplained master/slave replication issues. You also can put a memcached in front of the database.