NIFI-3009:

- Fixing NaN error when backpressure is not configured.
This closes #1200
This commit is contained in:
Matt Gilman 2016-11-09 09:41:57 -05:00 committed by Scott Aslan
parent b426de1793
commit f83863ebae
1 changed files with 10 additions and 2 deletions

View File

@ -1362,7 +1362,11 @@ nf.Connection = (function () {
.duration(400)
.attr({
'width': function (d) {
return (backpressureBarWidth * d.status.aggregateSnapshot.percentUseBytes) / 100;
if (nf.Common.isDefinedAndNotNull(d.status.aggregateSnapshot.percentUseBytes)) {
return (backpressureBarWidth * d.status.aggregateSnapshot.percentUseBytes) / 100;
} else {
return 0;
}
}
}).each('end', function () {
backpressurePercentDataSize
@ -1398,7 +1402,11 @@ nf.Connection = (function () {
.duration(400)
.attr({
'width': function (d) {
return (backpressureBarWidth * d.status.aggregateSnapshot.percentUseCount) / 100;
if (nf.Common.isDefinedAndNotNull(d.status.aggregateSnapshot.percentUseCount)) {
return (backpressureBarWidth * d.status.aggregateSnapshot.percentUseCount) / 100;
} else {
return 0;
}
}
}).each('end', function () {
backpressurePercentObject