In my experience, one of the highest-impact upgrades you can perform to increase Raspberry Pi performance is to buy the fastest possible microSD card—especially for applications where you need to do a lot of random reads and writes.
There is an order-of-magnitude difference between most cheap cards and the slightly-more-expensive ones (even if both are rated as being in the same class)—especially in small-block random I/O performance. As an example, if you use a normal, cheap microSD card for your database server, normal database operations can literally be 100x slower than if you used a standard microSD card.
Because of this, I went and purchased over a dozen different cards and have been putting them through their paces [midwesternmac.com]. Here are the results of those efforts...
Visit TFA for the full table. The overall winner seems to be OWC Envoy SSD (USB), with hdparm buffered: 34.13 MB/s; dd write: 34.4 MB/s; 4K rand read: 7.06 MB/s; 4K rand write: 8.20 MB/s