[grizzly~git:53d164c1] [2.3.x]

  • From: oleksiys@...
  • To: commits@...
  • Subject: [grizzly~git:53d164c1] [2.3.x]
  • Date: Wed, 5 Mar 2014 23:19:39 +0000

Project:    grizzly
Repository: git
Revision:   53d164c1102d0048f3f9fd8ec5d0c996176fbb76
Author:     oleksiys
Date:       2014-03-05 23:19:14 UTC
Link:       

Log Message:
------------
[2.3.x]
+ fix javadoc
+ use forgotten clientSocketSoTimeout option (thanks to Matt)



Revisions:
----------
53d164c1102d0048f3f9fd8ec5d0c996176fbb76


Modified Paths:
---------------
modules/grizzly/src/main/java/org/glassfish/grizzly/Buffer.java
modules/grizzly/src/main/java/org/glassfish/grizzly/nio/transport/TCPNIOTransport.java


Diffs:
------
--- a/modules/grizzly/src/main/java/org/glassfish/grizzly/Buffer.java
+++ b/modules/grizzly/src/main/java/org/glassfish/grizzly/Buffer.java
@@ -1,7 +1,7 @@
 /*
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
  *
- * Copyright (c) 2008-2012 Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008-2014 Oracle and/or its affiliates. All rights reserved.
  *
  * The contents of this file are subject to the terms of either the GNU
  * General Public License Version 2 only ("GPL") or the Common Development
@@ -848,12 +848,12 @@ public interface Buffer extends Comparable<Buffer>, 
WritableMessage {
      * given {@link String} into this buffer.
      *
      * <p> In other words, an invocation of this method of the form
-     * <tt>dst.put(src)</tt> has exactly the same effect as
+     * <tt>dst.put8BitString(src)</tt> has exactly the same effect as
      * the loop
      *
      * <pre>
-     *     for (int i = 0; i < s.length(); i++)
-     *         dst.put((byte) s.charAt(i)); </pre>
+     *     for (int i = 0; i < src.length(); i++)
+     *         dst.put((byte) src.charAt(i)); </pre>
      *
      * except that it first checks that there is sufficient space in this
      * buffer and it is potentially much more efficient. </p>--- 
a/modules/grizzly/src/main/java/org/glassfish/grizzly/nio/transport/TCPNIOTransport.java
+++ 
b/modules/grizzly/src/main/java/org/glassfish/grizzly/nio/transport/TCPNIOTransport.java
@@ -446,7 +446,18 @@ public final class TCPNIOTransport extends NIOTransport 
implements
         } catch (IOException e) {
             LOGGER.log(Level.WARNING, 
LogMessages.WARNING_GRIZZLY_SOCKET_TCPNODELAY_EXCEPTION(isTcpNoDelay()), e);
         }
-        socket.setReuseAddress(isReuseAddress());
+        
+        try {
+            socket.setReuseAddress(isReuseAddress());
+        } catch (IOException e) {
+            LOGGER.log(Level.WARNING, 
LogMessages.WARNING_GRIZZLY_SOCKET_REUSEADDRESS_EXCEPTION(isReuseAddress()), 
e);
+        }
+
+        try {
+            socket.setSoTimeout(getClientSocketSoTimeout());
+        } catch (IOException e) {
+            LOGGER.log(Level.WARNING, 
LogMessages.WARNING_GRIZZLY_SOCKET_TIMEOUT_EXCEPTION(getClientSocketSoTimeout()),
 e);
+        }    
     }
 
     @Override





[grizzly~git:53d164c1] [2.3.x]

oleksiys 03/05/2014
Terms of Use; Privacy Policy; Copyright ©2013-2017 (revision 20160708.bf2ac18)
 
 
Close
loading
Please Confirm
Close