refactoring entity use of container
suffix Trait and add container factory
refactoring some dependencies