At ArcGIS 10.1 and above, the deployment workflow for Java and .NET SOEs has changed significantly. This includes use of a container file, called a .soe file, to hold SOEs. A Java SOE exported by the Eclipse "Export SOE" wizard therefore resides in a .soe file, along with all its dependencies and accessories. The same is true also for .NET SOEs exported by Visual Studio.
In order to generate .soe files containing Java SOEs in an environment where Eclipse IDE is not available, the Java ArcObjects SDK includes a tool called SOEPackager. This tool can be invoked from the command line. It requires a jar file containing the SOE as input and generates a .soe file as output.
SOEPackager resides in the $AGSDEVKITJAVA/java/tools/soepackager folder. On Windows, it can be invoked via the soepackager.bat file. On Linux, the soepackage.sh script could be used. The following is its usage:
soepackager.bat -p [path to SOE jar file] -o [path to output folder] -j [path to the JDK] [optional parameters]
soepackager.sh -p [path to SOE jar file] -o [path to output folder] -j [path to the JDK] [optional parameters]
Following are required parameters to soepackager:
-p: absolute path to jar file containing SOE classes and dependencies
-o: absolute path to folder that must hold the newly generated .soe file
-j: path to the JDK. If the "bin" directory in JDK home is not added to your environment PATH variable, then the JDK path can be supplied directly using this parameter.
Following are optional parameters to soepackager:
-h: Shows help message
-n: Name of SOE (e.g. TestSOE). If using spaces, please enclose in double quotes.
-d: Description of SOE (e.g. "This is a test SOE")
-v: SOE Version (e.g. 1.0)
-a: SOE Author (e.g. "John Doe")
-c: Company/Organization name (e.g. "Esri")
-t: Target deployment version (e.g. 10.2)
-f: Semi-colon separated list of dependent jar files (overrides value of -l if both -f and -l are provided)
-l: Folder containing dependent jar files (ignored if -f is also used)
How to include dependent jar files?
For SOEs that depend on external jars, ensure that the SOE jar file's manifest does specify these jars in the Class-Path entry, as shown below. Use of folder names and relative paths is not supported, since all dependent jars will be housed in the same folder as SOE jar at runtime.
To bundle the dependent jars into the .soe file, the -f or -l options could be used. The -f option allows specifying one or more jar files (i.e. the absolute path to the jar files), separated by space.
soepackager.bat -p <absolute path to SOE jar file> -o <absolute path to output folder> -f "<absolute path to jar file 1> <absolute path to jar file 2>"
The -l option allows specifying a directory containing jar files.
soepackager.bat -p <absolute path to SOE jar file> -o <absolute path to output folder> -l "<absolute path to directory containing jar files>"
If -f and -l options are used simultaneously, the -f option overrides the -l option.
Including ArcGIS Manager custom property page
If the above structure is unavailable as described, SOEPackager will be unable to generate appropriate artifacts and related metadata in the .soe file. The .soe file will then still deploy to ArcGIS Server successfully, but the behavior of concerned SOEs, while enabling on map service or during runtime, would not be along expected lines.
|Development licensing||Deployment licensing|