Restore Process
Use the Restore API process to automatically restore projects in batch.
Process Settings
Below are the settings you must define for the Restore API process.
Setting | Description | Sample Value |
---|---|---|
ProcessID | This setting informs Cobra to run the Restore process. | Restore |
FileName | This setting refers to the name of the file you want to restore.
You can specify a comma delimited list of file names to restore. You cannot restore a combination of legacy and *.BK file extensions in a single Restore API process (*.BKCP and .CMP). A single Restore API process must contain files with the same file extensions. This setting is required. Note: The files are restored in the order they are defined in this parameter in the API script.
|
DEMOADV.BKCP |
Path | This setting refers to the directory containing the backup files.
If you leave this setting blank, the Cobra directory is used by default. This setting is required. |
C:\Cobra\System\DemoData\ |
OverWriteAll | If the setting value is
0, the Restore process skips the files that are being restored if they already exist in Cobra.
This setting is required and the default value is 1. |
0 |
UseBulkDataLoader |
If the setting value is 1, Cobra runs the Restore process with the Bulk Data Loader method. If the setting value is 0, Cobra proceeds with the normal Restore process. If the setting value is not specified, Cobra uses the value of the UseBulkDataLoader setting defined for the Restore process on the Advanced tab of the Application Preferences dialog box. Otherwise, this setting defaults to 0. Cobra ignores this setting in any of the following conditions:
|
1 |
BulkDataLoaderOutputPath |
Use this setting to define the output path where running the Restore process with the Bulk Data Loader method will send the CSV files, control files, batch files, and log files. If the setting value is not specified, Cobra uses the value of the BulkDataLoaderFilesOutputPath setting defined for the Restore process on the Advanced tab of the Application Preferences dialog box. Otherwise, this setting defaults to C:\Users\<User>\Documents\Deltek\Cobra. Cobra ignores this setting if the UseBulkDataLoader setting value is 0. |
C:\Users\Demo\BulkDataLoader\Output |
BulkDataLoaderExePath | Use this setting to specify the location of the Bulk Data Loader executable file to avoid manually editing the generated batch file every time you run the Restore process with the Bulk Data Loader method. If the setting value is not specified, Cobra uses the value of the
BulkDataLoaderExePath setting defined for the Restore process on the Advanced tab of the Application Preferences dialog box. Otherwise, this setting defaults to blank.
Cobra ignores this setting if the UseBulkDataLoader setting value is 0. |
C:\Users\Demo\BulkDataLoader\Exe |
OnlyConvertToBKFormat |
If the setting value is 0 or not defined, Cobra converts the legacy backup file to the BK format and runs the Restore process on each converted legacy backup file. If the setting value is 1, Cobra only converts the legacy backup file to the BK format without running the Restore process. Cobra ignores this setting when BK files are defined in the FileName setting. |
1 |
ConvertedBKFilePath |
Use this setting to specify the directory to create the BK file copies of the legacy backup files. If the directory is not specified, this setting defaults to the same directory specified in the Path setting. This setting is required when you use the OnlyConvertToBKFormat setting. Cobra does not proceed with the Restore process and logs an error in the process log if the specified directory is invalid. Cobra ignores this setting when BK files are defined in the FileName setting. |
C:\Cobra\System\LegacyBackUp\ |
Sample Script
[Process022]
ProcessID=Restore
FileName=DEMOADV.BKCP
Path=C:\Cobra\System\DemoData\
OverWriteAll=0
UseBulkDataLoader=1
BulkDataLoaderOutputPath=C:\Users\Demo\\BulkDataLoader\Output
BulkDataLoaderExePath=C:\Users\Demo\BulkDataLoader\Exe