Ballancing and refactoring