web server - Borland Technical Publications
web server - Borland Technical Publications web server - Borland Technical Publications
Using the iastool command-line tools Options The following table describes the options available when using the compilejsp tool. Option -src -target -overwrite -package -excludefile -loglevel -classpath Description Specifies the WAR or EAR file you want to compile. The full or relative path to the file must be specified. There is no default. Specifies the name of the target WAR or EAR archive file to be generated. If file name you specify already exists, use the -overwrite option to overwrite the previously existing target. The full or relative path to the file must be specified. There is no default. Indicates that the should be overwritten if it previously existed. If exists but -overwrite is not used, you will get an error message saying that the target JAR must be different from the source JAR. Specifies the base package name for the precompiled JSP servlet classes. The default is com.bes.compiledjsp. Specifies a text file containing a list of JSP files to exclude from the compile operation. See “Using the excludefile option” on page 295 for more details. Specifies the amount of output diagnostic messages to be generated. A value greater than 2 will also leave the temporary servlet Java files for further inspection. The default is 2. Specifies any additional libraries that may be required for compiling the JSP pages. There is no default. Example To precompile the JSP pages contained in a WAR file called proj1.war located in the current directory into a WAR file called proj1compiled.war in the same location: iastool -compilejsp -src proj1.war -target proj1compiled.war To precompile the JSP pages contained in an EAR file called proj1.ear located in the directory c:\myprojects\ into an EAR file called proj1compiled.ear in the same location and generate the maximum amount of diagnostic messages: iastool -compilejsp -src c:\myprojects\proj1.ear -target c:\myprojects\proj1compiled.ear -loglevel 4 Using the excludefile option The compilejsp excludefile option allows you to specify a text file containing a list of JSPs to exclude from the compile operation. The following list details the usage rules. ■ ■ ■ ■ ■ ■ Comment lines (with a leading '#') and blank lines are ignored. Leading and trailing blank spaces and white spaces on each line are trimmed. Each line in the exclude file represents one exclude pattern entry, which can be a string for exact matching or a Java Pattern regular expression. Each JSP exclude entry is used to perform an exact match against a JSP URL first. If there is no match, the JSP exclude entry will be used as a regular expression to match against the JSP URL again. A JSP URL is compared against each of the JSP exclude entries using the above algorithm. As soon as there is a match, the JSP is excluded from compilation. If the JSP URL does not match any of the JSP exclude entries, the JSP will be compiled. If a pattern entry is not a valid Java regular expression, a warning is shown. It will still be used to compare against JSP URLs for exact match. Chapter 29: iastool command-line utility 295
Using the iastool command-line tools ■ If the iastool -compilejsp -loglevel option is set to 3 or higher, the exclude pattern entries, the number of excluded JSP pages, and the excluded JSP URLs are be displayed. ■ If all of the JSP files in the archive are excluded the -compilejsp command will fail. The following are some example exclude patterns: # This pattern excludes a specific JSP: /jsp/test/test.jsp /jsp/test/test[.]jsp # This pattern excludes the JSP /jsp/test/test.jsp or /jsp/test/test2jsp, etc. # because the regular expression "." represents any character /jsp/test/test.jsp # This pattern excludes all the files under the /include URL path /include/.* # This pattern excludes all the include.jsp files .*/include[.]jsp # This pattern excludes all the JSP files that start with "tmp_" in the /jsp URL path # and all JSP files in any URL path that starts with "tmp_" under /jsp /jsp/tmp_.*[.]jsp # This pattern excludes all the JSP files that start with "tmp_" in the /jsp URL path /jsp/tmp_[^/]*[.]jsp compress Use this tool to compress a JAR file. Syntax -compress -src -target Default Output By default, compress reports if the operation was successful or not. Options The following table describes the options available when using the compress tool. Option -src -target Description Specifies the JAR file that you want to compress. The full or relative path to the file must be specified. There is no default. Specifies the name of the compressed JAR file to be generated. The full or relative path to the file must be specified. There is no default. Example To compress a JAR file, called proj1.jar and located in the current directory, into a file called proj1compress.jar in the same location: iastool -compress -src proj1.jar -target proj1compress.jar 296 BES Developer’s Guide
- Page 255 and 256: Creating the JAR file Creating the
- Page 257 and 258: Components Components The Connector
- Page 259 and 260: System Contracts Connection Managem
- Page 261 and 262: System Contracts Security Managemen
- Page 263 and 264: Common Client Interface (CCI) Conne
- Page 265 and 266: Packaging and Deployment Figure 26.
- Page 267 and 268: Resource Adapters Resource Adapters
- Page 269 and 270: Connection management Connection ma
- Page 271 and 272: Security management with the Securi
- Page 273 and 274: Security management with the Securi
- Page 275 and 276: Resource Adapter overview Note Reso
- Page 277 and 278: Deployment Descriptors for the Reso
- Page 279 and 280: Developing the Resource Adapter Con
- Page 281 and 282: Deploying the Resource Adapter Pack
- Page 283 and 284: Application development overview 8
- Page 285 and 286: Application development overview //
- Page 287 and 288: Application development overview
- Page 289 and 290: Other Considerations Other Consider
- Page 291 and 292: Other Considerations To illustrate,
- Page 293 and 294: Other Considerations } } { cf = new
- Page 295 and 296: General syntax and usage General sy
- Page 297 and 298: Syntax and usage for iastool Table
- Page 299 and 300: Syntax and usage for java2iiop Exam
- Page 301 and 302: Syntax and usage for appclient Tabl
- Page 303 and 304: Building and running the BES exampl
- Page 305: Using the iastool command-line tool
- Page 309 and 310: Using the iastool command-line tool
- Page 311 and 312: Using the iastool command-line tool
- Page 313 and 314: Using the iastool command-line tool
- Page 315 and 316: Using the iastool command-line tool
- Page 317 and 318: Using the iastool command-line tool
- Page 319 and 320: Using the iastool command-line tool
- Page 321 and 322: Using the iastool command-line tool
- Page 323 and 324: Using the iastool command-line tool
- Page 325 and 326: Using the iastool command-line tool
- Page 327 and 328: Using the iastool command-line tool
- Page 329 and 330: Using the iastool command-line tool
- Page 331 and 332: Using the iastool command-line tool
- Page 333 and 334: Executing iastool command-line tool
- Page 335 and 336: 324 BES Developer’s Guide
- Page 337 and 338: element ■ ■ ■ element The
- Page 339 and 340: element The Partition statistics ag
- Page 341 and 342: element element The services eleme
- Page 343 and 344: element element The archive elemen
- Page 345 and 346: EJB Container-level Properties Tabl
- Page 347 and 348: EJB Container-level Properties Tabl
- Page 349 and 350: EJB Customization Properties: Deplo
- Page 351 and 352: Complete Index of EJB Properties Co
- Page 353 and 354: Complete Index of EJB Properties Ta
- Page 355 and 356: Complete Index of EJB Properties Ta
Using the iastool command-line tools<br />
Options<br />
The following table describes the options available when using the compilejsp tool.<br />
Option<br />
-src <br />
-target <br />
-overwrite<br />
-package <br />
-excludefile <br />
-loglevel <br />
-classpath <br />
Description<br />
Specifies the WAR or EAR file you want to compile. The full<br />
or relative path to the file must be specified. There is no<br />
default.<br />
Specifies the name of the target WAR or EAR archive file to<br />
be generated. If file name you specify already exists, use the<br />
-overwrite option to overwrite the previously existing target.<br />
The full or relative path to the file must be specified. There is<br />
no default.<br />
Indicates that the should be overwritten if it<br />
previously existed. If exists but -overwrite is not<br />
used, you will get an error message saying that the target<br />
JAR must be different from the source JAR.<br />
Specifies the base package name for the precompiled JSP<br />
servlet classes. The default is com.bes.compiledjsp.<br />
Specifies a text file containing a list of JSP files to exclude<br />
from the compile operation. See “Using the excludefile<br />
option” on page 295 for more details.<br />
Specifies the amount of output diagnostic messages to be<br />
generated. A value greater than 2 will also leave the<br />
temporary servlet Java files for further inspection. The<br />
default is 2.<br />
Specifies any additional libraries that may be required for<br />
compiling the JSP pages. There is no default.<br />
Example<br />
To precompile the JSP pages contained in a WAR file called proj1.war located in the<br />
current directory into a WAR file called proj1compiled.war in the same location:<br />
iastool -compilejsp -src proj1.war -target proj1compiled.war<br />
To precompile the JSP pages contained in an EAR file called proj1.ear located in the<br />
directory c:\myprojects\ into an EAR file called proj1compiled.ear in the same location<br />
and generate the maximum amount of diagnostic messages:<br />
iastool -compilejsp -src c:\myprojects\proj1.ear -target<br />
c:\myprojects\proj1compiled.ear -loglevel 4<br />
Using the excludefile option<br />
The compilejsp excludefile option allows you to specify a text file containing a list of<br />
JSPs to exclude from the compile operation. The following list details the usage rules.<br />
■<br />
■<br />
■<br />
■<br />
■<br />
■<br />
Comment lines (with a leading '#') and blank lines are ignored.<br />
Leading and trailing blank spaces and white spaces on each line are trimmed.<br />
Each line in the exclude file represents one exclude pattern entry, which can be a<br />
string for exact matching or a Java Pattern regular expression.<br />
Each JSP exclude entry is used to perform an exact match against a JSP URL first.<br />
If there is no match, the JSP exclude entry will be used as a regular expression to<br />
match against the JSP URL again.<br />
A JSP URL is compared against each of the JSP exclude entries using the above<br />
algorithm. As soon as there is a match, the JSP is excluded from compilation. If the<br />
JSP URL does not match any of the JSP exclude entries, the JSP will be compiled.<br />
If a pattern entry is not a valid Java regular expression, a warning is shown. It will<br />
still be used to compare against JSP URLs for exact match.<br />
Chapter 29: iastool command-line utility 295