Oct 15, 2017

The profiler will give you the tools to find which portion of the code is actually slow and how long it is taking.

Some profilers are VisualVM (free) and JProfiler.