CLOUDSTACK-8231: use hardcoded list of LB algorithms as backup

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This commit is contained in:
Rohit Yadav 2015-03-27 09:28:16 +05:30
parent 0fe4acf525
commit 6f2facfa39
1 changed files with 16 additions and 1 deletions

View File

@ -1678,7 +1678,22 @@
'algorithm': {
label: 'label.algorithm',
select: function(args) {
var data = getLBAlgorithms(args.context.networks[0]);
var data = [{
id: 'roundrobin',
name: 'roundrobin',
description: _l('label.lb.algorithm.roundrobin')
}, {
id: 'leastconn',
name: 'leastconn',
description: _l('label.lb.algorithm.leastconn')
}, {
id: 'source',
name: 'source',
description: _l('label.lb.algorithm.source')
}];
if (typeof args.context != 'undefined') {
data = getLBAlgorithms(args.context.networks[0]);
}
args.response.success({
data: data
});