} // end of synchronized
//Now destroy all collected objects
while (! stack.isEmpty()) {
Object object = stack.pop();
beforeDestroy(object);
factory.destroy(object);
}
//Bug 4677074 System.out.println("Leaving service after killing " + killedCount + " (idle) objects. Now size: " + list.size());