Oracle GlassFish Server 3.0.1 Application Deployment Guide

ProcedureTo Deploy an Application or Module Automatically


Note –

This task is best suited for use in a development environment.


Automatic deployment involves copying an archive file into a special autodeploy directory where the archive is automatically deployed by GlassFish Server at predefined intervals. This method is useful in a development environment because it allows new code to be tested quickly. Automatic deployment is enabled by default.

  1. (Optional) Use the set(1) subcommand to adjust the autodeployment interval.

    This sets the interval at which applications and modules are checked for code changes and dynamically reloaded. The default is 2.

  2. (Optional) Use the set(1) subcommand to enable JSP precompilation.

  3. Copy your archive file to the autodeploy directory.

    The default location is domain-dir/autodeploy. The application will be deployed at the next interval.

    To undeploy an automatically deployed application or module, remove its archive file from the autodeploy directory.


    Note –

    Deployment directories might change between GlassFish Server releases.



Example 2–15 Setting the Autodeployment Interval

This example sets the autodeployment inverval to 3 seconds (default is 2).


asadmin> set server.admin-service.das-config.autodeploy-polling-interval-in-seconds=3
Command set executed successfully.


Example 2–16 Setting JSP Precompilation

This example enables JSP precompilation (default is false).


asadmin>  
set server.admin-service.das-config.autodeploy-jsp-precompilation-enabled=true
Command set executed successfully.

See Also

You can also view the full syntax and options of the subcommand by typing asadmin help set at the command line.