Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
LEIF User's Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

13.3 Using the LEIF Server

The leifserver script starts and stops the container and the bundled Apache web server, and accepts a variety of options. On Windows systems, the installer places shortcuts to the scripts in the Start menu. In the installation, this script is located in your installdir\bin directory. For UNIX systems, run the script from the command line only.

13.3.1 Starting and Stopping the LEIF Server

The command below shows the sequence to stop and restart the server on both Windows and UNIX:

Win32

%RWLEIF_HOME%\bin\leifserver start

%RWLEIF_HOME%\bin\leifserver stop

UNIX/Linux

$RWLEIF_HOME/bin/leifserver start

$RWLEIF_HOME/bin/leifserver stop

The leifserver start command starts both the LEIF server and the Apache web server by default.

13.3.2 LEIF Server Ports

The LEIF server uses the following ports:

8090

Used for HTTP requests sent directly to just the LEIF server using its built-in HTTP connector.

8013

Used to route requests through the bundled Apache HTTP server. Recommended for production use.

8009

Used for communication between Apache and the LEIF server. For example, a request sent to port 8013 is then passed on to the LEIF server via port 8009.

8413

Used as the default port for HTTPS requests.

13.3.3 Deploying your Service with the Makefile

The generated makefile includes a deploy target to deploy the sample service and associated client. (See Chapter 12, "Options for Compiling," for more information on building your applications using the makefiles.) If you have compiled the service using MSVC on Windows, a deployment batch file is generated for your convenience. See Section 13.3.4.

To deploy the service, follow the steps in this section.


NOTE -- Make sure that you have set up your environment as described in Chapter 3. On Windows, be sure you have set up your command window with the MSVC environment.

If the LEIF server is currently running, stop the container by running the leifserver stop command in the RWLEIF_HOME\bin directory, as shown below:

Win32

%RWLEIF_HOME%\bin\leifserver stop

UNIX/Linux

$RWLEIF_HOME/bin/leifserver stop

Run nmake (Windows) or make (UNIX or Linux) at the command prompt with the target deploy. The makefile deploys the service and client into your LEIF installation. The DLL or shared library for the service and client is placed in installdir\apps-bin on Windows and installdir/apps-lib on UNIX/Linux.

For example, the following command line builds the sample service and client library, copies the web.xml service descriptor for the service into the webapps directory beneath in your LEIF installdir directory, and registers the service with Apache:

Win32

nmake deploy

UNIX/Linux

make deploy

Restart the container to load the new service. To restart the container, run the leifserver start in the RWLEIF_HOME\bin directory, as shown below:

Win32

%RWLEIF_HOME%\bin\leifserver start

UNIX/Linux

$RWLEIF_HOME/bin/leifserver start


NOTE -- For MSVC projects, do not use nmake deploy. See Section 13.3.4.

13.3.4 Deploying your Service Using MSVC Files

For MSVC project files, you may run the deployment batch file generated in the top level project directory as a convenience: deployDebug.bat (for debug builds) or deployRelease.bat (for release builds). Do not use nmake deploy to deploy these projects.

13.3.5 LEIF Server Options

The syntax of the leifserver script is: leifserver [options] [start|stop]. Options are:


NOTE -- If you start the LEIF server in debug mode on Windows, it loads only services and named objects compiled in debug mode, as identified by the tag 15d in the file name.

There are two standard routing options you can use when invoking a client:


NOTE -- These two options cannot be used when invoking a secure client. See Section 3.3.5, "Client Security," in the Web Services Development Guide for more information on secure clients.

If no option is given, the client request is sent to the location defined in the WSDL file. To direct the client request to some other location, enter the location on the command line immediately after the client invocation. For example, to send the request to the Apache SSL port, enter:

The LEIF examples located in your installdir\examples\webservices directory specify localhost:8090 as the service port in the WSDL file. Therefore, if you run one of the example clients without either of the above options, the request is automatically routed solely to the LEIF server. To have the client send the request through Apache, invoke the client with the -a option.



Previous fileTop of DocumentContentsIndex pageNext file

©2003-2005 Copyright Quovadx, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Quovadx, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.