HTTP/2 DefaultHttp2Connection recursive call fix

Motivation:
There are methods to manipulate the prioritzable count for streams which have the '0' postfix which are designed to be used during recursion.  However these methods are calling out to an external method without the '0' during the recursive process.  This is doing uneccessary conditional checks during recursion.

Modifications:
Change the decrementPrioritizableForTree to decrementPrioritizableForTree0 while in recursive method.
Change the incrementPrioritizableForTree to incrementPrioritizableForTree0 while in recursive method.

Result:
Less overhead during recursive calls.
This commit is contained in:
Scott Mitchell 2015-04-06 17:11:20 -07:00
parent cee3cc25fc
commit ac8b05e0fb

View File

@ -465,7 +465,7 @@ public class DefaultHttp2Connection implements Http2Connection {
assert amt > 0;
prioritizableForTree += amt;
if (parent != null && parent != oldParent) {
parent.incrementPrioritizableForTree(amt, oldParent);
parent.incrementPrioritizableForTree0(amt, oldParent);
}
}
@ -487,7 +487,7 @@ public class DefaultHttp2Connection implements Http2Connection {
assert amt > 0;
prioritizableForTree -= amt;
if (parent != null) {
parent.decrementPrioritizableForTree(amt);
parent.decrementPrioritizableForTree0(amt);
}
}