You:
- "handle" all exceptions with an empty block;
- have no
finally
where you release the database resources; - have no line of code whatsoever which should close the database connection, even in a "happy day" scenario.
Your program stops working because each time the task runs, one database connection is left hanging. Soon enough there are no more connections to acquire, but you don't get informed of that because you decided not to log the exception.