diff --git a/components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/editor/commons/js/utils/utils.js b/components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/editor/commons/js/utils/utils.js index e7e27089102..cac1b3d727a 100644 --- a/components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/editor/commons/js/utils/utils.js +++ b/components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/editor/commons/js/utils/utils.js @@ -1,8 +1,8 @@ /** * Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0 */ -define(['require', 'jquery', 'constants'], - function (require, $, Constants) { +define(['require', 'jquery', 'constants', 'alerts'], + function (require, $, Constants, alerts) { var self = this; var Utils = function () { }; @@ -16,109 +16,6 @@ define(['require', 'jquery', 'constants'], editorUrl: window.location.protocol + "//" + window.location.host + '/editor' }; - // /** - // * getting extension data from back end. - // * @returns {Map|Map} - // */ - // function getExtensionDetails() { // TODO remove - // return new Map(Object.entries({})); - // - // - // - // - // // return new Map(Object.entries({ - // // "kafka": { - // // "extensionStatus": "NOT_INSTALLED", - // // "extensionInfo": { - // // "name": "kafka", - // // "version": "5.0.8-SNAPSHOT" - // // } - // // }, - // // "redis": { - // // "extensionStatus": "NOT_INSTALLED", - // // "extensionInfo": { - // // "name": "redis", - // // "version": "3.1.2-SNAPSHOT" - // // }, - // // "manuallyInstall": [ - // // { - // // "name": "redis-clients", - // // "version": "2.3.0", - // // "download": { - // // "info": { - // // "description": "redis clients is like a one extension", - // // "install": "by using this way we can install redis-clients" - // // }, - // // "autoDownloadable": false, - // // "url": "https://repo1.maven.org/maven2/org/apache/redis/redis_2.11/2.1.1/redis_2.11-2.1.1.jar" - // // }, - // // "type": "BUNDLE", - // // "lookupRegex": "kafka-clients-(.+).jar" - // // }, - // // { - // // "name": "redis-server", - // // "version": "2.3.0", - // // "download": { - // // "info": { - // // "description": "redis clients is like a one extension", - // // "install": "by using this way we can install redis-clients" - // // }, - // // "autoDownloadable": false, - // // "url": "https://repo1.maven.org/maven2/org/apache/redis/redis_2.11/2.1.1/kafka_2.11-2.1.1.jar" - // // }, - // // "type": "BUNDLE", - // // "lookupRegex": "kafka-server-(.+).jar" - // // } - // // ] - // // }, - // // "grpc": { - // // "extensionStatus": "NOT_INSTALLED", - // // "extensionInfo": { - // // "name": "grpc", - // // "version": "3.1.2-SNAPSHOT" - // // }, - // // "manuallyInstall": [ - // // { - // // "name": "grpc-clients", - // // "version": "2.3.0", - // // "download": { - // // "info": { - // // "description": "grpc clients is like a one extension", - // // "install": "by using this way we can install grpc-clients" - // // }, - // // "autoDownloadable": false, - // // "url": "https://repo1.maven.org/maven2/org/apache/grpc/grpc_2.11/2.1.1/grpc_2.11-2.1.1.jar" - // // }, - // // "type": "BUNDLE", - // // "lookupRegex": "grpc-clients-(.+).jar" - // // }, - // // { - // // "name": "grpc-server", - // // "version": "2.3.0", - // // "download": { - // // "info": { - // // "description": "grpc server is like a one extension", - // // "install": "by using this way we can install grpc-server" - // // }, - // // "autoDownloadable": false, - // // "url": "https://repo1.maven.org/maven2/org/apache/grpc/grpc_2.11/2.1.1/grpc_2.11-2.1.1.jar" - // // }, - // // "type": "BUNDLE", - // // "lookupRegex": "grpc-server-(.+).jar" - // // } - // // ] - // // }, - // // "nats": { - // // "extensionStatus": "NOT_INSTALLED", - // // "extensionInfo": { - // // "name": "nats", - // // "version": "3.1.2-SNAPSHOT" - // // }, - // // } - // // })); - // }, - - /** * Installs or un-installs an extension. * @@ -154,7 +51,7 @@ define(['require', 'jquery', 'constants'], "