Client/Server Computing:
A
client/Server is one type of a network computing where in the one
powerful workstation servers the request needed by the other system.
Client
Server application development requires hybrid skills that include
database design,transaction processing,communication experience and
also Graphical User interface design.
The Client/Server computing has changed the way in which the computers
are being used today and is a vast area in the computer industry.
The
Client/Server computing is an environment that satisfies that
business need by appropriately allocating the application processing
between the server and the client.
Sometimes
Client/Server processing is also called as peer to peer processing.
The
client/Sever model is also machine independent,It does not depend on
a particular type of machine,it can be implemented on any workstation
or a system.
Client/Server
computing can be a cross platform if it is written in cross platform
language,or it can also be a platform specific.
Computer
Server:
A
computer network server is a powerful computer or the set of
computers that are connected to each other providing
computing,connectivity and the database services and the interfaces
relevant to business needs..They have a database integrated within
them and have advanced configuration,These are used to process the
requests of the Client,and they also play a role in network
management for easy and uniform transmission of data & media
across the network.
The
main function of the server is to respond to the requests of the
client.Apart from this they have several other functionalities,Some
of them are:
1)
The processor speed of Server's are very high,So they can be used for
multitasking,
2)
They are used to provide information or handle many client requests
simultaneously,So they posses a large Random Access Memory
3)They
provide the results to various other network systems and hence they
have large storage capacity.
Computer
Client:
A computer client is a computer or a workstation at the end user's
place that request service from the servers.It interacts with the
user through the user interface and performs application
functions.The client also interacts with the client middle ware using
middle ware API.It receives the response from the server and displays
it to the user if needed.
The main functionalities of the client are:
1)It provides presentation services and the appropriate computing and
connectivity.
2)They are also used for database services ans the interfaces relevant to business need.
Figure shows the overview of Client/Server architecture.
Characterstics
of the Client and the Server:
The
client and server are the logical entities that work together over
the network to accomplish a particular task.
Some of the characteristics of the Client/Server systems are:
1) Client server computing uses local processing power,the power of
desktop platform.This changes the normal way of distributing and
accessing the data.With this approach data is no longer under the
control of others it is readily available to middle rank personnel and
staff.
2) Client/Server computing is open systems ,means the user will be
able to configure the systems,both software and hardware according to
a particular standard.In this way the company can use their system for
a particular situation and can alter it the most effective way.
3) All of the hardware and software components are actually modular
in nature.This modularity allows the system to expand and modernize
to meet the working requirements.
4) This type of computational model reduces the price of hardware and
software needed for computing and also use these resources in an
efficient way.
5) The Client/Server architecture is typically heterogeneous and are
made of hardware and software from multi vendors,The biggest
challenge is to put together all these complex system of hardware and
software from multi vendors and successfully implement it.
6) A server can service many clients at the same time and regulate
their access to the shared resources.
7) Client/Server systems can be scaled horizontally or
vertically.Horizontal scaling refers to the adding or removal of the
client workstation with only a slight change in performance.Vertical
scaling means migrating to a larger or faster server machine and
distributing the processing load across multiple servers.
Merits
of Client/Server computation:
1) Faster
Data sharing:
Client/Server architecture are used for faster and enhanced data
sharing among different systems.The Structure Query Language is used
to define ans manipulate the data and provides open access from all
client processes and software.
2) Sharing
resources among various platforms:As
the client/Server model is machine independent and also works on
cross platforms,The data sharing among the client and server becomes
easy.
3) Integrated
Services:
In the Client/Server model,all the information of the client is available with at the desktop .There is no need to change into
terminal mode or log into another processor to access information.
Demerits
of Client/Server Computation:
1) Traffic congestion:As the number of client requests increase
the server has to process all the information's of the client and
hence the server may get overloaded to increased number of requests.
2) Server
Failure:Server is considered as the backbone in the Client/Server
architecture and any fault within the server would seize the whole
computational model and the requests by the clients cannot be
fulfilled.Thus Client.Server Lacks Robustness.
3) Due
to the increase in number of request from the client the process of
data retrieval within the server may degrade,which results in the
delayed service of the client's request.
Here we would consider one disadvantage of the Client/Server
computation,which is the process of Data retrieval within the server
and introduce the measures for the Speeding up of Data retrieval.
METHODS:
The speed of data retrieval can be done by managing the number of
rows fetched during progressive fetching,controlling the size of the
data being fetched and by using delay memo fetching
UseMemoSize viewing property can also be used to return character
fields as memo fields and then by switching off the FetchMemo off to
enable the application to fetch only the selective data,which
increases the speed of data retrieval.
Progressive
Fetching:
When ever a data is fetched from a remote source usually the entire
row of data is fetched from the server and is returned to the
client,To overcome this progressive fetching technique is used which
employs the data fetching using view cursors and cursors created
asynchronously with SQL pass-through.When ever data is fetched using
this technique only a small subset of the result set of rows is
fetched,the size of this subset is 100 rows by default.
By this technique the local cursor contains increasingly more of the
queried data.Since rows are retrieved at different times from the data
source,the information in the row isnt automatically current.If the
connection in the server operating system is asynchronous
mode,progressive fetching technique returns control to the program as
soon as it fetches the first subset of data.During the idle time it
performs a background fetch of the remaining rows in queried data,one
subset at a time,into the local cursor.This scenario allows you to
use the already fetched data in the cursor without having to wait for
the rest of the data.
Progressive fetching in Windows system can be implemented using the
Visual Fox Pro where in only a selected data can be retrived from the
data stored in the server which can be used to service the client
requests.
Fetchind
Data on Demand:
The progressive fetching can be disabled to fetch data in subsets
and instead of it only the row needed can be fetched on an as-needed
basis by the FetchAsNeeded database and view cursor property at the
server side.This results in more efficient data retrival for remote
views or views related to extremely large result sets.
The FetchAsNeeded property is disabled by default in most of the
systems,which means the progressive fetching technique is
enabled.When the server is set to FetchAsNeeded rows are fetched only
when they are needed. Whenver the FetchAsNeeded property is set to
true,you cannot perform an update until the user either complete the
fetch,calling the SQLCANCEL() function on the current handle and then
closing the view.
A real time view of the FetchAsNeeded can be visualized,when the
user opens a brower and scrolls down,The status bar will be updated
with the number of rows retrived as you move through the browse
window.
Control
Cursor Fetching:
If the entire cursor wants to be fetched then the server can issue
GOTO BOTTOM command,or any command requiring access to the entire
set.
The server on itself does not provide idle loop processing.To fetch
view cursor programatically,we can use the GonRecordNumber or GOTO
BOTTOM commands.To fetch cursors created with SQL-pass through in
asynchronous mode,call the SQL pass-through asynchronous function
once for each row subset.
Controlling
Fetch Size:
The fetching of data at the server can be controlled to only a set
of rows based on the client request by setting the Fetch Size property
on the user view.The Fetch Size property specifies how many records
are fetched into the local cursor from the remote server at one time.
To control the number of records fetched at once time
1) Set the Fetch Size property with DBSETPROP() function to set the
view definitions fetch size
OR
2) Set the Fetch Size property with the CURSORSETPROP() function to
set the active view cursor's fetch size.
Delayed
Memo Fetching:
The delay Memo Fetching is used to speed up the data retrieval Delayed Memo fetching the Delay and the Memo fields are not fetched
automatically at the client's request instead only the row
corresponding to the requested data will be fetched and the Memo and
General fields are fetched only when the users specifies them,this
helps in faster data retrieval.
As a real time example suppose that the form that is requested by
the client has some data along with an image and only the data has to
be fetched from the form,by using the Delayed Memo Fetching only the
data could be fetched and the image can be viewed/downloaded only
when the user presses the preview button to avoid unwanted data
retrieval.
To control the delay memo fetch the server can be used with
Fetch Memo property on the view or cursor,the Fetch Memo property is
used to specifies whether the memo has to be downloaded along with
the data.By default the Fetch Memo is enabled so that the memo's are
downloaded and user can disable it based on the data to be retrieved.
Optimizing
the Fetching Performance:
Finally after seeing some of the methods in improving the data
retrieval the Client/Server Computation model,the data fetching speed
cannot be increased to a greater extent.Some of the methods to
optimize the fetching performance are:
1) The packet size to be fetched has to be larger (4k to 12k),The
higher the value of this containing more data and rows,the rows will
be fetched faster.
2) Use of the synchronous connections will speed up the fetching
process by 50%.
3) In the view,the Fetch Size has to be maximum,if the Fetch Size is
reduced it provides better responsiveness while progressive fetching
but slows down the fetch speed.If increased ,it increases the view
fetch performance.
Conclusion:
With the use of the Client/Server technique in contrast of the
normal P2P model,it provides better computational facility and also a
single server would be able to handle various client requests,By
using any one of the above mentioned data retrieval procedures the
request's from the Clients can be easily handled by the Server and
also the speed of retrieval can be increased. This is on the improvement
methods in the Client/Server model which leads to efficient
computing.
References:
1)Speeding up data retrival,Developer Network,Miscrosoft MSDN.