merging wso2-dev/master
code cleanup and refactoring