My application uses Hikari DB Pool. I run the application on one of my local machines (it's home network) but application uses remote database hosted by other company.
The application inserts some records every 5 minutes to the DB so it is in constant use.
Everything works fine, but from time to time (completely undeterministic), the database blocks my IP saying:
message from server: "Host 'xxx' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
Before that happens - I do not notice any strange behaviour.
So here is my question (I do not ask how to unblock it!! :)):
- How can I find an error - is this a problem with my application or maybe it's caused because of remote connection?
- In any case, how to detect and prevent such connection errors before DB will block my IP again?
I use java + spring data + hibernate + hikari db pool.