This probably fixes a race condition that we saw in CI (I cannot repro
locally.)
Change-Id: I64ad51d0dac57307aa664a2a5cd435ccf0c74af2
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/297130
Trust: Jonathan Amsterdam <jba@google.com>
Run-TryBot: Jonathan Amsterdam <jba@google.com>
TryBot-Result: kokoro <noreply+kokoro@google.com>
Reviewed-by: Julie Qiu <julie@golang.org>
Move the logic for updating experiments into a separate package.
A subsequent CL will replace the logic in internal/postgres/excluded.go
with a use of this package.
Motivation: currently, multiple concurrent requests to IsExcluded will
result in multiple DB queries, which is wasteful. It makes more sense
to poll IsExcluded periodically, as we do for experiments.
Change-Id: I33202c1ce1d94a5b1c99fe6a332d89174517fe08
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/261818
Trust: Jonathan Amsterdam <jba@google.com>
Run-TryBot: Jonathan Amsterdam <jba@google.com>
TryBot-Result: kokoro <noreply+kokoro@google.com>
Reviewed-by: Julie Qiu <julie@golang.org>