Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
spanner: fix incorrect decreasing metrics
This issue happens when the number of sessions is downsizing to a smaller value during a health recyling period (10 mins). When the session pool does not need this many sessions, the health maintainer will adjust the number of sessions to a lower number. The current implementation to decrease numReads and numWrites is incorrect because `p.idleList.Remove` and `p.idleWriteList.Remove` always return a non-nil value. This leads to a decrease for both metrics at the same time. Change-Id: Ie21c30200559ebbe95ec09c65e7e54040fcf0cfc Reviewed-on: https://code-review.googlesource.com/c/gocloud/+/54830 Reviewed-by: kokoro <noreply+kokoro@google.com> Reviewed-by: Knut Olav Løite <koloite@gmail.com>
- Loading branch information