Do not enqueue items when the queue is shut down (#652)
Do not enqueue items when the queue is shut down (#652)

* Do not enqueu (and log) if we're shutting down

* Wait for queue to empty before terminate and other restrictions

We need to stop enqueueing stuff when queue is shuitting down since this causes panics in our tests.
So

1. wait for queue to empty before shutting down
2. do not enqueue stuff for global reconciliation if the queue is shutting down (this exhibits races in global resync tests)
3. do not enqueue on error, since while the erroneous object was being processed the queue might have terminated

/assign mattmoor

knative/pkg,knative/pkg