You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by "JosiahWI (via GitHub)" <gi...@apache.org> on 2023/11/01 14:18:58 UTC

[PR] Extract Stripe::aggregate_pending_writes [trafficserver]

JosiahWI opened a new pull request, #10706:
URL: https://github.com/apache/trafficserver/pull/10706

   This extracts aggregate_pending_writes from aggWrite and adds a javadoc comment intended to document the operation of the method for future developers. This is an internal API so it intentionally goes into implementation details in an attempt to make this part of the write sequence less mysterious.


-- 
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: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Extract Stripe::aggregate_pending_writes [trafficserver]

Posted by "masaori335 (via GitHub)" <gi...@apache.org>.
masaori335 commented on code in PR #10706:
URL: https://github.com/apache/trafficserver/pull/10706#discussion_r1379505367


##########
src/iocore/cache/P_CacheVol.h:
##########
@@ -218,6 +218,27 @@ struct Stripe : public Continuation {
 
   int aggWriteDone(int event, Event *e);
   int aggWrite(int event, void *e);
+
+  /**
+   * Copies virtual connection buffers into the aggregate write buffer.
+   *
+   * Pending write data will only be copied while space remains in the aggregate
+   * write buffer. The copy will stop at the first pending write that does
+   * not fit in the remaining space. Note that the total size of each pending
+   * write must not be greater than the total aggregate write buffer size.
+   *
+   * After each virtual connection's buffer is successfully copied, it will
+   * receive mutually-exclusive post-handling based on the connection type:
+   *
+   *     - sync (only if CacheVC::f.use_first_key): inserted into sync queue
+   *     - evacuator: handler invoked - probably evacuateDocDone
+   *     - otherwise: inserted into tocall for handler to be scheduled later
+   *
+   * @param tocall Out parameter; a queue of virtual connections with handlers that need to
+   *     invoked at the end of aggWrite.
+   * @see aggWrite
+   */
+  void aggregate_pending_writes(Queue<CacheVC, Continuation::Link_link> &tocall);

Review Comment:
   We can make it later, but how's make this private function?



-- 
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: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Extract Stripe::aggregate_pending_writes [trafficserver]

Posted by "bneradt (via GitHub)" <gi...@apache.org>.
bneradt merged PR #10706:
URL: https://github.com/apache/trafficserver/pull/10706


-- 
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: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org