maybe instead of printing stack trace to console you can throw RuntimeException? It doesn't have to be declared and if something goes wrong you are notified about it in the right way - you don't need to look for the cause in logs