Fix checkstyle
Fix class-cast exception which is a regression introduces in 256c931db20fbfaf597e501b74a34fd850c7f948
[#1036] Add special ConnectTimeoutException which is thrown if a connection failed because of a timeout
port fix from Akka for HashedWheelTimer

Ported from commits:

* https://github.com/akka/akka/commit/cb4e3536b0ed3483bd3636d7789c0ddcadafa2da
* https://github.com/akka/akka/commit/7e590f3071bdf89a4aa9d7d262bac8923d85e754
Use the original stack trace when translating SocketTimeoutException to ConnectTimeoutException
Fix inspection warnings in HashedWheelTimer
Make WebSocket codec also work when HttpClientCodec and HttpServerCodec is used.

Also refactor the handshakers to share more code and make it easier to implement a new one and less error-prone
Relaxed memory access constraint of ReferenceCounted.refCnt() for potentially better performance / More precise reference counting for MessageBuf
Fix checkstyle
Always use EmptyByteBuf when a user attempts to construct a buffer with 0 maxCapacity / Make EmptyByteBuf remember the allocator it came from / Optimize EmptyByteBuf a little bit
Use I/O buffer whenever possible now that our direct buffers are as fast as heap buffers
Allow to specify the used buffer type for ChannelInboundByteBufHandler and ChannelOutboundByteBufHandler by configuration. As default it tries to use a direct ByteBuf
Add stacktrace to the IllegalStateException which is thrown if a Promise was notified before
[#1131] Codecs must not cache next buffer during processing
[#1135] Fix endless loop which will get triggered when an exception is thrown during freeHandlerBuffersAfterRemoval
[#1136] Fix possible IllegalBufferAccessException when remove itself from the pipeline
More concise exception message
Fix a bug where TypeParameterMatcher raises ClassCastException when an instance with raw type parameter is given
Let BufUtil.retain(...) return the given object
Check for NPE and also optimze HashSet allocation