There are two methods for upgrading a server that has been deployed to Apache Tomcat.
For instructions on new installations for Tomcat, see Apache Tomcat Example Deployment.
Recommended Method
If you deployed the SOAtest and Virtualize Server using the method described in Apache Tomcat Deployment Example 1 (Recommended Method), use the following instructions to upgrade the WAR file.
- Stop Tomcat Server and locate the
<SOAVIRT_HOME>
directory. - Copy config.properties file from the
<SOAVIRT_HOME>/WEB-INF
directory to a temporary location. - Backup the workspace folder to a temporary location.
- This is only required if the
working.dir
property in the config.properties file is not specified. See working.dir for details.
- This is only required if the
- Delete the following directories from
<SOAVIRT_HOME>
:- apifiles
- axis2
- META-INF
- WEB-INF
- Extract the contents of the new WAR file into
<SOAVIRT_HOME>
. - If you backed up the workspace folder in step 3, replace the new workspace folder with the one you saved. You can skip this step if the
working.dir
property in your config.properties file is specified. - Replace config.properties file in the
<SOAVIRT_HOME>/WEB-INF
directory with the config.properties file from step 2. - Open config.properties file and verify license configuration.
- Start Tomcat (for example, from
<TOMCAT_HOME>/bin
).
Shortcut Method
If you deployed the SOAtest and Virtualize Server using the method described in Apache Tomcat Deployment Example 2 (Shortcut Method), use the following instructions to upgrade the WAR file.
- Stop Tomcat Server and locate the
<TOMCAT_HOME>/webapps/ROOT
directory. - Backup the workspace folder to a temporary location.
- This is only required if the
working.dir
property in the config.properties file is not specified. See working.dir for details.
- This is only required if the
- Delete the "ROOT" directory from the webapps directory.
- Rename the new soavirt_<version>.war file to ROOT.war.
- Copy ROOT.war into the
<TOMCAT_HOME>/webapps/
directory. - Open config.properties file from the
<TOMCAT_HOME>/webapps
and verify license configuration. - Start Tomcat (for example, from
<TOMCAT_HOME>/bin
). Browse to
http://<HOST>:<PORT>
and verify that the following message is displayed:There are no deployments on this server. Cannot respond to this request: /.
- Stop Tomcat Server.
- If you backed up the workspace folder in step 2, replace workspace folder with the one you saved. You can skip this step if the
working.dir
property in your config.properties file is specified. - Restart Tomcat Server.
Confirming Server Readiness
You can confirm that your server is ready and available a couple ways.
Browser Request Method
To confirm that your server is ready, browse to http://<HOST>:<PORT>
(for example, http://localhost:8080/
). One of the following messages should appear.
No virtual asset or proxy found at this path: /
Enabled virtual assets:
...
There are no deployments on this server. Cannot respond to this request: /.
Curl Command Method
Run the following command to check the health status of the server:
curl -X GET "http://<HOST>:<PORT>/soavirt/api/v6/healthcheck" -H "accept: */*"
This command returns a 200
status code if the server is healthy and a 500
status code if there is an issue with the server.
If your server is healthy, you can validate your existing deployments with a command like the following:
curl -X GET "http://<HOST>:<PORT>/soavirt/api/v6/virtualAssets?fields=id%2Cname%2Cenabled" -H "accept: application/json"
The output should show you available virtual assets.