fixing issues due to refactoring carbon-kernel

Please merge after https://github.com/wso2/carbon4-kernel/pull/51 is merged