Deployment previews
You can preview a deployment before you deploy a package to the target environment. By previewing a deployment, you identify potential data validation errors so that you can correct them in the source environment.
You preview a deployment by selecting the Preview check box and a rollback point in the Deploy Package window. You can then review the messages and potential errors, which are either displayed in the status window or saved to a preview log file. After you correct any errors, re-create the package and then preview the deployment again or deploy it.
You do not need to enable administration mode to preview a deployment. However, you cannot preview a deployment if structural changes are pending in the target environment or if a package has inbound restrictions.
Rollback points
When you preview a deployment, the preview data is stored temporarily in the target database tables so that the data validations can be run. The rollback point determines how long the preview data is stored in the tables.
Rollback point | Description | When to use |
---|---|---|
Roll back every record | The data that is inserted or updated in the table is rolled back before the next record of the table is loaded. This rollback point stores the data in the target tables for the shortest time. | Use this rollback point when the content does not have dependencies. For example, use this rollback point for currency data. |
Roll back every XML document | The data remains in the target tables until all the records of an XML document in a package are loaded. The data that is inserted or updated in the table is rolled back before the next XML document is processed. | Use this rollback point when one row of a table depends on another row of the same table, such as in a hierarchy of classifications. |
Roll back every object structure | The data remains in the target tables until all the records of all the XML documents for an object structure are loaded. Depending on the volume of data, the data for a table might span multiple XML documents. The data that is inserted or updated in the table is rolled back before the next object structure is processed. | Use this rollback point for a set of domains where the domain content spans multiple XML documents. |
Roll back every migration group | The data for all the object structures of a migration group type is stored in the target tables until the data for the entire migration group is loaded. The data that is inserted or updated in the table is rolled back before the next migration group type is processed. This rollback point stores the data in the target tables for the longest time. | Use this rollback point when the content has dependencies, such as for the data dictionary object structures. Do not use this rollback point for big packages. |
Memory constraints
A deployment preview can use a substantial amount of memory in the application server. The amount that is used depends on the size of the package and the rollback point.
Before and during a deployment preview, Migration Manager checks the memory and stops the preview if a threshold is reached. The mxe.dm.previewfreememorythreshold system property defines the threshold as a percentage of the total available memory. Its default value is 20, which means that the preview stops, or cannot start, if less than 20% of the available memory is available.
Large packages, such as those that contain multiple migration groups and thousands of records, cannot be previewed. However, you can create several smaller packages by collecting subsets of the data in snapshot packages and by specifying SQL criteria. You can also reduce the number of migration groups in a package.
The preview log file indicates the available memory at each rollback point. Therefore, by rolling back at every record, you can study the preview log file to determine how much memory is used by a deployment preview.
Preview log files
The preview log file provides details on what occurs if the package is deployed. For example, the preview log file lists the processing of the XML documents that comprise the package and the data validations that check the configuration data in the XML documents. If data validation errors occur, the error messages are included in the preview log file. One validation error is captured for each record that is previewed, even if multiple errors occur for a record.
If you preview a deployment of a package again, the previous preview log file is deleted and a new log file is created. If you deploy a package that was previously previewed, the preview log file is deleted.
When a deployment preview completes, you can download the preview log file from the Package tab of the Migration Manager application.
The name of the preview log file matches the package name and has the suffix _preview and the extension .log.
Configuration commands and script log files
If the package includes structural changes that require the database to be configured, you can include the configuration commands in the preview log file and the script log file. However, the configuration changes do not occur.
The configuration commands are SQL-based Data Definition Language (DDL) statements. The commands are written to a script log file that is in the same folder as the preview log file. You can use the script log file to assess the structural changes, but you cannot run the script file on the target database.
The name of the script log file name matches the package name and has the suffix _script and the extension .log.