delete pac users

This commit is contained in:
Peter Hormanns 2011-07-28 17:26:33 +00:00
parent f003a5cc69
commit 468a6f1be5

View File

@ -68,9 +68,7 @@ public class PacProcessorFactory implements EntityProcessorFactory {
public <T extends AbstractEntity> Processor createDeleteProcessor(
EntityManager em, T entity) throws ProcessorException {
Pac pac = (Pac) entity;
em.refresh(pac);
Hive hive = pac.getHive();
UnixUser unixUser = getPacAdminUser(pac);
Map<String, String> hiveValues = fillHiveValues(hive);
List<Map<String, String>> pacValuesList = fillPacValuesList(hive);
WaitingTasksProcessor waitingProcessor = new WaitingTasksProcessor(new CompoundProcessor(
@ -78,7 +76,7 @@ public class PacProcessorFactory implements EntityProcessorFactory {
createNetworkInterfacesProc(hiveValues, pacValuesList),
createSudouersProc(hiveValues, pacValuesList),
createProftpdConfProc(hiveValues, pacValuesList)));
waitingProcessor.appendProcessor(pac.getHiveName(), createDelUserProc(unixUser.getName()), "remove packet");
waitingProcessor.appendProcessor(pac.getHiveName(), createDelUserProc(pac.getName()), "remove packet");
return waitingProcessor;
}