The shutdown() methods in several classes have been fixed to allow
more graceful shutdown. Null pointers are checked to avoid exception.
It's not necessary to empty container objects since they might still
be used by other threads and will be garbage collected eventually.
Ticket #247
--
Endi S. Dewata