ZCC Bundle Import using Directory option Fails

  • 7022882
  • 24-Apr-2018
  • 26-Apr-2018

Environment

ZENworks Configuration Management 2017 Bundles

Situation

ZCC Bundle Import using Directory option Fails 
Exporting Bundles from a zone, then creating new Bundles in ZCM 2017
Using ZCC > Bundle Import with selecting the Directory option crashes ZCC after uploading.
zcc.log

[DEBUG] [04/17/2018 09:24:28.723] [1776] [ZENServer] [119] [__z_1_27__] [ZCC]
[] [java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl
cannot be cast to com.novell.zenworks.datamodel.objects.bundles.Bundle .... [DEBUG] [04/17/2018 09:24:28.724] [1776] [ZENServer] [119] [__z_1_27__] [ZCC]
[] [javax.servlet.jsp.JspException: Unable to call method 'validateBundleImportConfig'

Resolution

The Folder structure for these files and directories must have the same name as the bundle.
In this example the Bundle that was exported was Notepad++.0.3.1
Put the exported files in this directory Notepad++.0.3.1
Put the Notepad++.0.3.1 directory (and any other exports) in a master directory named anything you wish.

In this example the master directory is named "BundleExportDir", which contains the directory with the name of the exported bundles.
When importing, authenticate to ZCC > Bundle > pick the folder you wish to put these imported bundles into.
Select New > Import Bundle | Select Directory and browse
Navigate to and select "BundleExportDir" then select upload.
Then finish the Bundle import wizard.

Cause

Bundle format is incorrect.
Any bundle being imported which has an xml file as a content should have the folder structure in a specific order.

Additional Information

Example: Exporting Notepad++.0.3.1 and importing to a zone.

The export contains;
XML Files - Notepad++.0.3.1.xml, Notepad++.0.3.1_ActionContentInfo.xml
Content Directory - Notepad++.0.3.1_content
These files and Content Directory should be nested in a directory the same name as the Bundle Name:
In this case the directory name would be: Notepad++.0.3.1

Create a master directory naming it anything, example: "BundleExportDir"
All import bundle directories can be nested in that "BundleExportDir"
directory.
When using the ZCC > Bundle Import using Directory option, point to the master directory "BundleExportDir" with all the bundles to import within "BundleExportDir".
ZCC will mass import all bundles in the "BundleExportDir".