Package org.apache.synapse.transport.pipe

Transport that reads messages from a UNIX pipe.


Interface Summary
Protocol Datagram stream protocol implementation.
ProtocolDecoder Datagram stream decoder.

Class Summary
EndDelimitedProtocol End delimited protocol implementation.
PipeConstants Utility class defining constants used by the pipe transport.
PipeDispatcher DatagramDispatcher implementation for the pipe transport.
PipeEndpoint Pipe endpoint description.
PipeEndpointListener Runnable that reads messages from a given UNIX pipe.
PipeListener Transport listener for UNIX pipes.

Package org.apache.synapse.transport.pipe Description

Transport that reads messages from a UNIX pipe.

The transport accesses pipes using standard Java file I/O. Note that this only works with UNIX pipes (FIFOs), not with Windows named pipes. Also, Java does not support non blocking I/O on files.

While pipes are streams, this transport is built as a datagram transport, i.e. messages are read entirely into memory before they are processed. Indeed, given that a pipe is a unique communication channel between two local processes it would not make sense to let the processing of a message block the reception of the next message. This is different from other stream based transports such as HTTP where multiple concurrent channels exist and where it makes sense to use streaming, i.e. read the message while it is being processed.

To listen on a given pipe, the datagram stream protocol and the content type must be specified. The stream protocol describes how the stream is decoded into individual datagrams (messages) while the content type determines how these datagrams are decoded. The protocol is specified by an implementation of the Protocol interface, while the content type is used to select the appropriate Builder with the standard lookup mechanisms in Axis2.

See the documentation of PipeListener for more information about how to configure a service to listen to a pipe.

Known issues and limitations

Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.