GoConqr has a new look! Let us know what you think.

Mind map

Semaphores/Sockets

Tom David English

Semaphores/Sockets

Map content

Semaphores/Sockets

  1. Concurrency = Processes executed simultaneously ie. several apps running on one machine

  2. Issue? - Uncontrolled access to shared data ie. this may allow two people to book the same tickets at a concert

  3. To combat this? - Only one process allowed in the critical section at any one time

  4. Processes compete for the same, shared, resources - Without synchronisation unpredictable and incorrect executions can result

    • Synchronisation = Mutual exclusion of any process not in the critical section
      • Synchronisation is implimented by the use of Semaphores
        • Semaphores = An object with methods Called by processes sharing a resource
          • There are two types of semaphores Binary semaphore, either 0 or 1 that is essentially a flag to signal when using critical region OR Counting semaphore, > 1 Basic implementation every process issues a wait on entering critical section and Signal finished on exiting
            • See producer/consumer problem
  5. A socket is an endpoint for communication

  6. Two communicating processes over a network each use a socket to identify them

  7. Socket defined by port number and ip address

  8. How does this work? - Client-server architecture A server listens for client requests When a request is received the server uses the socket details to set up a connection.

  9. More... - Well-known services: telnet:23, ftp:21, http:80 --- All ports below 1024 are considered well-known --- The client will allocate the port number to the process initiating communication --- Random port greater than 1024.

Images and files in the map

  • Semaphores/Sockets
  • Semaphores/Sockets

Information

Description
Mind Map on Semaphores/Sockets, created by Tom David on 20/05/2015.
Created by
Tom David
Views
0
Rating

Feedback

What is it about?

What do you think of the new look?

How do you like it?