IntegrationProjectLock.ensureLockHeld();
checkArgument(name.length() > 0, "name cannot be empty");
checkNotNull(rootDirectory, "rootDirectory");
ProjectUtils.prepareRootDirectory(rootDirectory);
IntegrationProject project = IntegrationProject.createNewProject(name);
project.setGlobalDataElements(new DefaultGlobalDataElements());
project.setLocationOnDisk(rootDirectory);
ProjectFile projectFile = ProjectFile.createForNewProject(project, rootDirectory);
projectFile.setCreationTimestamp(System.currentTimeMillis());
projectFile.update(project);
SystemObjects.populate(project);