I got an error with cancan:
Mongoid::Errors::InvalidCollection in MusiciansController#edit
Access to the collection for Musician is not allowed since it is an embedded document, please access a collection from the root document.
How could I create ability for embedded document?
Are you doing load_and_authorize_resource? That does not have support for embedded documents so you'll have to handle the loading yourself. You may want to do the authorization yourself too:
@musician = # fetch embedded musician
authorize! :edit, @musician
Thanks, will use reference