Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Supported Operations

Import/Export provides IMPORT, LIST, EXPORT, and DELETE operations for supported portal entities.

Import

Adds the entities defined in the specified XML file(s) to the portal database. If the specified entities are already present – determined by Id, Name, or other primary key, as appropriate – this operation will update the existing entity to match the information provided in the XML.

Usage
Code Block
titleImport Multiple Files
ant  >ant crndata-import -Ddir={path-to-directory} [-Dpattern={regex}]

...

Note
titleThe -Dpattern Argument

Regex special characters overlap heavily with OS/Shell special characters. It's often better to avoid the -Dpattern argument altogether. You can always place desired files into a new directory for import.

Code Block
titleImport Single File

ant data-import -Dfile={path-to-file}

Where path-to-file is a file system path, absolute or relative, containing uPortal Import/Export XML file.

List

Lists the data types the portal knows how to import/export/delete and can list all of the data currently in the database for a specific type.

Usage
Code Block
List Data Types
List Data Types

ant data-list

Export

Creates XML files representing the requested entities and writes them to the specified file system location.

Usage
Code Block
ant  >ant crndata-export [-Ddir={path-to-directory}] -Dtype={entity-type} [-Dsysid={entity-identifier}]

...

Warning
titleWarning

The DELETE feature should be used with extreme caution and is more appropriate for DEV and TEST portals than for PROD. It is possible to make your portal unusable by deleting the wrong thing.

Usage
Code Block
  >ant crn-delete -Dtype={entity-type} [-Dsysid={entity-identifier}]

...