Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
85159: requestbatcher: nil unused slice entries in batchQueue heap r=nvanbenschoten a=nvanbenschoten This change nils out unused entries in the `batchQueue`'s slice when the slice is truncated to avoid retaining references to batches of requests and preventing them from being GCed. The change also removes a redundant update of the batchQueue's byRange map. The `delete` was redundant because `heap.Remove` already calls `Pop`. I found this while looking at https://github.com/cockroachlabs/support/issues/1707, but I don't think this is actually the cause of the perceived memory leak. Co-authored-by: Nathan VanBenschoten <[email protected]>
- Loading branch information