WIP: Refactor certificate agent and queue

Details to follow...
It would be interesting to experiment with a large class - say 20k participants - to see if it would kill the host if you did something like:
```
while queue_length > 0:
  do_stuff()
```
i.e., only sleeping when polling an empty queue. Clearly this would be faster, and clearly it would drive higher load. It would be interesting to experiment and see how much higher. I suspect that the naturally i/o bound nature of certificate generation would keep it pretty manageable, even when the queue is deep.