Query cancellation & timeout