This should be volatile anyhow
This commit is contained in:
parent
0066f9c3ff
commit
28bac1978f
@ -49,7 +49,7 @@ public class LocalTimeClientHandler extends SimpleChannelUpstreamHandler {
|
||||
LocalTimeClientHandler.class.getName());
|
||||
|
||||
// Stateful properties
|
||||
private Channel channel;
|
||||
private volatile Channel channel;
|
||||
private final BlockingQueue<LocalTimes> answer = new LinkedBlockingQueue<LocalTimes>();
|
||||
|
||||
public List<String> getLocalTimes(Collection<String> cities) {
|
||||
@ -106,10 +106,10 @@ public class LocalTimeClientHandler extends SimpleChannelUpstreamHandler {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void channelConnected(ChannelHandlerContext ctx, ChannelStateEvent e)
|
||||
public void channelOpen(ChannelHandlerContext ctx, ChannelStateEvent e)
|
||||
throws Exception {
|
||||
channel = e.getChannel();
|
||||
super.channelConnected(ctx, e);
|
||||
super.channelOpen(ctx, e);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
x
Reference in New Issue
Block a user