Fix: Acquire and Release handle protected with mutex

Several threads acquire and release easy handles when creating stratum1 replica. This adds locks to protect the curl easy handle management.