Once you have the Netscape Application Server installed and running, you can use the sample applications provided to ensure that the server is working properly. The sample applications also provide a means of testing and learning about this product.
Netscape Application Server offers sample applications written in both C++ and Java. The following table lists the sample applications provided and describes the application and the language in which it was developed.
Configuring the Sample Applications and Files
Configuring the sample applications consists of connecting to the database, loading the sample data into the database, and configuring the sample data source. The applications can access the data sources through an ODBC database driver or through a native database driver.
Netscape supplies configuration and data-loading files to simplify the population of the database with the sample application data. These files are for UNIX and Windows NT operating systems.
For installations of Netscape Application Server on the UNIX operating system, there are shell scripts that handle the configuration tasks. There are separate scripts for each database into which you are going to load the data. The scripts can be used for the following databases:
Solaris
Oracle, Informix, Sybase, DB2
HPUX
Oracle, Informix, Sybase (C++ only), DB2 (C++ only)
There are also separate shell scripts for each sample application that performs database access. These files are located in the DB directory of the appropriate application.
Before you run the shell script, you should edit the login and password of the script to match that of your database administrator account.
Connecting to the database is done using the database vendor's client utilities or by invoking the shell scripts from the shell prompt. The shell scripts invoke the programs necessary to connect to the database, configure the sample application account, and invoke the SQL files used to populate the database with the data.
After you run the appropriate script, you need to configure the new data source so that the application can access the data. The sample applications can access the database through an ODBC driver or through a native database driver.
For configuring native database drivers, you can use the client utilities provided with the database, or you can edit the appropriate data source name file. The databases vendors provide the following client utilities for accessing their databases:
For more information about these vendor utilities, see the documentation provided with the utilities.
Configuring the data source for an ODBC driver requires that you edit the odbc.ini file to reflect the new data source name and server ID. Use the entries already in the file as a guide to add the new data source.
The following tasks are automated by invoking the appropriate shell script for your database. The shell scripts are provided with the sample applications.
To configure the sample applications for UNIX
Make sure the destination database is running and that you have modified the shell scripts login and password to match that of your database administrator account.
To connect to the database and load the data, do one of the following:
<NAS installation directory>/APPS/GXApp/load_ora.sh
<NAS installation directory>/APPS/GXApp/load_mssql.sh
<NAS installation directory>/APPS/GXApp/load_ifmx.sh
<NAS installation directory>/APPS/GXApp/load_db2.sh
You can also invoke these files from within the database client utilities.
Make sure you connect to the database as a system user.
The sample data is loaded when the shell script finishes running.
To configure the new data source for access through a native driver, do one of the following:
The sample data source is now configured and can be accessed by the
sample applications.
|