Norman Maurer
ae904a1f56
Introduce a new ChannelOption called DATAGRAM_CHANNEL_ACTIVE_ON_REGISTRATION. Related to [ #1830 ]
...
This ChannelOption allows to tell the DatagramChannel implementation to be active as soon as they are registrated to their EventLoop. This can be used to make it possible to write to a not bound DatagramChannel.
The ChannelOption is marked as @deprecated as I'm looking for a better solution in master which breaks default behaviour with 4.0 branch.
2013-09-24 11:46:49 +02:00
Sasha Zverev
a2624a833e
Slip in DefaultOioSocketChannelConfig (setAllowHalfClosure used to ignore argument)
2013-09-21 20:13:52 +02:00
Norman Maurer
f034f90fb3
[ #1836 ] Add comment to explain why read is triggered
2013-09-17 06:58:47 +02:00
Norman Maurer
357677d8fa
[ #1830 ] Add testcase for write to not bound DatagramChannel impls and revert change in OIO as it breaks things as the udnerlying socket lazy binds
2013-09-12 09:27:43 +02:00
Norman Maurer
f4f04a08c2
Make DatagramChannel impls .isActive() return true when the underlying Channel is open. This also fixes [ #1830 ]
2013-09-11 20:37:21 +02:00
Norman Maurer
7d9388a3cc
Allow to only register a Channel via AbstractBootstrap and bind/connect it later. Related to [ #1829 ]
2013-09-11 20:14:53 +02:00
Norman Maurer
ffab456aca
Bump up version to reflect correct one
2013-09-09 11:20:12 +02:00
Norman Maurer
af499b5fb4
Mark ChannelHandler.exceptionCaught(...) as deprecated in preparation to move to ChannelInboundHandler. Related to [ #1808 ]
2013-09-08 20:11:51 +02:00
Norman Maurer
363531caf9
[maven-release-plugin] rollback the release of netty-4.0.9.Final
2013-09-06 09:18:34 +02:00
Norman Maurer
9d53573ee8
[maven-release-plugin] prepare for next development iteration
2013-09-06 09:17:15 +02:00
Trustin Lee
ad0c456209
Ensure operationProgressed is invoked even on completion
...
- Fixes #1809
2013-09-05 18:37:14 +09:00
Norman Maurer
92cec8d2ac
Split up the nioBuffers() method to allow for inline. Related to #1812
...
This move less common method patterns to extra methods and so make the nioBuffers() method with most common pattern (backed by one ByteBuffer) small enough for inlining.
2013-09-05 09:22:13 +02:00
Norman Maurer
c97971b53a
[ #1805 ] Fix example in javadocs of SimpleChannelInboundHandler
2013-09-03 20:30:56 +02:00
Norman Maurer
25c226a835
Make sure only direct ByteBuffer are passed to the underlying jdk Channel.
...
This is needed because of otherwise the JDK itself will do an extra ByteBuffer copy with it's own pool implementation. Even worth it will be done
multiple times if the ByteBuffer is always only partial written. With this change the copy is done inside of netty using it's own allocator and
only be done one time in all cases.
2013-09-02 20:17:53 +02:00
Norman Maurer
4a5c840271
@Deprecated ChannelOutboundHandler.deregister(...)
2013-09-01 12:54:29 +02:00
Norman Maurer
b8866aef33
No need to check instanceof everytime to find the next inbound / outbound context
2013-08-30 06:31:58 +02:00
Norman Maurer
32deb2c22b
[ #1785 ] Fix incorrect javadocs
2013-08-27 06:55:14 +02:00
Norman Maurer
2e39b25cd4
[maven-release-plugin] prepare for next development iteration
2013-08-26 12:01:03 +02:00
Norman Maurer
b67659a866
[maven-release-plugin] prepare release netty-4.0.8.Final
2013-08-26 12:00:54 +02:00
Norman Maurer
5e9b199296
@deprecated all methods which are related to deregister as it will be removed in 4.1.0.Final
2013-08-26 11:36:56 +02:00
Norman Maurer
80d30c3dd8
Small code improvements
2013-08-26 07:52:47 +02:00
Norman Maurer
77d4222db5
[ #1777 ] Use correct Thread when close per channel
2013-08-25 21:22:53 +02:00
Norman Maurer
f76c01c3aa
[ #1782 ] Fix IndexOutOfBoundException with direct buffer and gathering writes
2013-08-24 18:16:05 +02:00
Trustin Lee
7aefd0cbdb
Make AbstractBootstrap public
...
.. to work around the issue with JDK reflection described here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4283544
Fixes #1780
2013-08-24 17:20:53 +09:00
Norman Maurer
9ca20b73d3
Add testcase to show channelRegistered is called
2013-08-23 17:17:28 +02:00
bgallagher
51fa795819
fix race condition in test
2013-08-23 16:20:02 +02:00
Norman Maurer
206dc2a391
[ #1772 ] Make sure ChannelOutboundBuffer.recycle() does also reset unflushed, flushed and tail.
...
This fix a IndexOutOfBoundsException which as triggered if recycle() did cut down the buffer[] to the initial size.
2013-08-23 09:01:16 +02:00
Norman Maurer
9fd35d09a2
[ #1770 ] Fix NPE which was thrown if connection timeout was disabled and the connect did not finish directly when using NIO
2013-08-22 12:38:56 +02:00
bgallagher
6a2f340ec0
trim buffers before recycling
2013-08-21 20:28:54 +02:00
bgallagher
fb619f2394
fix writability callback
2013-08-21 16:39:50 +02:00
Norman Maurer
217b8e255c
[ #1763 ] Fill ChannelOutboundBuffer.nioBuffers with null on close to allow the content to be GC'ed
2013-08-20 21:15:05 +02:00
Trustin Lee
15cfa47ad9
Fix checkstyle
2013-08-20 14:40:28 +09:00
Trustin Lee
caf91b9c06
Fix IllegalStateException triggered while shutting down ThreadPerChannelEventLoopGroup
...
- Fix #1718
- Add the test case contributed by @mkw
2013-08-20 14:37:57 +09:00
bgallagher
a383988cdb
add struct to replace parallel arrays consolidate flushed & unflushed buffers
2013-08-18 19:19:57 +02:00
bgallagher
06e250e493
remove unused initialCapacity
2013-08-17 14:10:33 +02:00
bgallagher
9f88552f12
remove some dead code
2013-08-10 20:46:48 +02:00
Norman Maurer
280afda013
[ #1715 ] Remove extra call socket.configureBlocking(false)
2013-08-10 20:33:19 +02:00
bgallagher
59c2fd8813
[ #1723 ] invoke close in eventloop
2013-08-10 08:19:16 +02:00
Norman Maurer
9d8c4ded50
Move method in correct scope
2013-08-09 13:30:04 +02:00
Norman Maurer
4d0621855a
Remove unused package private method and so remove some complexity
2013-08-09 11:44:41 +02:00
Norman Maurer
b54937ab50
[ #1711 ] Allow to use ChannelOption for set / get MessageSizeEstimator
2013-08-08 20:37:35 +02:00
Norman Maurer
f40a3f34b1
[ #1692 ] Allow to set WRITE_BUFFER_HIGH_WATER_MARK and WRITE_BUFFER_LOW_WATER_MARK via ChannelOption
2013-08-08 20:30:01 +02:00
Norman Maurer
1d3560e389
[maven-release-plugin] prepare for next development iteration
2013-08-08 13:53:28 +02:00
Norman Maurer
8e97e6c461
[maven-release-plugin] prepare release netty-4.0.7.Final
2013-08-08 13:53:19 +02:00
Norman Maurer
fc6213604d
Make sure ChannelOutboundBuffer not throw NPE during increment/decrement pending writes
2013-08-08 13:42:25 +02:00
Norman Maurer
b934b6009c
Share some code, related to [ #1707 ]]
2013-08-07 20:28:33 +02:00
Norman Maurer
5ef30b6d8b
[ #1707 ] More efficient implementation of ChannelHandlerContext.writeAndFlush(..)
2013-08-07 20:15:10 +02:00
Norman Maurer
5b6e762bf4
Allow to have the Channel GC'ed ASAP
2013-08-07 10:32:03 +02:00
Norman Maurer
48a7a21541
Correctly update Channel.isWritable() when the write happens from outside the EventLoop in a fast fashion. Fixes [ #1697 ]
...
Introduce a new interface called MessageSizeEstimator. This can be specific per Channel (via ChannelConfig). The MessageSizeEstimator will be used to estimate for a message that should be written. The default implementation handles ByteBuf, ByteBufHolder and FileRegion. A user is free to plug-in his/her own implementation for different behaviour.
2013-08-07 10:10:43 +02:00
Norman Maurer
de44917e62
Use recyclable write task to reduce GC pressure
2013-08-05 14:59:58 +02:00