Exporting packages from database
Glossary Item Box
Introduction
To transfer custom packages between non-shared environments (e.g. development and test environments), you must first export these packages to the file system. To save packages from the database, use the SaveDBContent operation of the WorkspaceConsole utility. Learn more about the WorkspaceConsole utility in the “WorkspaceConsole parameters” article.
NOTE Make sure the settings of the WorkspaceConsole utility are correct before you run it. Please refer to the “WorkspaceConsole settings” article for more details. |
To save packages from the database, run the WorkspaceConsole utility with the following parameter values:
Table 1. WorkspaceConsole utility parameters for saving database packages
Parameter | Value | Description |
---|---|---|
operation | SaveDBContent |
Saves database content to the file system. Content type is determined by the contentTypes parameter value. The destinationPath parameter is used to specify the path in a file system. |
contentTypes | Repository | Type of content uploaded to a file system. The Repository value is used to upload the workspace to a catalog specified in the destinationPath parameter. The name of the workspace is specified in the workspaceName parameter. |
workspaceName | [Workspace name] | The name of the workspace (configuration) with the saved packages. By default, all users work in the Default workspace. |
destinationPath | [Path to local directory] |
Path to a local directory in the file system. Packages with the *.gz format are saved in this directory. |
All workspace packages are saved in the process. It may take up to 10 minutes to complete this operation. |
NOTE Check data binding properties before saving. This includes system settings, lookups, section data etc. Please refer to the “Binding data to package” article for more details. |
Command signature for Windows command prompt that will export packages from the database:
[WorkspaceConsole path]\Terrasoft.Tools.WorkspaceConsole.exe -operation=SaveDBContent -contentTypes=Repository -workspaceName=[Workspace name] -destinationPath=[Local directory path]
NOTE We recommend using batch files (*.bat) to create and save commands. |
Uploading packages to a file system
Case description
The bpm’online application is installed in the C:\bpmonline7.9.2 directory. Export all Default workspace packages into the C:\SavedPackages directory.
Case implementation:
Use any text editor to create a batch command file (*.bat or *.cmd) with a command that will launch the WorkspaceConsole utility. Enter the following command in the file:
C:\bpmonline7.9.2\Terrasoft.WebApp\DesktopBin\WorkspaceConsole\Terrasoft.Tools.WorkspaceConsole.exe -operation=SaveDBContent -contentTypes=Repository -workspaceName=Default -destinationPath=C:\SavedPackages
pause
Upon saving the batch file and running it, a console window will appear, and the WorkspaceConsole execution process with specified parameter values will be displayed (Fig. 1).
Fig. 1. WorkspaceConsole execution
Zip-archives containing all Default configuration packages will be exported to the C:\SavedPackages directory (Fig. 2).
Fig. 2. Zip-archives with bpm'online packages exported to the file system