refactor code and add myhadoop-common project