Commit b31c3b5
RHCS-6003: Revert "Use synchronous LWCA KeyRetriever"
This reverts commit 451cc4d.
Making LWCA key retrieval causes hangs on servers to which
lightweight CA keys have not yet been successfully retrieved (e.g.
due to transient issue). The problem arises as follows:
1. AuthorityMonitor thread observes creation of new CA via LDAP
replication.
2. AuthorityMonitor initialises the CertificateAuthority object.
3. At SigningUnit initialisation, observes absence of keys and
initiates key retrieval (synchronously)
4. Key retrieval fails; enters exponential backoff loop
5. CertificateAuthority initialisation is stuck in key retrieval
backoff loop; it does not get added to the CA registry.
6. Separately, `AuthorityService` / `AuthorityServlet` receives a
request related to the CA (e.g. retrieve authority info or cert
chain).
7. Lookup via `AuthorityRepository` locates the data, but no
`CertificateAuthority` object exists for it. Starts the
initialisation process afresh (and hangs).
8. Rinse, repeat. Eventually even unrelated functions can be
impacted due to resource starvation (e.g. no available HTTP
worker threads).
The fix is to revert to asynchronous key retrieval. Happily, the
earlier patch reverted cleanly. The change to synchronous retrieval
was intended to resolve an [issue] with nondeterministic failures
when creating many LWCAs in rapid succession. Further investigation
of that issue hints that the issue may be resource limit related
because LDAP connection failures affect both LWCA creation and key
retrieval. We may need to do further investigation and
experimentation to solve that issue in a different way.
[issue]: dogtagpki#4677.
Fixes: https://issues.redhat.com/browse/RHCS-60031 parent 952fb6f commit b31c3b5
1 file changed
Lines changed: 6 additions & 8 deletions
Lines changed: 6 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
219 | 219 | | |
220 | 220 | | |
221 | 221 | | |
222 | | - | |
| 222 | + | |
223 | 223 | | |
224 | 224 | | |
225 | 225 | | |
| |||
649 | 649 | | |
650 | 650 | | |
651 | 651 | | |
652 | | - | |
| 652 | + | |
653 | 653 | | |
654 | 654 | | |
655 | 655 | | |
| |||
687 | 687 | | |
688 | 688 | | |
689 | 689 | | |
690 | | - | |
691 | | - | |
692 | | - | |
| 690 | + | |
693 | 691 | | |
694 | | - | |
695 | | - | |
| 692 | + | |
| 693 | + | |
696 | 694 | | |
697 | 695 | | |
698 | 696 | | |
699 | | - | |
| 697 | + | |
700 | 698 | | |
701 | 699 | | |
702 | 700 | | |
| |||
0 commit comments