broker.cleanUpTempResources();
if (status != SHUTDOWN) broker.cleanUpTempResources();
	private void sync(DBBroker broker, int syncEvent) {		broker.sync(syncEvent);		User user = broker.getUser();		//TODO : strange that it is set *after* the sunc method has been called.		broker.setUser(SecurityManager.SYSTEM_USER);		broker.cleanUpTempResources();        if (syncEvent == Sync.MAJOR_SYNC) {            try {                if (!FORCE_CORRUPTION)                    transactionManager.checkpoint(checkpoint);            } catch (TransactionException e) {                LOG.warn(e.getMessage(), e);            }            cacheManager.checkCaches();            sync.restart();            notificationService.debug();        } else            cacheManager.checkDistribution();        //TODO : touch this.syncEvent and syncRequired ?	        //After setting the SYSTEM_USER above we must change back to the DEFAULT User to prevent a security problem        //broker.setUser(User.DEFAULT);        broker.setUser(user);	}