← Back to team overview

maria-discuss team mailing list archive

Re: MariaDB threads optimalization


Le 7 févr. 2018 à 11:48, Reindl Harald <h.reindl@xxxxxxxxxxxxx> a écrit :

Am 07.02.2018 um 11:39 schrieb jocelyn fournier:

Le 7 févr. 2018 à 11:34, Reindl Harald <h.reindl@xxxxxxxxxxxxx> a écrit :

Am 07.02.2018 um 11:28 schrieb Sergey Vojtovich:

I'm afraid query cache doesn't scale well. Try turning it off

well, the question is why on a read-bound workload because there is no
valid reason that it locks reads for other threads

and no remove query-cache like MySQL 8.0 is no solution because when you
have a few terrible optimized queries on your server which takes seconds to
run query-cache will save your ass while you can (and we did) write known
fast queries with "select SQL_NO_CACHE" to get the locking relaxed

You could also take a look at software like https://www.heimdalldata.com
which tries to replace the query cache (and much more BTW)

it's not very helpful to throw more and more layers and software on
problems trying to hide instead solve them

well if there's no query cache at all like in MySQL 8, it could be
definitely useful :) And it add a few other useful features like read/write
split (for those who have not implemented it directly in their application
yet), automated failover, etc...
And with its dashboard you know what it's doing (and as a bonus what's
potentially wrong with your queries as well).

each layer brings inevitable it's own problems to the mix and if it's only
added latency for non-cacheable queries and complexer dependencies for
long-term maintainance of oyur whole application stack

I agree before adopting this kind of software, you have to check the
cacheability of your application (which is a metric displayed by the
heimdalldata dashboard BTW) because there's always a small overhead.
But I like the concept of heimdalldata where the cache is actually hosted
on each front server, instead of a potentially remote MySQL server, hence
*reducing* the latency of your application by removing the network
round-trip delay for cached queries.

Jocelyn Fournier
M : +33 6 51 21 54 10 <+33%206%2051%2021%2054%2010>
Softizy - At your side to Optimize your PHP / MySQL applications

Follow ups