A listener provides a communication channel for clients (such as 3270 emulators, or batch submission) to a CICS or JES region.

It is configured to provide one or more channels to a region or regions. Each channel is associated with a TCP port, a protocol (such as TN3270 or MFBINP), and a CICS or JES region name.

A client, such as a 3270 emulator, connects to the port for an appropriate channel. The listener does any work needed to set up the conversation. It then connects to the dispatcher to establish contact with the region. A listener can also connect directly to SEPs.

The listener listens for input from both the clients and the SEPs to which it is connected. It forwards input from the clients to the region for processing, and it sends responses from the SEPs back to the clients.

A listener can be started as either a Windows service or a Windows console application. When the dispatcher and SEP are hosted under IIS, the listener is normally run as a Windows service. When the dispatcher and SEP are self-hosted, it is normally run as a Windows console application. The -was command line option determines whether the listener communicates with an IIS-hosted or self-hosted dispatcher.

A listener forwards new client sessions and client input to a dispatcher, and receives responses from a SEP to send back to the client. A dispatcher can also send a response back to a client via the listener. For example, in the case of a CICS session, it can free up the keyboard if the Clear key is pressed and no next transaction is associated with the session, or send an error response when the region isn't started.