Fix overriden methos not called
Motivation: channelConnected was override but super was never called, while it should. It prevents next handlers to be informed of the connection. Also add one missing information in the toString method. Modifications: Add the super corresponding call, and add checkInterval to the toString() method Result; Now, if the channelConnected method is correctly passed to the the next handler.
This commit is contained in:
parent
cfa1074285
commit
3a3552c40a
@ -608,7 +608,7 @@ public abstract class AbstractTrafficShapingHandler extends
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TrafficShaping with Write Limit: " + writeLimit +
|
||||
" Read Limit: " + readLimit + " and Counter: " +
|
||||
" Read Limit: " + readLimit + " every: " + checkInterval + " and Counter: " +
|
||||
(trafficCounter != null? trafficCounter.toString() : "none");
|
||||
}
|
||||
}
|
||||
|
@ -208,6 +208,7 @@ public class GlobalTrafficShapingHandler extends AbstractTrafficShapingHandler {
|
||||
Integer key = ctx.getChannel().getId();
|
||||
List<ToSend> messagesQueue = new LinkedList<ToSend>();
|
||||
messagesQueues.put(key, messagesQueue);
|
||||
super.channelConnected(ctx, e);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user