Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(client): optimize with atomic.Int64 for lastSubscribeAt in pkg/v…
…arlog.(subscriber) (#720) ### What this PR does Switches the type of `pkg/varlog.(subscriber).lastSubscribeAt` from `atomic.Value` to `atomic.Int64` to eliminate heap escapes. The frequent updates with new `time.Time` values to `lastSubscribeAt` previously led to significant heap allocation due to heap escape. By adopting `atomic.Int64`, we can prevent heap escape, thereby reducing heap allocations and enhancing performance.
- Loading branch information