Commit Graph

5 Commits

Author SHA1 Message Date
Aaron Gable 519c199c9a
Greatly simplify crl-updater's batch mode (#7079)
Replace crl-updater's overly complex RunOnce and updateIssuer methods
with a single, much simpler RunOnce that is modeled off of the
recently-redone continuous Run method's model. Instead of breaking
things down by issuer then shard, simply kick off everything in
parallel. This also improves batch mode's ability to listen for context
cancellations at all the appropriate times.

At the same time, move getShardMappings into the shared updater.go file
because it is used by both the batch and continuous modes of operation,
and improve uniformity of usage of the crlId structure in log output.

Fixes https://github.com/letsencrypt/boulder/issues/7066
2023-09-19 13:40:18 -07:00
Aaron Gable d53c90a3bc
Streamline and test crl-updater errors and audit logs (#6382)
Modify the way errors are handled in crl-updater:
- Rather than having each method in the tick, tickIssuer, tickShard
  chain concatenate all errors from its children, simply have them
  summarize the errors. This results in much shorter error messages.
- Rather than having each method log its own errors as it returns, have
  each caller responsible for logging the errors it receives from its
  children.

In addition, add tests for tick, tickIssuer, and tickShard which cover
their simple errors paths, where one of the gRPC requests to the SA, CA,
or CRLStorer encounters an error. These tests let us ensure that errors
are being properly propagated upwards through the layers of indirection
and goroutines in the three methods under test, and that the appropriate
metrics are being incremented and log messages are being printed.

Fixes #6375
2022-09-14 16:41:28 -07:00
Samantha 7ed4cd992e
CRL: Improve shard identification in error messages (#6306)
- Create new package `crl`
- Add a common unique CRL identifier `crl.id` with constructor `crl.Id()`
- Replace `shardIdx` with `crl.Id` in `storer` and `updater` errors
- Add a common type for the `CRLNumber` field `crl.number` with constructor
  `crl.Number()`
- Replace `CRLNumber` construction in CA and CRL package with `crl.Number()`

Resolves #6261
2022-08-23 12:35:00 -07:00
Jacob Hoffman-Andrews f26228703e
Temporarily remove crl package. (#4725)
This is currently unused, and was a copy of the Go upstream package
anyhow. We will either re-copy when needed or wait for Go 1.15, which
will include the updates we need.
2020-03-30 10:55:38 -07:00
Roland Bracewell Shoemaker 65e5367493
Add upstream CRL change to tree (#4671)
Copies in the code + test from go-review.googlesource.com/c/go/+/217298. Also requires a bunch of private crypto/x509 stuff that the change relies on, which somewhat bloats the diff. The only divergent code in crl/crl.go is in CreateCRL.

Fixes #4668.
2020-02-05 13:22:03 -08:00