Oracle GlassFish Server 3.0.1 Application Deployment Guide

ProcedureTo Assemble and Deploy an Application Client

  1. Assemble the necessary client components.

    The client JAR file is created.

  2. Assemble the EJB components that are to be accessed by the client.

    The EJB JAR file is created.

  3. Assemble the client and EJB JAR files together in an EAR.

    An EAR file contains all the components of the application.

  4. Deploy the application.

    Instructions are contained in To Deploy an Application or Module.

  5. If you are using the appclient script to run the application client, retrieve the client files.

    The client JAR file contains the ties and necessary classes for the application client. In this release of GlassFish Server, the client JAR file is made up of multiple files. Use either deploy --retrieve or get-client-stubs, but not both.

    • Use the deploy(1) subcommand with the --retrieve option to retrieve the client files as part of deploying the application.

    • Use the get-client-stubs(1) subcommand to retrieve client files for a previously-deployed application.

  6. (Optional) Test the client on the GlassFish Server machine in one of the following ways:

    • If Java Web Start is enabled for the application client, use the Launch link on the Application Client Modules.

    • Run an application client by using the appclient script.

      The appclient script is located in the as-install/bin directory.

      If you are using the default server instance, the only required option is -client, which points to the client JAR file. For example:


      appclient -client converterClient.jar

      The -xml parameter, which specifies the location of the sun-acc.xml file, is also required if you are not using the default instance.

See Also

For more detailed information about Java Web Start, see Chapter 11, Developing Java Clients, in Oracle GlassFish Server 3.0.1 Application Development Guide.

For more detailed information about the appclient script, see appclient(1M).