code from the heap?

these days we have been looking into some weird performance issues with a project that is supposed to go live soon. we have not written all the code ourselves …  and were wondering why certain pieces of code had a constant 2 second duration which did not show up in the profiler.

we then found the following line of code:

monitor.wait(2000);

do I need to say anymore?