Return-Path: X-Original-To: apmail-ignite-commits-archive@minotaur.apache.org Delivered-To: apmail-ignite-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 76BE01829A for ; Thu, 30 Jul 2015 09:37:08 +0000 (UTC) Received: (qmail 73719 invoked by uid 500); 30 Jul 2015 09:37:08 -0000 Delivered-To: apmail-ignite-commits-archive@ignite.apache.org Received: (qmail 73688 invoked by uid 500); 30 Jul 2015 09:37:08 -0000 Mailing-List: contact commits-help@ignite.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.incubator.apache.org Delivered-To: mailing list commits@ignite.incubator.apache.org Received: (qmail 73679 invoked by uid 99); 30 Jul 2015 09:37:08 -0000 Received: from Unknown (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jul 2015 09:37:08 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id C26D9D8D29 for ; Thu, 30 Jul 2015 09:37:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.627 X-Spam-Level: X-Spam-Status: No, score=-0.627 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-1.428, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-eu-west.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id 3gXcPHrw8gPp for ; Thu, 30 Jul 2015 09:36:52 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-eu-west.apache.org (ASF Mail Server at mx1-eu-west.apache.org) with SMTP id 3695124D7C for ; Thu, 30 Jul 2015 09:36:47 +0000 (UTC) Received: (qmail 72886 invoked by uid 99); 30 Jul 2015 09:36:46 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jul 2015 09:36:46 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 3CF78E6B87; Thu, 30 Jul 2015 09:36:46 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: anovikov@apache.org To: commits@ignite.incubator.apache.org Date: Thu, 30 Jul 2015 09:36:56 -0000 Message-Id: In-Reply-To: <431d0233e2bf435fa31293bb3d879553@git.apache.org> References: <431d0233e2bf435fa31293bb3d879553@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [12/28] incubator-ignite git commit: # ignite-843 Rename http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/controllers/summary-controller.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/controllers/summary-controller.js b/modules/web-control-center/src/main/js/controllers/summary-controller.js deleted file mode 100644 index 531dc83..0000000 --- a/modules/web-control-center/src/main/js/controllers/summary-controller.js +++ /dev/null @@ -1,170 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -controlCenterModule.controller('summaryController', ['$scope', '$http', '$common', function ($scope, $http, $common) { - $scope.joinTip = $common.joinTip; - $scope.getModel = $common.getModel; - - $scope.javaClassItems = [ - {label: 'snippet', value: false}, - {label: 'factory class', value: true} - ]; - - $scope.evictionPolicies = [ - {value: 'LRU', label: 'LRU'}, - {value: 'RND', label: 'Random'}, - {value: 'FIFO', label: 'FIFO'}, - {value: 'SORTED', label: 'Sorted'}, - {value: undefined, label: 'Not set'} - ]; - - $scope.oss = ['debian:8', 'ubuntu:14.10']; - - $scope.configServer = {javaClassServer: false, os: undefined}; - $scope.backupItem = {javaClassClient: false}; - - $http.get('/models/summary.json') - .success(function (data) { - $scope.screenTip = data.screenTip; - $scope.clientFields = data.clientFields; - }) - .error(function (errMsg) { - $common.showError(errMsg); - }); - - $scope.clusters = []; - - $scope.aceInit = function (editor) { - editor.setReadOnly(true); - editor.setOption("highlightActiveLine", false); - - var renderer = editor.renderer; - - renderer.setHighlightGutterLine(false); - renderer.setShowPrintMargin(false); - renderer.setOption('fontSize', '14px'); - - editor.setTheme('ace/theme/chrome'); - }; - - $scope.reloadServer = function () { - $scope.javaServer = $scope.configServer.javaClassServer ? $scope.configServer.javaClass : $scope.configServer.javaSnippet; - - if ($scope.configServer.docker) { - var os = $scope.configServer.os ? $scope.configServer.os : $scope.oss[0]; - - $scope.dockerServer = $scope.configServer.docker.replace(new RegExp('\%OS\%', 'g'), os); - } - }; - - $scope.selectItem = function (cluster) { - if (!cluster) - return; - - $scope.selectedItem = cluster; - - $scope.$watch('javaClassServer', $scope.reloadServer); - $scope.$watch('os', $scope.reloadServer); - - $scope.generateServer(cluster); - - $scope.reloadServer(); - - $scope.$watch('configServer', function () { - $scope.reloadServer(); - }, true); - - $scope.$watch('backupItem', function () { - $scope.generateClient(); - }, true); - }; - - $scope.generateServer = function (cluster) { - $http.post('summary/generator', {_id: cluster._id}) - .success(function (data) { - $scope.xmlServer = data.xmlServer; - - $scope.configServer.javaClass = data.javaClassServer; - $scope.configServer.javaSnippet = data.javaSnippetServer; - $scope.configServer.docker = data.docker; - }).error(function (errMsg) { - $common.showError('Failed to generate config: ' + errMsg); - }); - }; - - $scope.generateClient = function () { - $http.post('summary/generator', { - _id: $scope.selectedItem._id, javaClass: $scope.backupItem.javaClassClient, - clientNearConfiguration: $scope.backupItem.nearConfiguration - }) - .success(function (data) { - $scope.xmlClient = data.xmlClient; - $scope.javaClient = data.javaClient; - }).error(function (errMsg) { - $common.showError('Failed to generate config: ' + errMsg); - }); - }; - - $scope.download = function () { - $http.post('summary/download', {_id: $scope.selectedItem._id, javaClass: $scope.javaClass, os: $scope.os}) - .success(function (data) { - var file = document.createElement('a'); - - file.setAttribute('href', 'data:application/octet-stream;charset=utf-8,' + data); - file.setAttribute('download', $scope.selectedItem.name + '-configuration.zip'); - - file.style.display = 'none'; - - document.body.appendChild(file); - - file.click(); - - document.body.removeChild(file); - }) - .error(function (errMsg) { - $common.showError('Failed to generate zip: ' + errMsg); - }); - }; - - $http.post('clusters/list').success(function (data) { - $scope.clusters = data.clusters; - - if ($scope.clusters.length > 0) { - var restoredId = sessionStorage.summarySelectedId; - - var selectIdx = 0; - - if (restoredId) { - var idx = _.findIndex($scope.clusters, function (cluster) { - return cluster._id == restoredId; - }); - - if (idx >= 0) - selectIdx = idx; - else - delete sessionStorage.summarySelectedId; - } - - $scope.selectItem($scope.clusters[selectIdx]); - - $scope.$watch('selectedItem', function (val) { - if (val) - sessionStorage.summarySelectedId = val._id; - }, true); - } - }); -}]); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/db.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/db.js b/modules/web-control-center/src/main/js/db.js deleted file mode 100644 index 5232e24..0000000 --- a/modules/web-control-center/src/main/js/db.js +++ /dev/null @@ -1,370 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var config = require('./helpers/configuration-loader.js'); - -// Mongoose for mongodb. -var mongoose = require('mongoose'), - Schema = mongoose.Schema, - ObjectId = mongoose.Schema.Types.ObjectId, - passportLocalMongoose = require('passport-local-mongoose'); - -var deepPopulate = require('mongoose-deep-populate'); - -// Connect to mongoDB database. -mongoose.connect(config.get('mongoDB:url'), {server: {poolSize: 4}}); - -// Define account model. -var AccountSchema = new Schema({ - username: String, - email: String, - lastLogin: Date, - admin: Boolean -}); - -AccountSchema.plugin(passportLocalMongoose, {usernameField: 'email', limitAttempts: true, lastLoginField: 'lastLogin', - usernameLowerCase: true}); - -AccountSchema.set('toJSON', { - transform: function(doc, ret) { - return { - _id: ret._id, - email: ret.email, - username: ret.username, - admin: ret.admin, - lastLogin: ret.lastLogin - }; - } -}); - -exports.Account = mongoose.model('Account', AccountSchema); - -// Define space model. -exports.Space = mongoose.model('Space', new Schema({ - name: String, - owner: {type: ObjectId, ref: 'Account'}, - usedBy: [{ - permission: {type: String, enum: ['VIEW', 'FULL']}, - account: {type: ObjectId, ref: 'Account'} - }] -})); - -// Define cache type metadata model. -var CacheTypeMetadataSchema = new Schema({ - space: {type: ObjectId, ref: 'Space'}, - name: String, - kind: {type: String, enum: ['query', 'store', 'both']}, - databaseSchema: String, - databaseTable: String, - keyType: String, - valueType: String, - keyFields: [{databaseName: String, databaseType: String, javaName: String, javaType: String}], - valueFields: [{databaseName: String, databaseType: String, javaName: String, javaType: String}], - queryFields: [{name: String, className: String}], - ascendingFields: [{name: String, className: String}], - descendingFields: [{name: String, className: String}], - textFields: [String], - groups: [{name: String, fields: [{name: String, className: String, direction: Boolean}]}] -}); - -exports.CacheTypeMetadata = mongoose.model('CacheTypeMetadata', CacheTypeMetadataSchema); - -// Define cache model. -var CacheSchema = new Schema({ - space: {type: ObjectId, ref: 'Space'}, - name: String, - mode: {type: String, enum: ['PARTITIONED', 'REPLICATED', 'LOCAL']}, - atomicityMode: {type: String, enum: ['ATOMIC', 'TRANSACTIONAL']}, - - backups: Number, - memoryMode: {type: String, enum: ['ONHEAP_TIERED', 'OFFHEAP_TIERED', 'OFFHEAP_VALUES']}, - offHeapMaxMemory: Number, - startSize: Number, - swapEnabled: Boolean, - - evictionPolicy: { - kind: {type: String, enum: ['LRU', 'RND', 'FIFO', 'Sorted']}, - LRU: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - }, - RND: { - maxSize: Number - }, - FIFO: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - }, - SORTED: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - } - }, - - rebalanceMode: {type: String, enum: ['SYNC', 'ASYNC', 'NONE']}, - rebalanceThreadPoolSize: Number, - rebalanceBatchSize: Number, - rebalanceOrder: Number, - rebalanceDelay: Number, - rebalanceTimeout: Number, - rebalanceThrottle: Number, - - storeMetadata: [{type: ObjectId, ref: 'CacheTypeMetadata'}], - cacheStoreFactory: { - kind: { - type: String, - enum: ['CacheJdbcPojoStoreFactory', 'CacheJdbcBlobStoreFactory', 'CacheHibernateBlobStoreFactory'] - }, - CacheJdbcPojoStoreFactory: { - dataSourceBean: String, - dialect: { - type: String, - enum: ['Oracle', 'DB2', 'SQLServer', 'MySQL', 'PosgreSQL', 'H2'] - } - }, - CacheJdbcBlobStoreFactory: { - user: String, - dataSourceBean: String, - initSchema: Boolean, - createTableQuery: String, - loadQuery: String, - insertQuery: String, - updateQuery: String, - deleteQuery: String - }, - CacheHibernateBlobStoreFactory: { - hibernateProperties: [String] - } - }, - loadPreviousValue: Boolean, - readThrough: Boolean, - writeThrough: Boolean, - - writeBehindEnabled: Boolean, - writeBehindBatchSize: Number, - writeBehindFlushSize: Number, - writeBehindFlushFrequency: Number, - writeBehindFlushThreadCount: Number, - - invalidate: Boolean, - defaultLockTimeout: Number, - transactionManagerLookupClassName: String, - - sqlEscapeAll: Boolean, - sqlOnheapRowCacheSize: Number, - longQueryWarningTimeout: Number, - queryMetadata: [{type: ObjectId, ref: 'CacheTypeMetadata'}], - indexedTypes: [{keyClass: String, valueClass: String}], - sqlFunctionClasses: [String], - statisticsEnabled: Boolean, - managementEnabled: Boolean, - readFromBackup: Boolean, - copyOnRead: Boolean, - maxConcurrentAsyncOperations: Number, - nearConfiguration: { - nearStartSize: Number, - nearEvictionPolicy: { - kind: {type: String, enum: ['LRU', 'RND', 'FIFO', 'Sorted']}, - LRU: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - }, - RND: { - maxSize: Number - }, - FIFO: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - }, - SORTED: { - batchSize: Number, - maxMemorySize: Number, - maxSize: Number - } - } - } -}); - -exports.Cache = mongoose.model('Cache', CacheSchema); - -// Define cluster schema. -var ClusterSchema = new Schema({ - space: {type: ObjectId, ref: 'Space'}, - name: String, - discovery: { - kind: {type: String, enum: ['Vm', 'Multicast', 'S3', 'Cloud', 'GoogleStorage', 'Jdbc', 'SharedFs']}, - Vm: { - addresses: [String] - }, - Multicast: { - multicastGroup: String, - multicastPort: Number, - responseWaitTime: Number, - addressRequestAttempts: Number, - localAddress: String - }, - S3: { - bucketName: String - }, - Cloud: { - credential: String, - credentialPath: String, - identity: String, - provider: String, - regions: [String], - zones: [String] - }, - GoogleStorage: { - projectName: String, - bucketName: String, - serviceAccountP12FilePath: String, - addrReqAttempts: String - }, - Jdbc: { - initSchema: Boolean - }, - SharedFs: { - path: String - } - }, - atomicConfiguration: { - backups: Number, - cacheMode: {type: String, enum: ['LOCAL', 'REPLICATED', 'PARTITIONED']}, - atomicSequenceReserveSize: Number - }, - caches: [{type: ObjectId, ref: 'Cache'}], - cacheSanityCheckEnabled: Boolean, - clockSyncSamples: Number, - clockSyncFrequency: Number, - deploymentMode: {type: String, enum: ['PRIVATE', 'ISOLATED', 'SHARED', 'CONTINUOUS']}, - discoveryStartupDelay: Number, - igfsThreadPoolSize: Number, - includeEventTypes: [{ - type: String, enum: ['EVTS_CHECKPOINT', 'EVTS_DEPLOYMENT', 'EVTS_ERROR', 'EVTS_DISCOVERY', - 'EVTS_JOB_EXECUTION', 'EVTS_TASK_EXECUTION', 'EVTS_CACHE', 'EVTS_CACHE_REBALANCE', 'EVTS_CACHE_LIFECYCLE', - 'EVTS_CACHE_QUERY', 'EVTS_SWAPSPACE', 'EVTS_IGFS'] - }], - managementThreadPoolSize: Number, - marshaller: { - kind: {type: String, enum: ['OptimizedMarshaller', 'JdkMarshaller']}, - OptimizedMarshaller: { - poolSize: Number, - requireSerializable: Boolean - } - }, - marshalLocalJobs: Boolean, - marshallerCacheKeepAliveTime: Number, - marshallerCacheThreadPoolSize: Number, - metricsExpireTime: Number, - metricsHistorySize: Number, - metricsLogFrequency: Number, - metricsUpdateFrequency: Number, - networkTimeout: Number, - networkSendRetryDelay: Number, - networkSendRetryCount: Number, - peerClassLoadingEnabled: Boolean, - peerClassLoadingLocalClassPathExclude: [String], - peerClassLoadingMissedResourcesCacheSize: Number, - peerClassLoadingThreadPoolSize: Number, - publicThreadPoolSize: Number, - segmentCheckFrequency: Number, - segmentationPolicy: {type: String, enum: ['RESTART_JVM', 'STOP', 'NOOP']}, - allSegmentationResolversPassRequired: Boolean, - segmentationResolveAttempts: Number, - swapSpaceSpi: { - kind: {type: String, enum: ['FileSwapSpaceSpi']}, - FileSwapSpaceSpi: { - baseDirectory: String, - readStripesNumber: Number, - maximumSparsity: Number, - maxWriteQueueSize: Number, - writeBufferSize: Number - } - }, - systemThreadPoolSize: Number, - timeServerPortBase: Number, - timeServerPortRange: Number, - transactionConfiguration: { - defaultTxConcurrency: {type: String, enum: ['OPTIMISTIC', 'PESSIMISTIC']}, - transactionIsolation: {type: String, enum: ['READ_COMMITTED', 'REPEATABLE_READ', 'SERIALIZABLE']}, - defaultTxTimeout: Number, - pessimisticTxLogLinger: Number, - pessimisticTxLogSize: Number, - txSerializableEnabled: Boolean - }, - waitForSegmentOnStart: Boolean -}); - -ClusterSchema.plugin(deepPopulate, { - whitelist: [ - 'caches', - 'caches.queryMetadata', - 'caches.storeMetadata' - ] -}); - -// Define cluster model. -exports.Cluster = mongoose.model('Cluster', ClusterSchema); - -// Define persistence schema. -var PersistenceSchema = new Schema({ - space: {type: ObjectId, ref: 'Space'}, - name: String, - rdbms: {type: String, enum: ['oracle', 'db2', 'mssql', 'postgre', 'mysql', 'h2']}, - dbName: String, - host: String, - user: String, - tables: [{ - use: Boolean, - schemaName: String, - tableName: String, - keyClass: String, - valueClass: String, - columns: [{ - use: Boolean, - pk: Boolean, - ak: Boolean, - notNull: Boolean, - databaseName: String, - databaseType: Number, - javaName: String, - javaType: String - }] - }] -}); - -// Define persistence model. -exports.Persistence = mongoose.model('Persistence', PersistenceSchema); - -exports.upsert = function (model, data, cb) { - if (data._id) { - var id = data._id; - - delete data._id; - - model.findOneAndUpdate({_id: id}, data, cb); - } - else - new model(data).save(cb); -}; - -exports.mongoose = mongoose; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/helpers/configuration-loader.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/helpers/configuration-loader.js b/modules/web-control-center/src/main/js/helpers/configuration-loader.js deleted file mode 100644 index 6dbb577..0000000 --- a/modules/web-control-center/src/main/js/helpers/configuration-loader.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var config = require('nconf'); - -config.file({'file': 'config/default.json'}); - -module.exports = config; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/helpers/data-structures.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/helpers/data-structures.js b/modules/web-control-center/src/main/js/helpers/data-structures.js deleted file mode 100644 index 2462708..0000000 --- a/modules/web-control-center/src/main/js/helpers/data-structures.js +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -eventGroups = { - EVTS_CHECKPOINT: ['EVT_CHECKPOINT_SAVED', 'EVT_CHECKPOINT_LOADED', 'EVT_CHECKPOINT_REMOVED'], - EVTS_DEPLOYMENT: ['EVT_CLASS_DEPLOYED', 'EVT_CLASS_UNDEPLOYED', 'EVT_CLASS_DEPLOY_FAILED', 'EVT_TASK_DEPLOYED', - 'EVT_TASK_UNDEPLOYED', 'EVT_TASK_DEPLOY_FAILED'], - EVTS_ERROR: ['EVT_JOB_TIMEDOUT', 'EVT_JOB_FAILED', 'EVT_JOB_FAILED_OVER', 'EVT_JOB_REJECTED', 'EVT_JOB_CANCELLED', - 'EVT_TASK_TIMEDOUT', 'EVT_TASK_FAILED', 'EVT_CLASS_DEPLOY_FAILED', 'EVT_TASK_DEPLOY_FAILED', - 'EVT_TASK_DEPLOYED', 'EVT_TASK_UNDEPLOYED', 'EVT_CACHE_REBALANCE_STARTED', 'EVT_CACHE_REBALANCE_STOPPED'], - EVTS_DISCOVERY: ['EVT_NODE_JOINED', 'EVT_NODE_LEFT', 'EVT_NODE_FAILED', 'EVT_NODE_SEGMENTED', - 'EVT_CLIENT_NODE_DISCONNECTED', 'EVT_CLIENT_NODE_RECONNECTED'], - EVTS_JOB_EXECUTION: ['EVT_JOB_MAPPED', 'EVT_JOB_RESULTED', 'EVT_JOB_FAILED_OVER', 'EVT_JOB_STARTED', - 'EVT_JOB_FINISHED', 'EVT_JOB_TIMEDOUT', 'EVT_JOB_REJECTED', 'EVT_JOB_FAILED', 'EVT_JOB_QUEUED', - 'EVT_JOB_CANCELLED'], - EVTS_TASK_EXECUTION: ['EVT_TASK_STARTED', 'EVT_TASK_FINISHED', 'EVT_TASK_FAILED', 'EVT_TASK_TIMEDOUT', - 'EVT_TASK_SESSION_ATTR_SET', 'EVT_TASK_REDUCED'], - EVTS_CACHE: ['EVT_CACHE_ENTRY_CREATED', 'EVT_CACHE_ENTRY_DESTROYED', 'EVT_CACHE_OBJECT_PUT', - 'EVT_CACHE_OBJECT_READ', 'EVT_CACHE_OBJECT_REMOVED', 'EVT_CACHE_OBJECT_LOCKED', 'EVT_CACHE_OBJECT_UNLOCKED', - 'EVT_CACHE_OBJECT_SWAPPED', 'EVT_CACHE_OBJECT_UNSWAPPED', 'EVT_CACHE_OBJECT_EXPIRED'], - EVTS_CACHE_REBALANCE: ['EVT_CACHE_REBALANCE_STARTED', 'EVT_CACHE_REBALANCE_STOPPED', - 'EVT_CACHE_REBALANCE_PART_LOADED', 'EVT_CACHE_REBALANCE_PART_UNLOADED', 'EVT_CACHE_REBALANCE_OBJECT_LOADED', - 'EVT_CACHE_REBALANCE_OBJECT_UNLOADED', 'EVT_CACHE_REBALANCE_PART_DATA_LOST'], - EVTS_CACHE_LIFECYCLE: ['EVT_CACHE_STARTED', 'EVT_CACHE_STOPPED', 'EVT_CACHE_NODES_LEFT'], - EVTS_CACHE_QUERY: ['EVT_CACHE_QUERY_EXECUTED', 'EVT_CACHE_QUERY_OBJECT_READ'], - EVTS_SWAPSPACE: ['EVT_SWAP_SPACE_CLEARED', 'EVT_SWAP_SPACE_DATA_REMOVED', 'EVT_SWAP_SPACE_DATA_READ', - 'EVT_SWAP_SPACE_DATA_STORED', 'EVT_SWAP_SPACE_DATA_EVICTED'], - EVTS_IGFS: ['EVT_IGFS_FILE_CREATED', 'EVT_IGFS_FILE_RENAMED', 'EVT_IGFS_FILE_DELETED', 'EVT_IGFS_FILE_OPENED_READ', - 'EVT_IGFS_FILE_OPENED_WRITE', 'EVT_IGFS_FILE_CLOSED_WRITE', 'EVT_IGFS_FILE_CLOSED_READ', 'EVT_IGFS_FILE_PURGED', - 'EVT_IGFS_META_UPDATED', 'EVT_IGFS_DIR_CREATED', 'EVT_IGFS_DIR_RENAMED', 'EVT_IGFS_DIR_DELETED'] -}; - -jdbcTypes = { - BIT: {value: "BIT", code: -7, label: "BIT"}, - TINYINT: {value: "TINYINT", code: -6, label: "TINYINT"}, - SMALLINT: {value: "SMALLINT", code: 5, label: "SMALLINT"}, - INTEGER: {value: "INTEGER", code: 4, label: "INTEGER"}, - BIGINT: {value: "BIGINT", code: -5, label: "BIGINT"}, - FLOAT: {value: "FLOAT", code: 6, label: "FLOAT"}, - REAL: {value: "REAL", code: 7, label: "REAL"}, - DOUBLE: {value: "DOUBLE", code: 8, label: "DOUBLE"}, - NUMERIC: {value: "NUMERIC", code: 2, label: "NUMERIC"}, - DECIMAL: {value: "DECIMAL", code: 3, label: "DECIMAL"}, - CHAR: {value: "CHAR", code: 1, label: "CHAR"}, - VARCHAR: {value: "VARCHAR", code: 12, label: "VARCHAR"}, - DATE: {value: "DATE", code: 91, label: "DATE"}, - TIME: {value: "TIME", code: 92, label: "TIME"}, - TIMESTAMP: {value: "TIMESTAMP", code: 93, label: "TIMESTAMP"}, - BINARY: {value: "BINARY", code: -2, label: "BINARY"} -}; - -javaTypes = { - INTEGER: {value: "java.lang.Integer", label: "Integer"}, - LONG: {value: "java.lang.Long", label: "Long"}, - BIGDECIMAL: {value: "java.math.BigDecimal", label: "BigDecimal"}, - FLOAT: {value: "java.lang.Float", label: "Float"}, - DOUBLE: {value: "java.lang.Double", label: "Double"}, - STRING: {value: "java.lang.String", label: "String"}, - BOOLEAN: {value: "java.lang.Boolean", label: "Boolean"}, - BYTE_ARRAY: {value: "byte[]", label: "byte[]"}, - DATE: {value: "java.sql.Date", label: "Date"}, - TIME: {value: "java.sql.Time", label: "Time"}, - TIMESTAMP: {value: "java.sql.Timestamp", label: "Timestamp"} -}; - -if (typeof window === 'undefined') { - exports.eventGroups = eventGroups; - exports.jdbcTypes = jdbcTypes; - exports.javaTypes = javaTypes; -} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/package.json ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/package.json b/modules/web-control-center/src/main/js/package.json deleted file mode 100644 index fd82196..0000000 --- a/modules/web-control-center/src/main/js/package.json +++ /dev/null @@ -1,49 +0,0 @@ -{ - "name": "ignite-web-control-center", - "version": "1.0.0", - "description": "Web application for configuration, monitoring Ignite Cluster", - "private": true, - "scripts": { - "start": "node ./bin/www" - }, - "author": "", - "contributors": [ - { - "name": "", - "email": "" - } - ], - "license": "Apache-2.0", - "keywords": "grid", - "homepage": "https://ignite.incubator.apache.org/", - "engines": { - "node": ">=0.12.4" - }, - "dependencies": { - "angular-ui-ace": "^0.2.3", - "archiver": "^0.14.4", - "body-parser": "~1.12.0", - "connect-flash": "^0.1.1", - "connect-mongo": "^0.8.1", - "cookie-parser": "~1.3.4", - "debug": "~2.1.1", - "express": "~4.12.2", - "express-session": "^1.11.1", - "jade": "~1.9.2", - "lodash": "3.10.0", - "mongoose": "^4.0.2", - "mongoose-deep-populate": "1.1.0", - "nconf": "^0.7.1", - "node-sass-middleware": "^0.9.0", - "passport": "^0.2.1", - "passport-local": "^1.0.0", - "passport-local-mongoose": "^1.0.0", - "serve-favicon": "~2.2.0" - }, - "devDependencies": { - "morgan": "~1.5.1", - "supertest": "^1.0.1", - "mocha": "~2.0.1", - "should": "~3.1.3" - } -} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/favicon.ico ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/favicon.ico b/modules/web-control-center/src/main/js/public/favicon.ico deleted file mode 100644 index 74ec626..0000000 Binary files a/modules/web-control-center/src/main/js/public/favicon.ico and /dev/null differ http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/images/docker.png ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/images/docker.png b/modules/web-control-center/src/main/js/public/images/docker.png deleted file mode 100644 index 7ec3aef..0000000 Binary files a/modules/web-control-center/src/main/js/public/images/docker.png and /dev/null differ http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/images/java.png ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/images/java.png b/modules/web-control-center/src/main/js/public/images/java.png deleted file mode 100644 index ddb3b8e..0000000 Binary files a/modules/web-control-center/src/main/js/public/images/java.png and /dev/null differ http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/images/logo.png ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/images/logo.png b/modules/web-control-center/src/main/js/public/images/logo.png deleted file mode 100644 index c3577c5..0000000 Binary files a/modules/web-control-center/src/main/js/public/images/logo.png and /dev/null differ http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/images/xml.png ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/images/xml.png b/modules/web-control-center/src/main/js/public/images/xml.png deleted file mode 100644 index 029065e..0000000 Binary files a/modules/web-control-center/src/main/js/public/images/xml.png and /dev/null differ http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/public/stylesheets/style.scss ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/public/stylesheets/style.scss b/modules/web-control-center/src/main/js/public/stylesheets/style.scss deleted file mode 100644 index e2542ce..0000000 --- a/modules/web-control-center/src/main/js/public/stylesheets/style.scss +++ /dev/null @@ -1,1270 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -$logo-path: "https://www.filepicker.io/api/file/QagunjDGRFul2JgNCAli"; -$input-height: 28px; -$ignite-red: #ec1c24; -$ignite-block-callout-background: #f3f8f3; -$ignite-block-callout: #50af51; - -hr { - margin: 20px 0; -} - -.main-header .logo { - height: auto; -} - -.main-sidebar { - padding-top: 60px; -} - -.navbar-default .navbar-brand, .navbar-default .navbar-brand:hover { - position: absolute; - width: 100%; - left: 0; - text-align: center; -} - -.modal-backdrop.am-fade { - opacity: .5; - transition: opacity .15s linear; - &.ng-enter { - opacity: 0; - &.ng-enter-active { - opacity: .5; - } - } - &.ng-leave { - opacity: .5; - &.ng-leave-active { - opacity: 0; - } - } -} - -.modal.center .modal-dialog { - position: fixed; - top: 50%; - left: 50%; - -webkit-transform: translateX(-50%) translateY(-50%); - transform: translateX(-50%) translateY(-50%); -} - -.border-left { - box-shadow: 1px 0 0 0 #eee inset; -} - -.border-right { - box-shadow: 1px 0 0 0 #eee; -} - -.theme-line { - background-color: #f9f9f9; -} - -.theme-line header { - background-color: #fff; -} - -.theme-line header a.btn { - border: 0 none; - padding: 10px 25px; - background-color: rgba(0, 0, 0, 0.15); -} - -.theme-line header a.btn:hover { - background-color: rgba(0, 0, 0, 0.25); -} - -.theme-line header a.btn.btn-link { - background: transparent; - color: rgba(255, 255, 255, 0.8); -} - -.theme-line header a.btn.btn-link:hover { - color: #fff; - text-decoration: none; -} - -.theme-line .navbar-nav a { - background-color: transparent; -} - -.theme-line .navbar-nav a:hover, -.theme-line .navbar-nav a:active, -.theme-line .navbar-nav a:focus { - background-color: transparent; -} - -.theme-line .main-links { - padding-top: 50px; -} - -.theme-line .main-links h3 { - margin-top: 0; - font-size: 17px; -} - -.theme-line .main-links .links a { - color: #888; -} - -.theme-line .main-links .links a:hover { - text-decoration: none; -} - -.theme-line #category-columns, -.theme-solid #category-columns { - margin: 50px 30px 0; -} - -.theme-line #category-columns h4 { - text-transform: uppercase; - font-weight: 300; - color: #999; - font-size: 14px; -} - -.theme-line #category-columns ul { - list-style: none; - padding: 0; - margin-bottom: 15px; -} - -.theme-line #category-columns ul li a { - padding: 5px 0; - display: block; - font-size: 16px; -} - -.theme-line #category-columns ul .view-all { - font-size: 0.85em; -} - -.theme-line .docs-header { - color: #999; - overflow: hidden; -} - -.theme-line .docs-header h1 { - color: #444; - margin-top: 0; - font-size: 22px; -} - -.theme-line .btn-primary { - border: 0 none; - background-color: $ignite-red; -} - -.theme-line .btn-primary:hover { - background-color: #950d12; -} - -.theme-line .main-content .nav-horizontal a { - box-shadow: 0 0; - border: 0 none; - background-color: #fff; - border-radius: 0; - color: #aaa; - padding: 6px; - margin: 0 14px; -} - -.theme-line .main-content .nav-horizontal a:hover { - color: #999; - border-bottom: 5px solid #ddd; -} - -.theme-line .main-content .nav-horizontal a.active { - border-bottom: 5px solid #888; -} - -.theme-line .navbar-nav, .theme-line .sidebar-nav { - ul li > a.active { - cursor: default; - pointer-events: none; - } -} - -.theme-line .sidebar-nav { - color: #474a54; - padding-bottom: 30px; - - ul { - padding: 0; - list-style: none; - font-size: 14px; - margin: 3px 0 0; - li { - color: #666; - line-height: $input-height; - - span.fa-stack { - margin-right: 5px; - font-size: 12px; - height: 26px; - } - - a { - font-size: 18px; - color: #666; - position: relative; - white-space: nowrap; - overflow: hidden; - -o-text-overflow: ellipsis; - text-overflow: ellipsis; - } - } - } -} - -.theme-line .sidebar-nav ul li a:hover { - text-decoration: none; -} - -.theme-line .select, -.theme-line .typeahead { - li a { - color: #666; - background-color: transparent; - } - - li a:hover { - color: $ignite-red; - } - - .active { - background-color: #eee; - } -} - -.theme-line .sidebar-nav ul li .subcategory { - padding-left: 15px; -} - -.theme-line .sidebar-nav h4 { - margin-top: 2em; - font-weight: normal; - text-transform: uppercase; - font-size: 11px; - margin-bottom: 10px; - color: #bbb; -} - -.theme-line .sidebar-nav h4:first-child { - margin-top: 0; -} - -.theme-line .sidebar-nav .ask { - width: 100%; - text-align: center; - padding: 10px; -} - -.theme-line .border-left .sidebar-nav { - padding-left: 15px; -} - -.theme-line .suggest { - padding: 5px; - display: inline-block; - font-size: 12px; -} - -.header { - padding: 15px; -} - -.header .has-github { - padding-right: 136px; -} - -.header h1.navbar-brand { - height: 40px; - width: 200px; - padding: 0; - margin: 5px 15px 0 0; -} - -.header h1.navbar-brand a { - text-indent: -99999px; - background: no-repeat center center; - display: block; - width: 100%; - height: 100%; - background-size: contain; -} - -.header .nav.navbar-nav.pull-right { - position: relative; - right: -30px; -} - -.header .nav.navbar-nav .not-link { - padding: 15px; - display: inline-block; -} - -.header .nav.navbar-nav .stable, -.header .nav.navbar-nav .beta, -.header .nav.navbar-nav .private { - font-size: 9px; - padding: 3px 5px; - display: inline-block; - line-height: 8px; - border-radius: 3px; - margin-left: 6px; - color: #fff; - top: -2px; - position: relative; - opacity: 0.6; - -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=60)"; - filter: alpha(opacity=60); -} - -.header .nav.navbar-nav a:hover > .stable, -.header .nav.navbar-nav a:hover > .beta, -.header .nav.navbar-nav a:hover > .private { - opacity: 1; - -ms-filter: none; - filter: none; -} - -.header .nav.navbar-nav .beta { - background-color: #59c3d1; -} - -.header .nav.navbar-nav .stable { - background-color: #41b841; -} - -.header .nav.navbar-nav .private { - background-color: #333; -} - -.theme-line header { - border-bottom: 8px solid; -} - -.theme-line header h2 { - color: #aaa; -} - -.theme-line header p { - color: #666; -} - -.theme-line header { - border-bottom-color: $ignite-red; -} - -.theme-line .navbar-nav { - color: #888; -} - -.theme-line .navbar-nav a { - color: #bbb; -} - -.theme-line header a.btn { - background-color: $ignite-red; -} - -.theme-line header a.btn:hover { - background-color: #950d12; -} - -.theme-line header .navbar-nav .tt-cursor { - background-color: $ignite-red; -} - -.theme-line header .navbar-nav a:hover, .theme-line header .navbar-nav .open > a { - color: $ignite-red; -} - -.theme-line .navbar-nav .active a { - //font-weight: bold; - color: $ignite-red; -} - -.theme-line .navbar-nav .active a:hover { - color: #950d12; -} - -.theme-line .main-links .links a:hover { - color: $ignite-red; -} - -.theme-line .main-content a { - color: #666; -} - -.theme-line .main-content a:hover { - color: #950d12; -} - -.theme-line .sidebar-nav ul li a.active:before { - background-color: $ignite-red; -} - -.theme-line .sidebar-nav ul li a.active { - color: $ignite-red; -} - -.theme-line .sidebar-nav ul li a:hover, .theme-line .sidebar-nav ul li a.active:hover { - color: #950d12; -} - -.theme-line .main-content .nav-horizontal a.active { - border-color: $ignite-red; - color: $ignite-red; -} - -.theme-line .main-content .nav-horizontal a:hover { - color: #950d12; -} - -.theme-line .main-content .nav-horizontal a.active:hover { - border-color: #950d12; -} - -.theme-line header .navbar-nav a.active, .theme-line #versions-list li a:hover strong, .theme-line #versions-list li a.active .current, .theme-line #versions-list li a:active .current { - color: $ignite-red; -} - -.theme-line header .navbar-nav a { - font-size: 18px; -} - -.theme-line.body-threes .section-right .threes-nav .btn-default:hover, .theme-line.page-docs.body-threes .section-right .threes-nav .pull-right a:hover { - color: $ignite-red; - border-color: $ignite-red; -} - -.theme-line .section-right { - padding-left: 30px; -} - -.body-overlap .main-content { - margin-top: 30px; -} - -.body-box .main-content, -.body-overlap .main-content { - padding: 30px; - box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1); - background-color: #fff; -} - -body { - font-weight: 400; - font-family: Roboto Slab, serif;; -} - -h1, h2, h3, h4, h5, h6 { - font-weight: 700; - font-family: Roboto Slab, serif; - margin-bottom: 10px; -} - -.submit-vote.submit-vote-parent.voted a.submit-vote-button, .submit-vote.submit-vote-parent a.submit-vote-button:hover { - background-color: $ignite-red; -} - -div.submit-vote.submit-vote-parent.voted a.submit-vote-button:hover { - background-color: #950d12; -} - -a, .link .title { - color: $ignite-red; -} - -a:hover, .link:hover .title { - color: #950d12; -} - -.header h1.navbar-brand a { - background-image: url("#{$logo-path}"); -} - -.header h1.navbar-brand { - width: 96px; -} - -.block-edit-parameters { - text-align: right; - padding-bottom: 5px; -} - -.container-footer { - margin-top: 20px; -} - -/* Modal */ -.modal { - display: block; - overflow: hidden; -} - -.modal .close { - position: absolute; - top: 10px; - right: 10px; - float: none; -} - -// Close icon -.modal-header .close { - margin-right: -2px; -} - -.modal .modal-dialog { - width: 610px; -} - -.modal .modal-content { - border-radius: 0; - background-color: #f7f7f7; -} - -.modal .modal-content .modal-header { - background-color: #fff; - text-align: center; - color: #555; - padding: 15px; - font-family: "myriad-pro", sans-serif; -} - -.modal .modal-content .modal-header h4 { - font-family: "myriad-pro", sans-serif; - font-size: 22px; -} - -.modal .modal-content .modal-header h4 .fa { - display: block; - font-size: 41px; - color: #ddd; - margin-bottom: 5px; -} - -.modal .modal-content .modal-header p { - color: #aaa; - font-size: 1em; - margin: 3px 0 0; -} - -.modal .modal-content .modal-spacer { - padding: 10px 10px 0 10px; -} - -.modal .modal-content .modal-footer { - margin-top: 0; -} - -.modal-body { - padding-top: 15px; -} - -h1.ignite-logo { - background-image: url("#{$logo-path}"); -} - -.block-display-image img { - max-width: 100%; - max-height: 450px; - margin: auto; - display: block; -} - -.greedy { - min-height: 100%; - height: #{"calc(100vh - 290px)"}; -} - -@media (min-width: 768px) { - .navbar-nav > li > a { - padding-top: 18px; - padding-bottom: 10px; - } -} - -.details-row { - padding: 0 10px; -} - -.details-row, .settings-row { - display: block; - margin: 10px 0; - - label.table-header { - line-height: $input-height; - } - - [class*="col-"] { - display: inline-block; - vertical-align: middle; - float: none; - - padding-left: 0 !important; - padding-right: 0 !important; - } - - input[type="checkbox"] { - line-height: 20px; - margin-right: 5px; - } - - .checkbox label { - line-height: 20px; - vertical-align: middle; - } -} - -button { - margin-right: 5px; -} - -h1, -h2, -h3 { - user-select: none; - font-weight: normal; - /* Makes the vertical size of the text the same for all fonts. */ - line-height: 1; -} - -h3 { - color: black; - font-size: 1.2em; - margin-top: 0; - margin-bottom: 1.5em; -} - -table tr:hover { - cursor: pointer; -} - -.btn { - padding: 3px 6px; -} - -button .caret, .btn .caret { - float: right; - margin-left: 5px; - margin-top: 7px; -} - -.base-control { - text-align: left; - padding: 3px 3px; - height: $input-height; -} - -.form-control { - @extend .base-control; - - display: inline-block; - - button { - text-align: left; - } -} - -.theme-line .panel-heading { - padding: 10px 10px; - margin: 0; - - h3 { - margin-bottom: 0; - } - - h3 > a { - color: black; - } -} - -.theme-line .panel-title { - a { - color: $ignite-red; - } - - h3 { - margin-bottom: 20px; - } -} - -.theme-line .panel-body { - padding: 10px 20px; -} - -.theme-line .main-content a.customize { - margin-left: 5px; - color: $ignite-red; -} - -.theme-line .panel-collapse { - margin: 0; -} - -.theme-line table.links { - display: table; - table-layout: fixed; - - td { - padding-left: 18px; - } - - .active a { - color: $ignite-red; - font-weight: bold; - } - - a:hover { - color: #950d12; - } - - a { - color: #666; - } -} - -.theme-line table.links-edit { - @extend table.links; - - margin-top: 5px; - margin-bottom: 5px; - - label { - line-height: $input-height; - color: #666; - } -} - -.theme-line table.links-edit-details { - @extend table.links; - - margin-bottom: 10px; - - label { - line-height: $input-height; - color: #666; - } - - td { - padding: 0; - - .input-tip { - padding: 0; - } - } -} - -.theme-line table.admin { - tr:hover { - cursor: default; - } - - thead > tr th.header { - padding: 0 0 10px; - - div { - padding: 0 - } - } - - margin-bottom: 10px; - - label { - line-height: $input-height; - color: #666; - } - - thead > tr th, td { - padding: 10px 10px; - - .input-tip { - padding: 0; - } - } - - tfoot > tr > td { - padding: 0; - - .pagination { - margin: 10px 0; - - > .active > a { - color: $ignite-red; - font-weight: bold; - border-color: #ddd; - background-color: #eee; - } - } - } -} - -.theme-line table.sql-results { - [class*="col-"] { - padding-left: 0 !important; - padding-right: 0 !important; - } - - td { - padding: 3px 6px; - } - - > thead > tr > td { - padding: 3px 0; - } - - thead > tr > th { - padding: 3px 6px; - - line-height: $input-height; - } -} - -.panel-title a { - font-size: 14px; -} - -.panel-details { - margin-top: 10px; - - padding: 0; - - border-radius: 5px; - border: thin dotted lightgrey; -} - -.table-details { - border-radius: 5px; - border: thin dotted lightgrey; - - margin-top: 10px; - - padding-left: 10px; - padding-right: 5px; -} - -.tooltip.right .tooltip-arrow { - border-right-color: $ignite-red; -} - -.tooltip > .tooltip-inner { - max-width: 400px; - text-align: left; - background-color: $ignite-red; -} - -label { - font-weight: normal; - margin-bottom: 0; -} - -.form-horizontal .checkbox { - padding-top: 0; -} - -.input-tip { - display: block; - overflow: hidden; -} - -.labelField { - float: left; - margin-right: 5px; -} - -.labelFormField { - float: left; - line-height: $input-height; -} - -.form-horizontal .form-group { - margin: 0; -} - -.form-horizontal .has-feedback .form-control-feedback { - right: 0; -} - -.tipField { - float: right; - line-height: $input-height; - margin-left: 5px; -} - -.tipLabel { - font-size: 14px; - margin-left: 5px; -} - -.fieldSep { - float: right; - line-height: $input-height; - margin: 0 5px; -} - -.fieldButton { - float: right; - margin-left: 5px; - margin-right: 0; -} - -.fa-plus { - cursor: pointer; -} - -.fa-remove { - color: $ignite-red; - cursor: pointer; -} - -.fa-floppy-o { - cursor: pointer; -} - -.fa-arrow-up { - cursor: pointer; -} - -.fa-arrow-down { - cursor: pointer; -} - -label.required:after { - color: $ignite-red; - content: ' *'; - display: inline; -} - -.blank { - visibility: hidden; -} - -.alert { - outline: 0 -} - -.alert.bottom, .alert.bottom-left, .alert.bottom-right, .alert.top, -.alert.top-left, .alert.top-right { - position: fixed; - z-index: 1050; - margin: 20px -} - -.alert.top, .alert.top-left, .alert.top-right { - top: 50px -} - -.alert.top { - right: 0; - left: 0 -} - -.alert.top-right { - right: 0 -} - -.alert.top-right .close { - padding-left: 10px -} - -.alert.top-left { - left: 0 -} - -.alert.top-left .close { - padding-right: 10px -} - -.alert.bottom, .alert.bottom-left, .alert.bottom-right { - bottom: 0 -} - -.alert.bottom { - right: 0; - left: 0 -} - -.alert.bottom-right { - right: 0 -} - -.alert.bottom-right .close { - padding-left: 10px -} - -.alert.bottom-left { - left: 0 -} - -.alert.bottom-left .close { - padding-right: 10px -} - -// Summary page -#cfgResult textarea { - font-family: monospace; - font-size: 12px; -} - -input[type="number"]::-webkit-outer-spin-button, -input[type="number"]::-webkit-inner-spin-button { - -webkit-appearance: none; - margin: 0; -} - -input[type="number"] { - -moz-appearance: textfield; -} - -input.ng-dirty.ng-invalid, button.ng-dirty.ng-invalid { - border-color: $ignite-red; - - :focus { - border-color: $ignite-red; - } -} - -.form-control-feedback { - display: inline-block; - color: $ignite-red; - right: 18px; - line-height: $input-height; - pointer-events: initial; -} - -.syntaxhighlighter { - padding: 10px 5px; - border-radius: 6px; -} - -.theme-line table.links-edit-small-padding { - @extend table.links; - - label { - line-height: $input-height; - color: #666; - } - - a { - line-height: $input-height; - } - - input[type="checkbox"] { - line-height: 20px; - margin-right: 5px; - } - - .checkbox label { - line-height: 20px; - vertical-align: middle; - } - - th { - text-align: center; - } - - td { - padding-left: 10px; - } - - margin-top: 10px; -} - -.nav-tabs > li > a { - padding: 5px 5px; -} - -.viewedUser { - position: absolute; - width: 100%; - left: 0; - - text-align: center; - - margin-top: -15px; - - background-color: #f8d5d8; -} - -a { - cursor: pointer; -} - -.st-sort-ascent:after { - content: '\25B2'; -} - -.st-sort-descent:after { - content: '\25BC'; -} - -.panel { - margin-bottom: 0; -} - -.panel-group { - margin-bottom: 0; -} - -.panel-group .panel + .panel { - margin-top: 20px; -} - -.margin-top-dflt { - margin-top: 10px; -} - -.margin-bottom-dflt { - margin-bottom: 10px; -} - -.margin-dflt { - margin-top: 10px; - margin-bottom: 10px; -} - -.padding-top-dflt { - padding-top: 10px; -} - -.padding-bottom-dflt { - padding-bottom: 10px; -} - -.padding-dflt { - padding-top: 10px; - padding-bottom: 10px; -} - -.theme-line .panel-title h3 { - margin-top: 20px; - margin-bottom: 20px; -} - -.block-callout-parent { - background-color: $ignite-block-callout-background; - overflow: hidden; -} - -.block-callout { - background-color: $ignite-block-callout-background; - display: inline-block; - vertical-align: top; - width: 50%; - - i { - padding: 10px 5px 0 10px; - color: $ignite-block-callout; - } - - ul { - padding-left: 20px; - margin-bottom: 0; - } - - p { - padding: 5px 0 10px 10px; - margin: 0; - } - - label { - font-weight: bold; - color: $ignite-block-callout; - } -} - -.block-callout-border { - border-left: 5px solid; - border-color: $ignite-block-callout; -} - -.labelHeader { - font-weight: bold; -} - -.ace_editor, #ace_document { - margin: 0.65em 0 0 0; - - width: 100%; - height: 400px; - - .ace_gutter { - background: transparent !important; - border: 1px #ddd; - border-right-style: solid; - } - - .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell { - padding-left: 0.65em; - padding-right: 0.9em; - } -} - -.loading-indicator { - box-sizing: border-box; - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - width: 100%; - text-align: center; - padding: 0.7em; - - :before { - display: inline-block; - margin: 0 0.4em; - min-width: 1em; - min-height: 1em; - border: 4px solid #646464; - border-right-color: #e6e6e6; - border-left-color: #e6e6e6; - content: ""; - -webkit-animation: halfspin 1s ease infinite; - -moz-animation: halfspin 1s ease infinite; - -o-animation: halfspin 1s ease infinite; - animation: halfspin 1s ease infinite; - border-radius: 100%; - } -} - -@-webkit-keyframes halfspin { - to { - -webkit-transform: rotate(180deg); - -moz-transform: rotate(180deg); - transform: rotate(180deg); - } -} - -@-moz-keyframes halfspin { - to { - -webkit-transform: rotate(180deg); - -moz-transform: rotate(180deg); - transform: rotate(180deg); - } -} - -@keyframes halfspin { - to { - -webkit-transform: rotate(180deg); - -moz-transform: rotate(180deg); - transform: rotate(180deg); - } -} http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/routes/admin.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/routes/admin.js b/modules/web-control-center/src/main/js/routes/admin.js deleted file mode 100644 index 5af72f7..0000000 --- a/modules/web-control-center/src/main/js/routes/admin.js +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var router = require('express').Router(); -var db = require('../db'); - -router.get('/', function (req, res) { - res.render('settings/admin'); -}); - -/** - * Get list of user accounts. - */ -router.post('/list', function (req, res) { - db.Account.find({}).sort('username').exec(function (err, users) { - if (err) - return res.status(500).send(err.message); - - res.json(users); - }); -}); - -router.post('/remove', function (req, res) { - var userId = req.body.userId; - - db.Account.findByIdAndRemove(userId, function (err) { - if (err) - return res.status(500).send(err); - - res.sendStatus(200); - }); -}); - -router.post('/save', function (req, res) { - var userId = req.body.userId; - var adminFlag = req.body.adminFlag; - - db.Account.findByIdAndUpdate(userId, {admin: adminFlag}, function (err) { - if (err) - return res.status(500).send(err.message); - - res.sendStatus(200); - }); -}); - -router.get('/become', function (req, res) { - var viewedUserId = req.query.viewedUserId; - - if (!viewedUserId) { - req.session.viewedUser = null; - - return res.redirect('/admin'); - } - - db.Account.findById(viewedUserId).exec(function (err, viewedUser) { - if (err) - return res.sendStatus(404); - - req.session.viewedUser = viewedUser; - - res.redirect('/'); - }) -}); - -module.exports = router; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/routes/caches.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/routes/caches.js b/modules/web-control-center/src/main/js/routes/caches.js deleted file mode 100644 index 24152af..0000000 --- a/modules/web-control-center/src/main/js/routes/caches.js +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var router = require('express').Router(); -var db = require('../db'); - -/* GET caches page. */ -router.get('/', function (req, res) { - res.render('configuration/caches'); -}); - -/** - * Get spaces and caches accessed for user account. - * - * @param req Request. - * @param res Response. - */ -router.post('/list', function (req, res) { - var user_id = req.currentUserId(); - - // Get owned space and all accessed space. - db.Space.find({$or: [{owner: user_id}, {usedBy: {$elemMatch: {account: user_id}}}]}, function (err, spaces) { - if (err) - return res.status(500).send(err.message); - - var space_ids = spaces.map(function (value) { - return value._id; - }); - - // Get all caches type metadata for spaces. - db.CacheTypeMetadata.find({space: {$in: space_ids}}, '_id name kind', function (err, metadatas) { - if (err) - return res.status(500).send(err); - - // Get all caches for spaces. - db.Cache.find({space: {$in: space_ids}}).sort('name').exec(function (err, caches) { - if (err) - return res.status(500).send(err.message); - - var metadatasJson = metadatas.map(function (meta) { - return {value: meta._id, label: meta.name, kind: meta.kind}; - }); - - res.json({spaces: spaces, metadatas: metadatasJson, caches: caches}); - }); - }); - }); -}); - -/** - * Save cache. - */ -router.post('/save', function (req, res) { - if (req.body._id) - db.Cache.update({_id: req.body._id}, req.body, {upsert: true}, function (err) { - if (err) - return res.status(500).send(err.message); - - res.send(req.body._id); - }); - else { - db.Cache.findOne({space: req.body.space, name: req.body.name}, function (err, cache) { - if (err) - return res.status(500).send(err.message); - - if (cache) - return res.status(500).send('Cache with name: "' + cache.name + '" already exist.'); - - (new db.Cache(req.body)).save(function (err, cache) { - if (err) - return res.status(500).send(err.message); - - res.send(cache._id); - }); - }); - } -}); - -/** - * Remove cache by ._id. - */ -router.post('/remove', function (req, res) { - db.Cache.remove(req.body, function (err) { - if (err) - return res.status(500).send(err.message); - - res.sendStatus(200); - }) -}); - -module.exports = router; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/routes/clusters.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/routes/clusters.js b/modules/web-control-center/src/main/js/routes/clusters.js deleted file mode 100644 index 683630e..0000000 --- a/modules/web-control-center/src/main/js/routes/clusters.js +++ /dev/null @@ -1,104 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var router = require('express').Router(); -var db = require('../db'); - -/* GET clusters page. */ -router.get('/', function (req, res) { - res.render('configuration/clusters'); -}); - -/** - * Get spaces and clusters accessed for user account. - * - * @param req Request. - * @param res Response. - */ -router.post('/list', function (req, res) { - var user_id = req.currentUserId(); - - // Get owned space and all accessed space. - db.Space.find({$or: [{owner: user_id}, {usedBy: {$elemMatch: {account: user_id}}}]}, function (err, spaces) { - if (err) - return res.status(500).send(err.message); - - var space_ids = spaces.map(function (value) { - return value._id; - }); - - db.Cache.find({space: {$in: space_ids}}, '_id name swapEnabled', function (err, caches) { - if (err) - return res.status(500).send(err); - - // Get all clusters for spaces. - db.Cluster.find({space: {$in: space_ids}}).sort('name').exec(function (err, clusters) { - if (err) - return res.status(500).send(err.message); - - var cachesJson = caches.map(function (cache) { - return {value: cache._id, label: cache.name, swapEnabled: cache.swapEnabled}; - }); - - res.json({spaces: spaces, caches: cachesJson, clusters: clusters}); - }); - }); - }); -}); - -/** - * Save cluster. - */ -router.post('/save', function (req, res) { - if (req.body._id) - db.Cluster.update({_id: req.body._id}, req.body, {upsert: true}, function (err) { - if (err) - return res.status(500).send(err.message); - - res.send(req.body._id); - }); - else { - db.Cluster.findOne({space: req.body.space, name: req.body.name}, function (err, cluster) { - if (err) - return res.status(500).send(err.message); - - if (cluster) - return res.status(500).send('Cluster with name: "' + cluster.name + '" already exist.'); - - (new db.Cluster(req.body)).save(function (err, cluster) { - if (err) - return res.status(500).send(err.message); - - res.send(cluster._id); - }); - }); - } -}); - -/** - * Remove cluster by ._id. - */ -router.post('/remove', function (req, res) { - db.Cluster.remove(req.body, function (err) { - if (err) - return res.status(500).send(err.message); - - res.sendStatus(200); - }) -}); - -module.exports = router; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/routes/generator/common.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/routes/generator/common.js b/modules/web-control-center/src/main/js/routes/generator/common.js deleted file mode 100644 index 44ddf31..0000000 --- a/modules/web-control-center/src/main/js/routes/generator/common.js +++ /dev/null @@ -1,312 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -var _ = require('lodash'); - -exports.isDefined = function (v) { - return !(v === undefined || v === null); -}; - -exports.mainComment = mainComment; - -function mainComment() { - return 'This configuration was generated by Ignite Control Center (' - + formatDate(new Date()) + ')'; -} - -function addLeadingZero(numberStr, minSize) { - if (typeof (numberStr) != 'string') - numberStr = '' + numberStr; - - while (numberStr.length < minSize) { - numberStr = '0' + numberStr; - } - - return numberStr; -} - -exports.formatDate = formatDate; - -function formatDate(date) { - var dd = addLeadingZero(date.getDate(), 2); - var mm = addLeadingZero(date.getMonth() + 1, 2); - - var yyyy = date.getFullYear(); - - return mm + '/' + dd + '/' + yyyy + ' ' + addLeadingZero(date.getHours(), 2) + ':' + addLeadingZero(date.getMinutes(), 2); -} - -exports.builder = function () { - var res = []; - - res.deep = 0; - res.lineStart = true; - - res.append = function (s) { - if (this.lineStart) { - for (var i = 0; i < this.deep; i++) - this.push(' '); - - this.lineStart = false; - } - - this.push(s); - - return this; - }; - - res.line = function (s) { - if (s) - this.append(s); - - this.push('\n'); - this.lineStart = true; - - return this; - }; - - res.startBlock = function (s) { - if (s) - this.append(s); - - this.push('\n'); - this.lineStart = true; - this.deep++; - - return this; - }; - - res.endBlock = function (s) { - this.deep--; - - if (s) - this.append(s); - - this.push('\n'); - this.lineStart = true; - - return this; - }; - - res.emptyLineIfNeeded = function () { - if (this.needEmptyLine) { - this.line(); - - this.needEmptyLine = false; - - return true; - } - - return false; - }; - - res.imports = {}; - - res.importClass = function (fullClassName) { - var dotIdx = fullClassName.lastIndexOf('.'); - - var shortName; - - if (dotIdx > 0) - shortName = fullClassName.substr(dotIdx + 1); - else - shortName = fullClassName; - - if (this.imports[shortName]) { - if (this.imports[shortName] != fullClassName) - throw "Class name conflict: " + this.imports[shortName] + ' and ' + fullClassName; - } - else { - this.imports[shortName] = fullClassName; - } - - return shortName; - }; - - res.generateImports = function () { - var res = []; - - for (var clsName in this.imports) { - if (this.imports.hasOwnProperty(clsName)) - res.push('import ' + this.imports[clsName] + ';'); - } - - return res.join('\n') - }; - - return res; -}; - -function ClassDescriptor(className, fields) { - this.className = className; - this.fields = fields; -} - -exports.evictionPolicies = { - 'LRU': new ClassDescriptor('org.apache.ignite.cache.eviction.lru.LruEvictionPolicy', - {batchSize: null, maxMemorySize: null, maxSize: null}), - 'RND': new ClassDescriptor('org.apache.ignite.cache.eviction.random.RandomEvictionPolicy', {maxSize: null}), - 'FIFO': new ClassDescriptor('org.apache.ignite.cache.eviction.fifo.FifoEvictionPolicy', - {batchSize: null, maxMemorySize: null, maxSize: null}), - 'SORTED': new ClassDescriptor('org.apache.ignite.cache.eviction.sorted.SortedEvictionPolicy', - {batchSize: null, maxMemorySize: null, maxSize: null}) -}; - -exports.marshallers = { - OptimizedMarshaller: new ClassDescriptor('org.apache.ignite.marshaller.optimized.OptimizedMarshaller', { - poolSize: null, - requireSerializable: null - }), - JdkMarshaller: new ClassDescriptor('org.apache.ignite.marshaller.jdk.JdkMarshaller', {}) -}; - -var javaBuildInClasses = { - BigDecimal: {className: 'java.math.Boolean'}, - Boolean: {className: 'java.lang.Boolean'}, - Byte: {className: 'java.lang.Byte'}, - Date: {className: 'java.sql.Date'}, - Double: {className: 'java.lang.Double'}, - Float: {className: 'java.lang.Float'}, - Integer: {className: 'java.lang.Integer'}, - Long: {className: 'java.lang.Long'}, - Short: {className: 'java.lang.Short'}, - String: {className: 'java.lang.String'}, - Time: {className: 'java.sql.Time'}, - Timestamp: {className: 'java.sql.Timestamp'}, - UUID: {className: 'java.util.UUID'} -}; - -exports.javaBuildInClass = function (className) { - var fullClassName = javaBuildInClasses[className]; - - if (fullClassName) - return fullClassName.className; - - return className; -}; - -exports.knownClasses = { - Oracle: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.OracleDialect', {}), - DB2: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.DB2Dialect', {}), - SQLServer: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.SQLServerDialect', {}), - MySQL: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.MySQLDialect', {}), - PostgreSQL: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.BasicJdbcDialect', {}), - H2: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.dialect.H2Dialect', {}) -}; - -exports.dataSources = { - Oracle: 'oracle.jdbc.pool.OracleDataSource', - DB2: 'com.ibm.db2.jcc.DB2ConnectionPoolDataSource', - SQLServer: 'com.microsoft.sqlserver.jdbc.SQLServerDataSource', - MySQL: 'com.mysql.jdbc.jdbc2.optional.MysqlDataSource', - PostgreSQL: 'org.postgresql.ds.PGPoolingDataSource', - H2: 'org.h2.jdbcx.JdbcDataSource' -}; - -exports.storeFactories = { - CacheJdbcPojoStoreFactory: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.CacheJdbcPojoStoreFactory', { - dataSourceBean: null, - dialect: {type: 'className'} - }), - - CacheJdbcBlobStoreFactory: new ClassDescriptor('org.apache.ignite.cache.store.jdbc.CacheJdbcBlobStoreFactory', { - user: null, - dataSourceBean: null, - initSchema: null, - createTableQuery: null, - loadQuery: null, - insertQuery: null, - updateQuery: null, - deleteQuery: null - }), - - CacheHibernateBlobStoreFactory: new ClassDescriptor('org.apache.ignite.cache.store.hibernate.CacheHibernateBlobStoreFactory', { - hibernateProperties: {type: 'propertiesAsList', propVarName: 'props'} - }) -}; - -exports.atomicConfiguration = new ClassDescriptor('org.apache.ignite.configuration.AtomicConfiguration', { - backups: null, - cacheMode: {type: 'enum', enumClass: 'CacheMode'}, - atomicSequenceReserveSize: null -}); - -exports.swapSpaceSpi = new ClassDescriptor('org.apache.ignite.spi.swapspace.file.FileSwapSpaceSpi', { - baseDirectory: null, - readStripesNumber: null, - maximumSparsity: {type: 'float'}, - maxWriteQueueSize: null, - writeBufferSize: null -}); - -exports.transactionConfiguration = new ClassDescriptor('org.apache.ignite.configuration.TransactionConfiguration', { - defaultTxConcurrency: {type: 'enum', enumClass: 'TransactionConcurrency'}, - transactionIsolation: {type: 'TransactionIsolation', setterName: 'defaultTxIsolation'}, - defaultTxTimeout: null, - pessimisticTxLogLinger: null, - pessimisticTxLogSize: null, - txSerializableEnabled: null -}); - -exports.hasProperty = function (obj, props) { - for (var propName in props) { - if (props.hasOwnProperty(propName)) { - if (obj[propName]) - return true; - } - } - - return false; -}; - -/** - * Generate properties file with properties stubs for stores data sources. - * - * @param cluster Configuration to process. - * @returns {string} Generated content. - */ -exports.generateProperties = function (cluster) { - var res = exports.builder(); - - var datasources = []; - - if (cluster.caches && cluster.caches.length > 0) { - _.forEach(cluster.caches, function (cache) { - if (cache.cacheStoreFactory && cache.cacheStoreFactory.kind) { - var storeFactory = cache.cacheStoreFactory[cache.cacheStoreFactory.kind]; - - if (storeFactory.dialect) { - var beanId = storeFactory.dataSourceBean; - - if (!_.contains(datasources, beanId)) { - datasources.push(beanId); - - res.line(beanId + '.jdbc.url=YOUR_JDBC_URL'); - res.line(beanId + '.jdbc.username=YOUR_USER_NAME'); - res.line(beanId + '.jdbc.password=YOUR_PASSWORD'); - res.line(); - } - } - } - }); - } - - if (datasources.length > 0) - return '# ' + mainComment() + '\n\n' + res.join(); - - return undefined; -}; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96522874/modules/web-control-center/src/main/js/routes/generator/docker.js ---------------------------------------------------------------------- diff --git a/modules/web-control-center/src/main/js/routes/generator/docker.js b/modules/web-control-center/src/main/js/routes/generator/docker.js deleted file mode 100644 index 93faf8e..0000000 --- a/modules/web-control-center/src/main/js/routes/generator/docker.js +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -exports.generateClusterConfiguration = function(cluster, os) { - if (!os) - os = 'debian:8'; - - return "" + - "# Start from a OS image.\n"+ - "FROM " + os + "\n"+ - "\n"+ - "# Install tools.\n"+ - "RUN apt-get update && apt-get install -y --fix-missing \\\n"+ - " wget \\\n"+ - " dstat \\\n"+ - " maven \\\n"+ - " git\n"+ - "\n"+ - "# Install Oracle JDK.\n"+ - "RUN mkdir /opt/jdk\n"+ - "\n"+ - "RUN wget --header \"Cookie: oraclelicense=accept-securebackup-cookie\" \\\n"+ - " http://download.oracle.com/otn-pub/java/jdk/7u79-b15/jdk-7u79-linux-x64.tar.gz\n"+ - "\n"+ - "RUN tar -zxf jdk-7u79-linux-x64.tar.gz -C /opt/jdk\n"+ - "\n"+ - "RUN rm jdk-7u79-linux-x64.tar.gz\n"+ - "\n"+ - "RUN update-alternatives --install /usr/bin/java java /opt/jdk/jdk1.7.0_79/bin/java 100\n"+ - "\n"+ - "RUN update-alternatives --install /usr/bin/javac javac /opt/jdk/jdk1.7.0_79/bin/javac 100\n"+ - "\n"+ - "# Sets java variables.\n"+ - "ENV JAVA_HOME /opt/jdk/jdk1.7.0_79/\n"+ - "\n"+ - "# Create working directory\n"+ - "WORKDIR /home\n"+ - "\n"+ - "RUN wget -O ignite.zip http://tiny.cc/updater/download_ignite.php && unzip ignite.zip && rm ignite.zip\n"+ - "\n"+ - "COPY *.xml /tmp/\n"+ - "\n"+ - "RUN mv /tmp/*.xml /home/$(ls)/config"; -};