[CHG] Code refactoring, common code moved to lessgo