We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
运行日志,请关注最后一行
2017-08-08 09:59:07.224 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.util.NetUtil - -Djava.net.preferIPv4Stack: false 2017-08-08 09:59:07.224 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.util.NetUtil - -Djava.net.preferIPv6Addresses: false 2017-08-08 09:59:07.313 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.util.NetUtil - Loopback interface: lo (Software Loopback Interface 1, 127.0.0.1) 2017-08-08 09:59:07.317 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.util.NetUtil - \proc\sys\net\core\somaxconn: 200 (non-existent) 2017-08-08 09:59:07.403 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.channel.DefaultChannelId - -Dio.netty.machineId: 00:00:00:00:00:00:00:e0 (auto-detected) 2017-08-08 09:59:07.404 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.util.internal.ThreadLocalRandom - -Dio.netty.initialSeedUniquifier: 0xfe50d10b389fdd4b 2017-08-08 09:59:07.482 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.buffer.ByteBufUtil - -Dio.netty.allocator.type: pooled 2017-08-08 09:59:07.483 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.buffer.ByteBufUtil - -Dio.netty.threadLocalDirectBufferSize: 65536 2017-08-08 09:59:07.483 [destination = example , address = /127.0.0.1:3306 , EventParser] DEBUG io.netty.buffer.ByteBufUtil - -Dio.netty.maxThreadLocalCharBufferSize: 16384 2017-08-08 09:59:17.547 [destination = example , address = /127.0.0.1:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /127.0.0.1:3306...
public static SocketChannel open(SocketAddress address) throws Exception { final SocketChannel socket = new SocketChannel(); boot.connect(address).addListener(new ChannelFutureListener() { @Override public void operationComplete(ChannelFuture arg0) throws Exception { if (arg0.isSuccess()) socket.setChannel(arg0.channel()); synchronized (socket) { socket.notify(); // <-------------------- } } }); synchronized (socket) { socket.wait(); // <-------------------- } if (null == socket.getChannel()) { throw new IOException("can't create socket!"); } chManager.put(socket.getChannel(), socket); return socket; }
notify是有可能会比wait提前执行的,建议优化下
The text was updated successfully, but these errors were encountered:
fixed issue #360 , socket pool bug
788c1d9
agapple
No branches or pull requests
运行日志,请关注最后一行
notify是有可能会比wait提前执行的,建议优化下
The text was updated successfully, but these errors were encountered: