Inter-Process Communication Flashcards
What are the characteristics of IPC?
- Message Passing
- Possible synchronisation of two processes
- Synchronous and Asynchronous communication
- Queue associated with each message destination
- Reliability
- Ordering
- Unicast/Multicast Communication
What is meant by message passing?
Passing message between two processes via send and receive
What is synchronous communication?
Sender and receiver synchronise (send and receive are blocking operations)
What is asynchronous communication?
Send is non-blocking, sender is allowed to continue
What does the sender and receiver processes do with regards to queues?
Sending process adds message to remote queue
Receiver process removes message from the remote queue
What is the destination of messages?
Sent to Internet Address, Local Port
What is meant by reliability?
The guaranteed delivery despite a ‘reasonable’ number of packets being dropped or lost
What is meant by integrity?
Messages arriving uncorrupted and without duplication
What is meant by ordering?
Some applications require sender order
What is unicast communication?
Communication from one process to a single other process e.g. socket communication
What is multicast communication?
Communication from one process to a group of processes e.g. publish/subscribe message model
What is IP?
Internet Protocol
What is the purpose of IP?
To deliver data packets to network devices
What type of address is used by IP to deliver data packets?
Logical IP addresses consisting of a network part and a host part
It is routable - can forward packets to another network
What is an internet?
2 or more connected TCP/IP networks that can be reached by routing
What is TCP?
Transmission Control Protocol
Is TCP connection- or connectionless- orientated?
Connection-orientated protocol
Ensures packet delivery is possibly by establishing connection first with receiving device
Does TCP resend packets if they don’t arrive?
Yes
When is the connection closed by TCP?
When packets have been successfully delivered
Unrecoverable error has occured
Is TCP unicast/multicast?
Unicast
Used for one-to-one connectioons
Which applications rely on TCP?
Web browser
FTP
SMTP - Simple Mail Transfer Protocol
What is UDP?
User Datagram Protocol
Is UDP connection- or connectionless-orientated?
Connectionless-orientated protocol
Used when the overhead of a connection isn’t required
Doesn’t guarantee delivery - places packet on the network via IP and forgets about it
How may a programmer deal with confirming delivery using UDP?
Applications can use expected replies
If no reply without a certain time, application either resends the packet or deals with packet loss
What applications use UDP?
DNS, used to looks up domain names/IP addresses
Voice and video applications normally
What is a socket address?
Message destination are defined as socket addresses
Consist of port number and internet address
Data is transmitted between sockets