IP fixes
Adding roles functions
Multi-tenancy fixes
Fixes for mulit-tenancy
Removing logs and adding common module
Merge branch 'rc2' of github.com:WSO2Mobile/mam into rc2