Restructured the wso2 integration code