kuberay icon indicating copy to clipboard operation
kuberay copied to clipboard

chore: reduce memory allocation on handling http response

Open fscnick opened this issue 10 months ago • 0 comments

Why are these changes needed?

After getting response from ProxyActorHealth, the body is not used if the status is 200. It causes an unnecessary allocation.

Here are the simulation of code from benchmark. before: before

after: after

Related issue number

Checks

  • [x] I've made sure the tests are passing.
  • Testing Strategy
    • [ ] Unit tests
    • [ ] Manual tests
    • [ ] This PR is not tested :(

fscnick avatar Jun 18 '25 14:06 fscnick