Creating a Package
This topic describes the
Package Inventory File and the
Package (.djar) File, and then provides instructions
To create a package using the New Package Wizard:. The New Package Wizard first generates a package inventory file. The package inventory file is then used to generate the package (.djar) file.
A package is a compressed, portable (.djar) file which can be executed directly from the command line of the engine (see
Using Runtime Engine). Users can also upload the .djar file to Integration Manager (see
Using Integration Manager).
Package Inventory File
The package inventory file is an XML file that has the extension .inv.xml. The package inventory file contains a list of all artifacts referenced by a project. For example, if a process references a Data Profile (.dp) file, the Data Profile is included.
The package inventory file is sometimes also referred to as a manifest, archive file, package list, and inventory file.
The New Package Wizard uses the inventory file to create the .djar file. The inventory file is:
• the manifest for what's included in the .djar you create.
• the mechanism for creating the .djar.
• used for versioning the .djar. For example, the New Package Wizard versions the first .djar 1.0. You can then edit the inventory file and the artifacts it references, as needed. The version of the next .djar generated is incremented to 1.1. There is no limit to the number of .djar files the inventory file generates.
The inventory file is saved to your workspace.
Entry Point
The New Package Wizard prompts you to specify an entry point. The entry point tells the standalone engine what to execute first. The entry point must be a configuration (.rtc) file in your project. The (.rtc) file can be a process.rtc or map.rtc file.
The entry point cannot be changed in the .djar file.
Package (.djar) File
A package file is a compressed, portable file (.djar) which contains all the artifacts in a project. To deploy the package, you can execute this single .djar file directly from the command line of the engine (see
Using Runtime Engine), or provide the .djar file to Integration Manager (see
Using Integration Manager).
The .djar file is created in the New Package Wizard using the package inventory (.inv.xml) file.
To create a package using the New Package Wizard:
1. Select the project for which you want to create a package and do any of the following:
• Go to File > New > Package.
• Click the arrow in
and then click
Package.
• Right-click within Project Explorer and then click New > Package.
The New Package Wizard is displayed.
2. Select the parent folder where you want to save the package inventory file.
3. In the Enter Package Inventory Name field, type a name for the package file and click Next.
The Select Entry Point and Options dialog is displayed.
4. Specify the following:
• Choose Process or Map - Click Browse and specify the required runtime configuration file (.process.rtc or .map.rtc).
• Expand macros in references when building package (recommended) - Select this option to expand macros while packaging. Macros in referenced artifact paths are expanded, ensuring a self-contained package for distribution and execution.
• Include Macro Definition File - Select this option to include the macro definition file in the package and then select one of the following:
• Include entire Workspace Macros - Includes the entire macro definition file associated with the workspace. This is selected by default.
• Include only Configuration Macros - Includes the local macros and all the macros from the Configuration tab > Macros section for all the processes and referenced maps.
• Include Global Macros: Enabled when the Include only Configuration Macros option is selected, this option allows you to include the global macros from the workspace macro definition file.
Note: In case of duplicate macros, only the local macros configured in the process that is selected as an entry-point is added. For example, consider that there is a local macro named userName in .process.rtc file and another local macro with the same name but with a different value in .map.rtc file and this map is used within the .process.rtc (in a transformation step). When creating the inventory, if you select .process.rtc as entry-point, then the userName from .process.rtc is included in the configurationMacros.json file and not the macro from .map.rtc file.
5. Click Finish.
A progress bar is displayed in the bottom right corner. Sometimes inventory creation can take a long time so it is executed as a background process, thus allowing you to perform other tasks during this time. Click the progress bar to view the inventory creation status in the Progress tab. See
Package and Inventory Creation Progress Tab. When the progress bar is gone the UI gets refreshed.
An inventory file is created (with extension as .inv.xml) and opens in the Package Manager Editor tab. It displays all the artifacts that are included in the package.
If you selected the Include entire Workspace Macro option, then the MacroDefinition.json file is included in the package.
If you selected the Include only Configuration Macro option, then a new {nameOfPackageEntryPoint)_macros.json file is created in the same location as the workspace macro definition file. This macro definition file includes only the configuration macros used by the entry point map or process. When it is packaged in the .djar, this file name is changed to configurationMacros.json, which is required by Integration Manager.
The following information is displayed for the artifacts included in the inventory file:
• Main: The main artifact is selected by default. Select the required check box to specify another artifact as the main.
• Type: The type of artifact. For example, a map, process, macro, map configuration, etc.
• File: The file name of the artifact that is included in the package.
• Location: The location of the artifact. If the artifact is located outside the workspace or contains a macro, then it displays the full path. If the artifact is inside the workspace, then it displays the path relative to the workspace.
• Version: The version number of the artifact.
Also, the inventory (.inv.xml) file is available within the project folder.
Note: The inventory file is created relative to where the project is located.
6. Generate a .djar file using the inventory (.inv.xml) file by doing, the following:
• Open the inventory(.inv.xml) file (if it is closed).
• Verify that the main entry point (process or map) is selected while creating the package.
• Package Name displays the name of the .djar file you are creating. By default, the name is the same as the inventory file. You can change this name if required.
• Create external runtime config file - Select this option to create a runtime configuration file in the same location as the .djar. The RTC can be used with -RC package execution command line option or the client SDK.
• Overwrite external RTC - Select this option to overwrite an existing RTC. Otherwise, a unique name for the RTC will be created.
• Package Version - The version number for the .djar file. The default is 1.0. You can change this version number.
• Click
to add files to the package. To remove a file, select the required file and click
.
7. Click Create Package.
A progress bar is displayed in the bottom right corner. Sometimes package creation can take a long time so it is executed as a background process, thus allowing you to perform other tasks during this time. You can click the progress bar to display the package creation status in the Progress tab. See
Package and Inventory Creation Progress Tab. Once the package is created, the
Package Creation Success dialog displays a confirmation message along with the folder where the .djar file is stored.
Note: When you run a .djar that contains a macro definition file, djengine does not automatically use the macro file contained within the .djar, unless you explicitly provide the macro file path and name using the -mf command.
Package and Inventory Creation Progress Tab
When you initiate the creation of a package or inventory, a Progress tab is displayed. This tab enables you to view the current status, remaining time, and requests in the queue. Package or inventory creation can take some time. The process executes in the background, allowing you to perform other tasks during this time. For example, another package or inventory creation can be initiated, which is added to the Progress tab queue with the status Waiting.
Changes made to inventory files are not included once the create package process executes or is added to the queue.
Note: - To cancel a package or inventory creation process, click
(cancel).
Package Inventory Changes Pop-up Message
The following conditions determine whether the Package Inventory Changes warning message occurs:
• If the package has extra files and there are other changes, the warning message is displayed and the version number for the artifacts is incremented.
• If there are additional files in the package and no other changes have occurred, the warning message is not displayed and the version number for artifacts is not incremented.