sourcegraph/cmd
Joe Chen 2589fef13e
lib/background: upgrade Routine interface with context and errors (#62136)
This PR is a result/followup of the improvements we've made in the [SAMS repo](https://github.com/sourcegraph/sourcegraph-accounts/pull/199) that allows call sites to pass down a context (primarily to indicate deadline, and of course, cancellation if desired) and collects the error returned from `background.Routine`s `Stop` method.

Note that I did not adopt returning error from `Stop` method because I realize in monorepo, the more common (and arguably the desired) pattern is to hang on the call of `Start` method until `Stop` is called, so it is meaningless to collect errors from `Start` methods as return values anyway, and doing that would also complicate the design and semantics more than necessary.

All usages of the the `background.Routine` and `background.CombinedRoutines` are updated, I DID NOT try to interpret the code logic and make anything better other than fixing compile and test errors.

The only file that contains the core change is the [`lib/background/background.go`](https://github.com/sourcegraph/sourcegraph/pull/62136/files#diff-65c3228388620e91f8c22d91c18faac3f985fc67d64b08612df18fa7c04fafcd).
2024-05-24 10:04:55 -04:00
..
appliance appliance: split reconciler package into subpackage (#62730) 2024-05-20 16:53:14 +01:00
batcheshelper bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
blobstore bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
bundled-executor bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
cody-gateway lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
embeddings lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
enterprise-portal feat/enterprise-portal: DB layer for {Get/List}CodyGatewayAccess (#62706) 2024-05-22 12:56:59 -07:00
executor lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
executor-kubernetes bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
frontend lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
gitserver lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
loadtest bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
migrator bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
msp-example lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
pings bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
precise-code-intel-worker lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
repo-updater lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
searcher bazel: transcribe test ownership to bazel tags (#62664) 2024-05-16 15:51:16 +01:00
server gitserver: Simplify invocation of p4-fusion (#62070) 2024-05-02 01:44:53 +02:00
symbols lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
syntactic-code-intel-worker lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
telemetry-gateway lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
worker lib/background: upgrade Routine interface with context and errors (#62136) 2024-05-24 10:04:55 -04:00
README.md Reminder to keep architecture diagram in-sync (#36869) 2022-06-08 19:40:36 -07:00

This directory contains Sourcegraph services and binaries.

When a services is added, removed, or when a service's dependencies change, update our architecture diagram.