Commit Graph

32 Commits

Author SHA1 Message Date
Trustin Lee
d02bc1c0d3 Log outbound buffer
- Use uppercase names for outbound events
2012-05-11 00:46:51 +09:00
Trustin Lee
d5b52077fe Remove hexdump option in LoggingHandler and dump always
- Allow a user override the log message instead
- Prettier hex dump
2012-05-11 00:39:44 +09:00
Trustin Lee
da9ecadfc0 Introduce bypass buffer and use it in LoggingHandler
- Added ChannelBufferHolders.(inbound|outbound)BypassBuffer()
  - The holder returned by these methods returns the next handler's
    buffer.  When a handler's new(Inbound|Outbound)Buffer returns
    a bypass holder, your inboundBufferUpdated() and flush()
    implementation should check if the buffer is a bypass and should not
    modify the content of the buffer.
- Channel(Inbound|Outbound)?HandlerAdapter is now abstract.
  - A user has to specify the exact inbound/outbound buffer type
  - It's because there's no way to determine the best buffer type
- Implemented LoggingHandler using the new API.
  - It doesn't dump received or sent messages yet.
- Fixed a bug where DefaultUnsafe.close() does not trigger deregister()
- Fixed a bug where NioSocketChannel.isActive() does not return false
  when closed
2012-05-10 23:19:59 +09:00
Trustin Lee
368156f5d0 Another round of the new API design
- Channel now creates a ChannelPipeline by itself

  I find no reason to allow a user to use one's own pipeline
  implementation since I saw nobody does except for the cases where a
  user wants to add a user attribute to a channel, which is now covered
  by AttributeMap.

- Removed ChannelEvent and its subtypes because they are replaced by
  direct method invocation.
- Replaced ChannelSink with Channel.unsafe()
- Various getter renaming (e.g. Channel.getId() -> Channel.id())
- Added ChannelHandlerInvoker interface
- Implemented AbstractChannel and AbstractServerChannel
- Some other changes I don't remember
2012-05-01 17:19:41 +09:00
Trustin Lee
fd0b0a4e2b Code cleanup 2012-03-30 12:48:28 +09:00
Trustin Lee
a81fa75c59 Fix #239: IdleStateHandler starts two timers
1) ReadTimeoutHandler is also affected by this bug - fixed
2) Reverted IdleStateHandler.beforeAdd() and channelConnected() -
without isAttached() check, timeout can be inaccurate if beforeAdd() is
called long before channelConnected().
2012-03-22 16:03:58 +09:00
Trustin Lee
f8253e031d Fix #239: IdleStateHandler starts two timers
1) Do not rely on ChannelPipeline.isAttached() to ensure initialize() is
called once.
2) Fix a race condition where initialize() can schedule timeouts after
destroy() is called.
2012-03-22 15:56:43 +09:00
Norman Maurer
b09bf5b1fb Tasks added to OrderedMemoryAwareThreadPoolExecutor may be lost in some
cases. See #234
2012-03-15 14:31:01 +01:00
Norman Maurer
3317dd7bff Make sure we don't try to use Channel.setReadable(true) if it was not
set by the threadpool itself. See #215
2012-03-04 19:32:44 +01:00
Norman Maurer
a071759575 Fix formatting 2012-03-02 09:35:16 +01:00
norman
0c46db317a Allow to handle only downstream events via the ExecutionHandler. See
#173
2012-03-02 09:28:43 +01:00
Norman Maurer
d8021fc6a8 Release ChildExecutor after the channel was closed. See #173 2012-03-01 21:36:34 +01:00
Trustin Lee
68f9c7a5f3 Fix #160 - Even more strict majorVersion check in SslHandler 2012-03-01 11:42:01 -08:00
Trustin Lee
4b583325b0 Fix #160 - No response to write if server is using SslHandler and client is not 2012-03-01 11:32:51 -08:00
Trustin Lee
4158152b24 Trigger exceptionCaught event from the middle of the pipline (#210)
.. because the previous handlers have no interest in the exceptions
raised by the next handlers.
2012-02-29 14:02:12 -08:00
Norman Maurer
8579f09c59 Merge pull request #210 from netty/threading_fix
Merge in fix for threading (related to #140 and #187). This also includes the new feature that allow to submit a Runnable that gets executed later in the io thread.
2012-02-29 12:11:46 -08:00
Trustin Lee
8ab9451086 Fix #208 - SslHandler does not use ChannelBufferFactory to create a new buffer
* Also fixed build failure caused by wrong fork mode
2012-02-29 09:19:18 -08:00
Norman Maurer
16fada5c23 Remove bogus constructor. See #173 2012-02-26 11:06:14 +01:00
Norman Maurer
5e43e879f2 Add OrderedDownstreamThreadPoolExecutor which can be used when using the
new feature of ExecutionHandler to also handle downstream events. This
is mainly useful for SEDA like stuff. See #173
2012-02-26 11:00:30 +01:00
Norman Maurer
68066c5e4b Make sure that ChannelDownstreamHandler impl fire exception caughts
later via the io-worker. See #140 and #187
2012-02-25 16:05:41 +01:00
norman
479def20bd Check if logging level is enabled before log. See #192 2012-02-17 10:37:41 +01:00
Norman Maurer
549546f944 Remove the child Executor with the right method so it will also work
when the channel is not the key.See #175
2012-02-03 15:50:36 +01:00
Trustin Lee
b9b2366361 Fix checkstyle violations / Renaming RXTX -> Rxtx 2012-01-15 01:08:00 +09:00
Trustin Lee
d40bd5e7f2 Rename IOStream example / Code cleanup 2012-01-15 00:43:28 +09:00
Trustin Lee
36bba6b29d Reverting the previous commit which makes no sense 2012-01-13 20:49:18 +09:00
Trustin Lee
b9386e7be8 Do not count a ChannelDownstreamEventRunnable
* MATPE is only for upstream events.
2012-01-13 20:48:18 +09:00
Trustin Lee
fde6789f41 Cleanup / Modify MATPE to reject a downstream event 2012-01-13 20:35:46 +09:00
Trustin Lee
958ffa50e3 Make ChannelUp/DownstreamEventRunnable non-final / Move the classes in execution.filter to execution 2012-01-13 18:04:06 +09:00
Trustin Lee
303c1b5f79 Overall cleanup / Add lost old jzlib headers 2012-01-13 17:41:18 +09:00
Trustin Lee
ebfc4513e0 Apply checkstyle to the build
Please note that the build will fail at the moment due to various checkstyle
violations which should be fixed soon
2012-01-11 20:16:14 +09:00
Norman Maurer
7c412848ef Fix NPE which is triggered if the destory method is called
before channelOpen(..). See #143
2012-01-07 19:42:00 +01:00
Trustin Lee
8663716d38 Issue #60: Make the project multi-module
Split the project into the following modules:
* common
* buffer
* codec
* codec-http
* transport
* transport-*
* handler
* example
* testsuite (integration tests that involve 2+ modules)
* all (does nothing yet, but will make it generate netty.jar)

This commit also fixes the compilation errors with transport-sctp on
non-Linux systems.  It will at least compile without complaints.
2011-12-28 19:44:04 +09:00