Index: code/modules/grizzly/src/main/java/com/sun/grizzly/DefaultSelectionKeyHandler.java =================================================================== --- code/modules/grizzly/src/main/java/com/sun/grizzly/DefaultSelectionKeyHandler.java (revision 3774) +++ code/modules/grizzly/src/main/java/com/sun/grizzly/DefaultSelectionKeyHandler.java (working copy) @@ -222,7 +222,16 @@ return timeout; } - + /** + * Set expiration timeout for the {@link SelectionKey}. + * + * If during that defined timeout the client isn't pushing bytes + * (or closing the connection), the SelectionKey will be expired + * and its channel closed. The negative timeout value will let + * {@link SelectionKey} never expire. + * + * @param timout in seconds + */ public void setTimeout(long timeout) { this.timeout = timeout; }