Inter-process communication

In computing, Inter-process communication (IPC) is a set of methods for the exchange of data among multiple threads in one or more processes. Processes may be running on one or more computers connected by a network. IPC methods are divided into methods for message passing, synchronization, shared memory, and remote procedure calls (RPC). The method of IPC used may vary based on the bandwidth and latency of communication between the threads, and the type of data being communicated. There are several reasons for providing an environment that allows process cooperation:
    

Information sharing Speedup Modularity Convenience Privilege separation

IPC may also be referred to as inter-thread communication and interapplication communication. The combination of IPC with the address space concept is the foundation for address space independence/isolation

MECHANISMS:

*****Creating pipelines programmatically
Pipelines can be created under program control. The Unix pipe() system call asks the operating system to construct a new anonymous pipe object. This results in two new, opened file descriptors in the process: the read-only end of the pipe, and the write-only end. The pipe ends appear to be normal, anonymous file descriptors, except that they have no ability to seek.

implement signals in only the C run-time library and provide no support for their use as an IPC method[citation needed] Socket Most operating systems Message queue Most operating systems Pipe All POSIX systems. arranged so that the output of each element is the input of the next. Usually some amount of buffering is provided between consecutive elements.). Windows Semaphore All POSIX systems. bytes or bits. Windows Named pipe All POSIX systems. some systems.. etc. threads.In software engineering. such as Windows. coroutines. The concept is also called the pipes and filters design pattern. The information that flows in these pipelines is often a stream of records. It was named by analogy to a physical pipeline. Windows . a pipeline consists of a chain of processing elements (processes. Main IPC methods Method Provided by (operating systems or other environments) File Most operating systems Signal Most operating systems.

shared memory is memory that may be simultaneously accessed by multiple programs with an intent to provide communication among them or avoid redundant copies. Using memory for communication inside a single program. Shared memory is an efficient means of passing data between programs. this method may carry race condition risk if a temporary file is used[citation needed] Shared memory In computing. Windows. MSMQ. CORBA. Java RMI. Messages placed onto the queue are stored until the recipient retrieves them. meaning that the sender and receiver of the message do not need to interact with the message queue at the same time. Depending on context. Windows Message passing (shared nothing) Used in MPI paradigm. others Memorymapped file All POSIX systems. Message queue Message queues provide an asynchronous communications protocol. is generally not referred to as shared memory.Shared memory All POSIX systems. programs may run on a single processor or on multiple separate processors. MailSlots. Message queues have implicit or . for example among its multiple threads.

.explicit limits on the size of data that may be transmitted in a single message and the number of messages that may remain outstanding on the queue.[4] These message queueing systems typically provide enhanced resilience functionality to ensure that messages do not get "lost" in the event of a system failure. Such queues exist for the purposes of that system only.[1][2] [3] Other implementations allow the passing of messages between different computer systems. Many implementations of message queues function internally: within an operating system or within an application. potentially connecting multiple applications and multiple operating systems.

Sign up to vote on this title
UsefulNot useful