internal/worker: retry shedded fetches

If a fetch returns a 503 (ServiceUnavailable), it was prevented from
running because of load shedding. We want the task queue to retry
that module for us.

Change-Id: I4f306a259e1cf30cf21e78f06ee4145ef5941aeb
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/257177
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>
diff --git a/internal/worker/server.go b/internal/worker/server.go
index 8494f49..cdf00cc 100644
--- a/internal/worker/server.go
+++ b/internal/worker/server.go
@@ -262,7 +262,7 @@
 	}
 
 	msg, code := s.doFetch(r)
-	if code == http.StatusInternalServerError {
+	if code == http.StatusInternalServerError || code == http.StatusServiceUnavailable {
 		log.Infof(r.Context(), "doFetch of %s returned %d; returning that code to retry task", r.URL.Path, code)
 		http.Error(w, http.StatusText(code), code)
 		return