Reorg packages, Refactor entities handling, Improve performance