This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.

TCP Transport

The TCP transport implementation is in the Apache WS-Commons Transports project. The two classes that act as the transport listener and the sender are org.apache.axis2.transport.tcp.TCPServer and org.apache.axis2.transport.tcp.TCPTransportSender respectively. In order to use the transport axis2-transport-tcp.jar should be added to the Carbon classpath.

Transport receiver parameters

Parameter Name

Description

Requried

Possible Values

Default Value

port

The port on which the TCP server should listen for incoming messages

No

A positive integer less than 65535

8000

hostname

The host name of the server to be displayed in WSDLs etc

No

A valid host name or an IP address

 

Transport sender parameters

The TCP transport sender does not accept any configuration parameters as of now.

To enable the TCP transport for samples, simply open the repository/conf/axis2.xml file in a text editor and add the following transport receiver configuration and sender configuration. TCP transport module is shipped with WSO2 ESB by default.

<transportReceiver name="tcp">
    <parameter name="transport.tcp.port">6060</parameter>
</transportReceiver>

<transportSender name="tcp"/>

If you wish to use the sample Axis2 client to send TCP messages, you have to remove the comment of the TCP transport sender configuration in the following file:

samples/axis2Client/client_repo/conf/axis2.xml