WSO2Con 2013 CFP Banner

How to Change Tungsten-1.0 HTTP and HTTPS Port Numbers

Discuss this article on Stack Overflow
By Ruchith Fernando
  • 6 Jul, 2006
  • Level: 
  • Reads: 6951

Here we will learn how to change Tungsten-1.0 HTTP and HTTPS Port Numbers

  1. In the standalone distribution
  2. In the embeddable distribution
Ruchith Fernando
Software Engineer
WSO2 Inc.

Tungsten Standalone Distribution

By default the Tungsten standalone distribution starts the HTTP transport on port 9762 and HTTPS transport on port 9443. You can simply change these to your desired values with two simple steps:

Update "tungsten.xml" file

1. Open "conf/tungsten.xml" file in your favourite text editor. 2. Now you will be able to find the following section:
    <!--HTTP settings.-->
<HTTP>
<Port>9762</Port>
</HTTP>

<!--HTTPS settings.-->
<HTTPS>
<Port>9443</Port>
...
...
...
</HTTPS>
Now change the HTTP/Port value to the desired port number for HTTP and change HTTPS/Port value to the desired port number for HTTPS.

Update "tungsten.sh/.bat" file

Linux/Unix

When hosting Tungsten on a Unix/Linux platform you will be using the "bin/tungsten.sh" file to start Tungsten. In this case you will only have to update the last line of tungsten.sh file with the new HTTP port number.
start "$TUNGSTEN_HOME/repository" 9762

Microsoft Windows

In the case where you are using Microsoft Windows you must update the "bin/tungsten.bat" file. Find the following section in it and update the port number to your desired HTTP port.
:defaultPort
set TUNGSTEN_PORT=9762

Tungsten Embeddable Distribution

The Tungsten Embeddable Distribution is hosted in a servlet container such as Apache Tomcat. In this situation you will have to configure that particular container's HTTP and HTTPS configuration to change the port numbers.

Applies To:

WSO2 WSAS (Prebiously known as Tungsten) for Java, v1.0

WSO2Con 2014 USA