Delete commandfactories on exit