| | |
|
|
|
Packaging
Deployment of Project Zero applications is very simple. You can either use the export wizard in the Eclipse plug-in or the command-line 'package' command. In both cases, a simple zip is produced that allows the consumer to simply unzip the package and run it. There are a few options to consider when exporting your application. They are explained below.
Exporting applications in Eclipse
Right-click on the Eclipse project and click Export.... Select the Project Zero Export Wizard and click Next. Then you will be presented with the following dialog:
You have three things to decide:
- The directory where the package should be exported.
- Include source: Select yes to includes the source files (java/*, .classpath, .project). Note: This is required if you will need to import this application back into Eclipse
- Standalone: This option packages all of the applications dependencies in the zip. Select yes if any of the application's dependencies cannot be resolved from a remote repository that is accessible to the consumer. Also, select yes if any of the dependency requirements are dynamically versioned (e.g. 1.0+) since the consumer of the package could resolve a different version of the package than that which you tested. The only prereqs to run a standalone package are a JDK and the Zero CLI.
Finally, click Finish and you will find a zip file named like <project>-<version>.zip.
Importing applications into Eclipse
To import a zero application that has the source included (see export above), use the following steps:
- Click File > Import > General > Existing Projects into Workspace, then select the Select Archive File radio button.
- Select Browse... to locate your exported zero zip file (for a project that is not already in your workspace) and click OK.
- Click Finish to import the checked project.
Packaging applications with the command-line
There is a zero package command for exporting your applications on the command-line.
You have three main things to decide:
- -dir: The directory where the package should be exported. The default is <apphome>/export.
- -includeSrc: 'true' to include the source files (java/*, .classpath, .project).
- -type: 'shared' (default) or 'standalone'. The standalone option packages all of the applications dependencies in the zip. Select yes if any of the application's dependencies cannot be resolved from a remote repository that is accessible to the consumer. Also, select yes if any of the dependency requirements are dynamically versioned (e.g. 1.0+) since the consumer of the package could resolve a different version of the package than that which you tested.
|
|
r4 - 08 Feb 2008 - 10:46:47 - steveims
|
|
|
| | |