Kubernetes / Node MySQL - Concurrent requests exponentially slowing and causing pod to crash Kubernetes / Node MySQL - Concurrent requests exponentially slowing and causing pod to crash kubernetes kubernetes

Kubernetes / Node MySQL - Concurrent requests exponentially slowing and causing pod to crash


For anyone else who might experience a similar problem, I found that the issue stemmed from a combination of issues:

Although the query took a minuscule amount of time to process (53ms), the results being sent back contained every column of each join entity (i.e. If I queried a table with 3 joins, I'd received 4 tables worth of columns in the response). By itself this is fine, however the frontend and gateway were utilising GraphQL, which seemed unable to cope with processing such a large amount of data concurrently.

The resolution was to re-structure the query such that only the required columns/rows were retrieved (this took the number of rows down to double digits)