[#749] Report non @Shareable handler name that has been re-added.
This commit is contained in:
parent
5d2b41c094
commit
fea7475080
@ -627,7 +627,8 @@ public class DefaultChannelPipeline implements ChannelPipeline {
|
|||||||
ChannelStateHandlerAdapter h = (ChannelStateHandlerAdapter) handler;
|
ChannelStateHandlerAdapter h = (ChannelStateHandlerAdapter) handler;
|
||||||
if (!h.isSharable() && h.added) {
|
if (!h.isSharable() && h.added) {
|
||||||
throw new ChannelHandlerLifeCycleException(
|
throw new ChannelHandlerLifeCycleException(
|
||||||
"Only a @Sharable handler can be added or removed multiple times.");
|
h.getClass().getName() +
|
||||||
|
" is not a @Sharable handler, so can't be added or removed multiple times.");
|
||||||
}
|
}
|
||||||
h.added = true;
|
h.added = true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user