Lock when getting the dynamics.