Fixed concurrency issues using a pool