How to run Nexaweb application on WebSphere Application Server

This tutorial covers step-by-step instructions on how to run a Nexaweb application on WebSphere Application Server traditional V8.5. Some of our customers use WAS as their server, and therefore in order to diagnose and work on certain support tickets we should be able to run sample applications on that server.

Please note the environment used for this tutorial -

Nexaweb Studio 6.3

Nexaweb Platform 4.5.67.0006

WebSphere Application Server traditional 8.5.5.16

Windows 10 1809 64-bit

Instructions

This tutorial assumes that you have successfully installed WebSphere Application Server traditional 8.5.5.16 successfully on your Windows machine. Please run the First Steps for you server to check whether it starts and stops without any issue.

Below is an overview of the steps involved -

  1. Create a WAR file for your Nexaweb application

  2. Start the server

  3. Log into the server administrative console

  4. Install the new application on the WAS server through the administrative console

  5. Run the application on WAS server

 This tutorial also assumes that the name of your server is “AppSrv01”. If not, then substitute your server name with AppSrv01.

Create WAR file

Go to the Nexaweb application project in your Nexaweb Studio. Right click on the project → Export → WAR file.

 

Application name for this example is WASTest1.

Make sure Target runtime section has "WebSphere Application Server traditional V8.5" selected under "Optimize for a specific server runtime". Select a destination to save the WAR file and then Finish.

Start the server

Go to Windows Start Menu → IBM WebSphere → “AppSrv01 - Start the Server” shortcut. Wait till the operation completes and the console window closes.

Log into server administrative console

Go to Windows Start Menu → IBM WebSphere → “AppSrv01 - Administrative console” shortcut.

Log into the console with your WAS admin credentials. After logging in, the main console page will open.

Install the new application on WAS server through administrative console

If you have not made the WAR file for your Nexaweb application already, please refer to step 1.

In the administrative console, click on “New Enterprise Application”, as shown below.

 

Choose the WAR file created in Step 1, then click on Next button.

 

In the next couple of steps of installing the application on the server, keep the default settings and keep clicking Next button.

In Step 4 of the installation, we need to specify the Context Root. Go back to the Nexaweb Studio, and open the project Properties window. On the left navigation panel, scroll all the way down and select Web Project Settings, as shown below.

 

Copy this Context root name and paste it in Step 4 of installation on WAS server, after the '/', as shown below.

Click on Next button to come to Step 5, which is summary. Click Finish button.

After the application is installed successfully, you may hit Save where it mentions in the instructions. See below.

 

Now click on the Manage Application link as shown in the picture above. Alternatively, go to the left navigation panel → Applications → Application Types → WebSphere enterprise applications. Now in the main panel, you will see a list of applications installed on the server. Click on the checkbox against your application and then click on the “Start” button at the top.

Before proceeding further, we need to know the port number for the server.

Run the application on the server

On the left side navigation panel, go to Servers → Server Types → WebSphere application servers .

 

When you click on your server, the main panel will show the details. On the main panel, under the “Communications” section, expand “Ports”. You will see a list of ports that the application uses and various listeners. We need the port number against the listener “WC_defaulthost” because we are using HTTP. If we use HTTPS, then we need the port number against the listener “WC_defaulthost_secure”. You can run your application on either HTTP or HTTPS.

 

Now to launch the application on the server, open your browser and type the following in the address bar - http://localhost:<port-number>/<Context-type-name-entered-in-Step-4>

The application should run now, and for reference, see the screenshot below.

 

Conclusion

We saw how to install and run a Nexaweb application on the WAS server 8.5.5.16. Please note that this method is recommended over running the WAS server through Nexaweb Studio.