friendica/friendica — pull request #594 by fermionic (2013-01-28 00:54:53+00:00)
Title: add event-id index to prevent large CPU loads when visiting the events page

I discovered that when I visited my Events page, the DB used 100% of the CPU for about 15 s. Upon investigation, I discovered the problem: there's no index for event-id in the item table. After creating the index, the DB query drops to 2 ms.