Michael Ho has posted comments on this change. ( http://gerrit.cloudera.org:8080/8895 )
Change subject: KUDU-1865: Avoid some heap allocations in RPC paths ...................................................................... Patch Set 2: (1 comment) http://gerrit.cloudera.org:8080/#/c/8895/2//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/8895/2//COMMIT_MSG@21 PS2, Line 21: Introduce a new interface RpcContext::RespondSuccess(const Message& message) : which allows callers to pass the response PB directly as argument instead : of using the preallocated response PB owned by RpcContext. This allows callers : to allocate the response PB on the stack, thus avoiding the need to use the heap. > Yes, I am not too keen on having two APIs either. In fact, I wonder if ther It'd also be nice if there is an object pool which can recycle the request and response buffer but it would have to be a per-thread pool or we may run into the lock contention when multiple service threads try to allocate from it. -- To view, visit http://gerrit.cloudera.org:8080/8895 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I407b4782c9f3cd39ad3c6e0d21fd9542be34b118 Gerrit-Change-Number: 8895 Gerrit-PatchSet: 2 Gerrit-Owner: Michael Ho <[email protected]> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Michael Ho <[email protected]> Gerrit-Reviewer: Mostafa Mokhtar <[email protected]> Gerrit-Reviewer: Sailesh Mukil <[email protected]> Gerrit-Reviewer: Tidy Bot Gerrit-Reviewer: Todd Lipcon <[email protected]> Gerrit-Comment-Date: Thu, 21 Dec 2017 06:43:57 +0000 Gerrit-HasComments: Yes
