You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by ak...@apache.org on 2015/06/24 05:05:26 UTC
[1/2] incubator-ignite git commit: # IGNITE-843 Fixed eviction policy.
Repository: incubator-ignite
Updated Branches:
refs/heads/ignite-843 b3abf11da -> 65f4fcaa2
# IGNITE-843 Fixed eviction policy.
Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/8c46a461
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8c46a461
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8c46a461
Branch: refs/heads/ignite-843
Commit: 8c46a4619e7f10326cfb1d47c71051f3fe0de6ca
Parents: b3abf11
Author: AKuznetsov <ak...@gridgain.com>
Authored: Wed Jun 24 10:04:58 2015 +0700
Committer: AKuznetsov <ak...@gridgain.com>
Committed: Wed Jun 24 10:04:58 2015 +0700
----------------------------------------------------------------------
modules/webconfig/nodejs/db.js | 43 +++--
.../nodejs/public/form-models/caches.json | 168 ++++++++++++++++++-
2 files changed, 185 insertions(+), 26 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8c46a461/modules/webconfig/nodejs/db.js
----------------------------------------------------------------------
diff --git a/modules/webconfig/nodejs/db.js b/modules/webconfig/nodejs/db.js
index 06169d5..f49e35f 100644
--- a/modules/webconfig/nodejs/db.js
+++ b/modules/webconfig/nodejs/db.js
@@ -52,6 +52,28 @@ var DiscoveryObj = {
addresses: [String]
};
+var evictionPolicyType = {
+ 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
+ }
+};
+
// Define cache model.
var CacheSchema = new Schema({
space: {type: ObjectId, ref: 'Space'},
@@ -64,22 +86,7 @@ var CacheSchema = new Schema({
offHeapMaxMemory: Number,
swapEnabled: Boolean,
- evictionPolicy: {
- kind: {type: String, enum: ['LRU', 'RND', 'FIFO', 'Sorted']},
- LRU: {
- batchSize: Number,
- maxMemorySize: Number
- },
- RND: {
- batchSize: Number
- },
- FIFO: {
- batchSize: Number
- },
- SORTED: {
- batchSize: Number
- }
- },
+ evictionPolicy: evictionPolicyType,
rebalanceMode: {type: String, enum: ['SYNC', 'ASYNC', 'NONE']},
rebalanceThreadPoolSize: Number,
@@ -120,7 +127,7 @@ var CacheSchema = new Schema({
transactionManagerLookupClassName: String,
sqlEscapeAll: Boolean,
- sqlOnheapRowCacheSize: Boolean,
+ sqlOnheapRowCacheSize: Number,
longQueryWarningTimeout: Number,
indexedTypes: [{keyClass: String, valueClass: String}],
sqlFunctionClasses: [String],
@@ -131,7 +138,7 @@ var CacheSchema = new Schema({
maxConcurrentAsyncOperations: Number,
nearConfiguration: {
nearStartSize: Number,
- nearEvictionPolicy: {type: String, enum: ['LRU', 'RND', 'FIFO', 'Sorted']},
+ nearEvictionPolicy: evictionPolicyType,
atomicSequenceReserveSize: Number
}
});
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8c46a461/modules/webconfig/nodejs/public/form-models/caches.json
----------------------------------------------------------------------
diff --git a/modules/webconfig/nodejs/public/form-models/caches.json b/modules/webconfig/nodejs/public/form-models/caches.json
index d6085ae..0d34802 100644
--- a/modules/webconfig/nodejs/public/form-models/caches.json
+++ b/modules/webconfig/nodejs/public/form-models/caches.json
@@ -115,12 +115,21 @@
},
{
"label": "Max memory size",
- "type": "text",
+ "type": "number",
"model": "maxMemorySize",
"placeholder": "0",
"tip": [
"Maximum allowed cache size in bytes."
]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
}
]
},
@@ -128,10 +137,13 @@
"expanded": false,
"fields": [
{
- "label": "Batch size",
- "type": "text",
- "model": "batchSize",
- "placeholder": "1"
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
}
]
},
@@ -143,6 +155,24 @@
"type": "text",
"model": "batchSize",
"placeholder": "1"
+ },
+ {
+ "label": "Max memory size",
+ "type": "number",
+ "model": "maxMemorySize",
+ "placeholder": "0",
+ "tip": [
+ "Maximum allowed cache size in bytes."
+ ]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
}
]
},
@@ -154,6 +184,24 @@
"type": "text",
"model": "batchSize",
"placeholder": "1"
+ },
+ {
+ "label": "Max memory size",
+ "type": "number",
+ "model": "maxMemorySize",
+ "placeholder": "0",
+ "tip": [
+ "Maximum allowed cache size in bytes."
+ ]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
}
]
}
@@ -176,13 +224,117 @@
},
{
"label": "Eviction policy",
- "type": "dropdown",
- "model": "nearEvictionPolicy",
+ "type": "dropdown-details",
+ "group": "nearEvictionPolicy",
+ "model": "kind",
"placeholder": "Choose eviction policy",
"items": "evictionPolicies",
"tip": [
"Cache expiration policy."
- ]
+ ],
+ "details": {
+ "LRU": {
+ "expanded": false,
+ "fields": [
+ {
+ "label": "Batch size",
+ "type": "text",
+ "model": "batchSize",
+ "placeholder": "1"
+ },
+ {
+ "label": "Max memory size",
+ "type": "number",
+ "model": "maxMemorySize",
+ "placeholder": "0",
+ "tip": [
+ "Maximum allowed cache size in bytes."
+ ]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
+ }
+ ]
+ },
+ "RND": {
+ "expanded": false,
+ "fields": [
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
+ }
+ ]
+ },
+ "FIFO": {
+ "expanded": false,
+ "fields": [
+ {
+ "label": "Batch size",
+ "type": "text",
+ "model": "batchSize",
+ "placeholder": "1"
+ },
+ {
+ "label": "Max memory size",
+ "type": "number",
+ "model": "maxMemorySize",
+ "placeholder": "0",
+ "tip": [
+ "Maximum allowed cache size in bytes."
+ ]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
+ }
+ ]
+ },
+ "SORTED": {
+ "expanded": false,
+ "fields": [
+ {
+ "label": "Batch size",
+ "type": "text",
+ "model": "batchSize",
+ "placeholder": "1"
+ },
+ {
+ "label": "Max memory size",
+ "type": "number",
+ "model": "maxMemorySize",
+ "placeholder": "0",
+ "tip": [
+ "Maximum allowed cache size in bytes."
+ ]
+ },
+ {
+ "label": "Max size",
+ "type": "number",
+ "model": "maxSize",
+ "placeholder": "100000",
+ "tip": [
+ "Maximum allowed size of cache before entry will start getting evicted."
+ ]
+ }
+ ]
+ }
+ }
}
]
},
[2/2] incubator-ignite git commit: # IGNITE-843 Fixed form name.
Posted by ak...@apache.org.
# IGNITE-843 Fixed form name.
Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/65f4fcaa
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/65f4fcaa
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/65f4fcaa
Branch: refs/heads/ignite-843
Commit: 65f4fcaa271cc5c05625a516dff039e4f407bf12
Parents: 8c46a46
Author: AKuznetsov <ak...@gridgain.com>
Authored: Wed Jun 24 10:05:19 2015 +0700
Committer: AKuznetsov <ak...@gridgain.com>
Committed: Wed Jun 24 10:05:19 2015 +0700
----------------------------------------------------------------------
modules/webconfig/nodejs/views/clusters.jade | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65f4fcaa/modules/webconfig/nodejs/views/clusters.jade
----------------------------------------------------------------------
diff --git a/modules/webconfig/nodejs/views/clusters.jade b/modules/webconfig/nodejs/views/clusters.jade
index 492ca1d..2f5bce0 100644
--- a/modules/webconfig/nodejs/views/clusters.jade
+++ b/modules/webconfig/nodejs/views/clusters.jade
@@ -65,5 +65,5 @@ block content
.panel-title
h3
a(bs-collapse-toggle='0' ng-click='expanded = !expanded;') {{expanded ? 'Hide advanced settings...' : 'Show advanced settings...'}}
- button.btn.btn-primary(ng-disabled='clustersForm.$invalid' ng-click='saveItem()') Save
+ button.btn.btn-primary(ng-disabled='inputForm.$invalid' ng-click='saveItem()') Save
button.btn.btn-primary(ng-show='backupItem._id' ng-click='removeItem()') Remove
\ No newline at end of file