[Home]Client Server

HomePage | RecentChanges | Preferences | My Website home page

Client Server

My Wet String Theory shows a process B needing to talk to process A and Process C also to Mananagement and hardware.

I said you need a polling loop.

 While ( 1 ) 
  poll for events
  service any events
 end

Using a polling loop for the wet string model.

 While ( 1 ) 
  poll processA
  poll processB
  poll processManagement
  poll processHardware
  service any events
  sleepAwakingOnInterrupt

 end

I said you need a polling loop.

 While ( 1 ) 
  poll for events
  service any events
  if no events sleep until interrupt
 end

Model for Server for short term connections.

 While ( 1 ) 
  block awaiting a connection
  handle connection
 end

When using TCP/IP it seems that the client server model could be used.

 While (1)
  Client1( polls for events )
  Client2( polls for events )
  Client3( polls for events )
 end

We need a server that accepts connections and responds.

Client Server

A client server model is required when there are very many clients interfacing to a few servers.

I have a term - Too Many To One relationship. The are too many clients to list them all.

Servers can only respond to Clients.

SIP softphone clients need a server to accept incoming calls. otherwise the client would need to poll the server periodically to say have you anything for me.

Servers probalby need client functionality to connect to other servers.

Shared memory may be required.

Client Server

A program may have have clients and servers using multiple threads.

A client requests information

A server responds

A server cannot initiate a request



  [Client]--+-------+--[server]
           many    one


Clients must be given a time slice to poll the server

The Server needs a database to store data.



  [Client]--+-------+--[server]<=>[Client]--+-------+--[server]<=>[Client]--+-------+--[server]<=>[Client]--+-------+--[server]



Pier To Pier

Pier To Pier is suitable for managing hardware.

A blob of software is attached to the hardware.

It is run periodically or run when the hardware generates an interrupt.

This is what wet string is about.

Each process is given a time slice.

  Process A
    if( anyEventsWaiting ) {
      pollEvent()
      ProcessEvent()
    }

  while( 1 ){
    ProcessA()
    ProcessB()
    ProcessC()
    ProcessD()
  }

Poll, Interrupt, Push, Pull

A CPU fetches instructions and executes them. It may check for interrupts.

Client Server and Peer to Peer

I was thinking that a Telephone is Peer to Peer while registered and in a contract for service. It can be contacted or contact another phone.

However if it is not registered, it is Client Server until It registers, as it cannot be contacted!

At the start a Telephone is a Client Server Model.

You order a new phone and get allocated a Phone number - Client Server model.

You socialize your number and people in the know can call you - Peer to Peer model

I do not know exactly where your phone is, but I know your number. Your phone has to register.

Client Server before phone registers.

A Registered Phone is Peer to Peer. I can ring you and the exchange knows where you are while you are registered.

I deregister and revert back to Server Client. The Exchange cannot contact my Phone, until I register again.


HomePage | RecentChanges | Preferences | My Website home page
This page is read-only | View other revisions
Last edited November 15, 2021 7:49 am by dougrice.plus.com
Search: