MySQL vs Redis – Configuring MySQL as ACI

MySQLredis

i have an use case in my application where i need real time communication between users based on their position. Basically one user will create an "event" and it will be sent to near users. On the server side i'm planning use redis or mysql to manage events and participants. Based on questions like this one i could configure mysql with:

innodb_flush_log_at_trx_commit = 2

and it increases write performance. Do you think that properly configured MySQL could compete with Redis?, what i like of MySQL is that i can use an ORM in front of it. Or maybe i'm missing something about the difference between Redis and MySQL.

Thanks in advance.

Best Answer

There are too many differences to enumerate. The choice between them is heavily based on your application, which you have not described.

That setting affects writes, not reads.

If you are not exceeding 100 queries per second on slow spinning drives, MySQL will do just fine. Or, if it does not, then we should look at your indexes and queries.