Skip to content

improve GetMulti method resilience and performance

Latest

Choose a tag to compare

@flyhope flyhope released this 23 Jun 06:45
feat: improve GetMulti method resilience and performance

- Skip failed servers instead of returning early when PickServer fails
- Pre-allocate result map with expected capacity to avoid dynamic resizing
- Ensure partial results are returned even when some memcache servers are unavailable

This change improves fault tolerance by allowing GetMulti to continue
processing keys from healthy servers when some servers are down, while
also optimizing memory allocation performance.

Fixes issue where GetMulti would fail entirely if any single server
was unreachable, now gracefully handles server failures and returns
available data from functioning servers.