Program: 141760
Project: 141760
Buggy source:
private void addJobFilesToExport(IProgressMonitor monitor) throws Exception {
  String directoryName=serviceManager.getRootFolderName(tempFolder);
  exportChoiceMap.put(ExportChoice.needJobItem,false);
  for (  RepositoryNode node : nodes) {
    JobScriptsManager osgiManager=new OSGIJavaScriptForESBWithMavenManager(exportChoiceMap,"String_Node_Str","String_Node_Str",IProcessor.NO_STATISTICS,IProcessor.NO_TRACES){
      @Override protected Map<String,String> getMainMavenProperties(      Item item){
        Map<String,String> mavenPropertiesMap=super.getMainMavenProperties(item);
        mavenPropertiesMap.put(EMavenBuildScriptProperties.ItemGroupName.getVarScript(),getGroupId());
        return mavenPropertiesMap;
      }
      @Override protected void setMavenBuildScriptProperties(      Document pomDocument,      Map<String,String> mavenPropertiesMap){
        super.setMavenBuildScriptProperties(pomDocument,mavenPropertiesMap);
        String itemName=mavenPropertiesMap.get(EMavenBuildScriptProperties.ItemName.getVarScript());
        if (itemName != null && pomDocument != null) {
          Element rootElement=pomDocument.getRootElement();
          Element artifactIdEle=rootElement.element("String_Node_Str");
          if (artifactIdEle != null) {
            artifactIdEle.setText(itemName);
          }
        }
      }
    }
;
    String artefactName=serviceManager.getNodeLabel(node);
    String version=node.getObject().getVersion();
    String destinationPath=tempFolder + PATH_SEPERATOR + artefactName+ osgiManager.getOutputSuffix();
    osgiManager.setDestinationPath(destinationPath);
    JobExportAction job=new JobExportAction(Collections.singletonList(node),version,osgiManager,directoryName);
    job.run(monitor);
    ZipToFile.unZipFile(destinationPath,tempFolder + PATH_SEPERATOR + ServiceExportWithMavenManager.OPERATIONS_PATH+ artefactName);
    FilesUtils.removeFile(new File(destinationPath));
  }
}

Fixed version (ground truth):
private void addJobFilesToExport(IProgressMonitor monitor) throws Exception {
  String directoryName=serviceManager.getRootFolderName(tempFolder);
  exportChoiceMap.put(ExportChoice.needJobItem,false);
  for (  RepositoryNode node : nodes) {
    JobScriptsManager osgiManager=new OSGIJavaScriptForESBWithMavenManager(exportChoiceMap,"String_Node_Str","String_Node_Str",IProcessor.NO_STATISTICS,IProcessor.NO_TRACES){
      @Override protected Map<String,String> getMainMavenProperties(      Item item){
        Map<String,String> mavenPropertiesMap=super.getMainMavenProperties(item);
        mavenPropertiesMap.put(EMavenBuildScriptProperties.ItemGroupName.getVarScript(),getGroupId());
        return mavenPropertiesMap;
      }
      @Override protected void setMavenBuildScriptProperties(      Document pomDocument,      Map<String,String> mavenPropertiesMap){
        super.setMavenBuildScriptProperties(pomDocument,mavenPropertiesMap);
        String itemName=mavenPropertiesMap.get(EMavenBuildScriptProperties.ItemName.getVarScript());
        if (itemName != null && pomDocument != null) {
          Element rootElement=pomDocument.getRootElement();
          Element artifactIdEle=rootElement.element("String_Node_Str");
          if (artifactIdEle != null) {
            artifactIdEle.setText(itemName);
          }
        }
      }
    }
;
    String artefactName=serviceManager.getNodeLabel(node);
    String version=node.getObject().getVersion();
    File destFile=new File(tempFolder + PATH_SEPERATOR + artefactName+ osgiManager.getOutputSuffix());
    String destinationPath=destFile.getAbsolutePath();
    osgiManager.setDestinationPath(destinationPath);
    JobExportAction job=new JobExportAction(Collections.singletonList(node),version,osgiManager,directoryName);
    job.run(monitor);
    ZipToFile.unZipFile(destinationPath,tempFolder + PATH_SEPERATOR + ServiceExportWithMavenManager.OPERATIONS_PATH+ artefactName);
    FilesUtils.removeFile(destFile);
  }
}