moonchen commented on code in PR #13202:
URL: https://github.com/apache/trafficserver/pull/13202#discussion_r3367589631


##########
src/iocore/net/SSLNetVConnection.cc:
##########
@@ -737,18 +737,17 @@ SSLNetVConnection::load_buffer_and_write(int64_t towrite, 
MIOBufferAccessor &buf
 
   Dbg(dbg_ctl_ssl, "towrite=%" PRId64, towrite);
 
+  // Per-thread scratch to coalesce fragmented blocks into one SSL_write. 
Reuse across
+  // connections is safe: a WANT_WRITE retry flushes SSL's own record buffer, 
not this.

Review Comment:
   I think we should rephrase why the gather_buf is thread_local.  Isn't it 
this way because we don't set `SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER`?  Maybe 
something like:
   
   ```
   // SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER is off, so SSL_write retries after 
WANT_WRITE/WANT_READ 
   // require the same buffer address.  We ensure the same buffer address 
between retries by reusing a
   // thread_local buffer.
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to