some packages refactoring