I managed to get CanCan and Mongoid (version 2) to work well with the rails 3 application. There are still some errors here and there related to the conditions in the resolution definition (ability model).
I just put the contents of this gist into a file in config / initializers:
The hash of the conditions is almost the same as that of ActiveRecord:
can :manage, User, :_id => current_user.id
, Mongoid:: Criteria, :
can :eat, Cake do
current_user.jobs.any?{ |job| job.title == 'Peasant'}
end