home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Network Support Encyclopedia 96-1
/
novell-nsepro-1996-1-cd2.iso
/
download
/
netware
/
dax1.exe
/
DOC
/
OUTLINE.DOC
< prev
Wrap
Text File
|
1992-02-23
|
10KB
|
275 lines
Distributed Application Design
Last Update: 02/23/92
Agenda
Distributed processing architectures
The various levels of distributed processing architectures
from one extreme to the other
Distributed application design
Discussion of components of distribution applications
Prototyping with RPC
Overview of determining what part of your application to distribute.
Distributed Application Example
NetCalc - Client Server network calculator
NetDebug
Dynamically patch the application NLM.
Ultimately read .MAP files and be intelligent about symbols
Initial
Dump memory
Modify memory
v2 - Execute console command
v2 - Set breakpoints on conditions? thresholds
Distributed Processing Architectures
Disk Service
The most distributed approach.
WS does all processing including dir and file struct mgmt
Physical disk is only centralized component.
File Service
Next most distributed approach.
Server machine does dir and file struct mgmt.
WS interprets and manages data within files
Record Mgmt Service
Small record retrieval appl runs in file server
WS perform all processing that relates to interpreting appl and data
Database/Schema Service approach
Higher levels of database functionality on the server
NetWare SQL is an example of this approach.
Application that uses these higher level db functions run on WS
Centralized Application with Distributed Presentation
Next most centralized approach.
Server performs everything except presentation of data
WS is intelligent screen and data entry point
Centralized Application and Presentation
The most centralized approach.
WS runs in "terminal emulation" mode
Server does everything except physical IO to screen and keyboard
The models we'll be discussing
File Service
Record Management Service
Database/Schema Service
Determining Performance Guidelines
Centralized vs. Distributed
Distributed has additional overhead of
maintaining communication protocol
request/reply packets
moving packets over wire
synchronization
Distributed can provide parallel processing
Creating multiple reports simultaneously
Determining what to distribute
?
More work can be done by multiple machines
File service model centralizes only file mgmt & rec sync
Central component usually is bottleneck, so dist as much as
possible increases aggregate processing capability
External synchronization
Distributed apps require multiuser synchronization
Server apps can do this internally with less overhead
Application Software Efficiency
Applications can be efficient or inefficient in searching for data
IO Efficient apps generally work better being fully distributed
Add additional server
Fully distributed appls are more divisible than server-based ones
IOW, files can be distributed among several file servers if
server becomes a bottleneck.
Optimizing server application
Server app can be optimized in ways dist apps cannot.
Server is only processor modifying data.
Can use internal caching algorithms
Can maintain hashing tables in RAM to speed up searching
PT. both dist and central can use hash tables in files (index)
Less communication with server application
Server apps utilize comm channel significantly less that dist appl
Server apps communicate only high-level db requests and replies
OTOH, dist apps have to transfer more records AWA do rec sync.
Faster data access with server application
Server appl is closer to the data (within same box), thus can
retrieve data with less overhead than remote WS.
Host environment & server application
Appl SW that resides in the server interacts with its host OS
OS efficiency in servicing disk IO requests affect server appl effic.
Other host related OS factors
Processor time that is available to server appl
Efficiency with which OS provides other svcs such as communication
The more it does, means fewer cycles for server appl
THESE AFFECT both file server and server-based implementations include:
Communication Bandwidth
Speed w/which client WS can receive requests and responses affects perf.
Communication speed factors include service protocols and LAN HW speeds
The more distributed, the greater the demand on the comm channel
Communication Protocol efficiency
Different protocols can vary widely in terms of efficiency
Plus processor time required to maintain the protocol.
Compute vs. IO Ratio
In general, Appl functions that are compute intensive should be dist
Server should perform functions that are IO intensive
PT. Compare the processor cycles required to do the request vs.
the processor cycles required to send that data to the
workstation to perform the request
Impact on security
Server based apps generally more secure since security is
administered away from the workstations.
If only file level security is needed, however, file server can
provide that, so both methods are just as secure as one another.
Functionality factors
File, record mgmt and db/schema implementations look and feel the same.
Fully dist app might need too much WS memory, whereas the server-based
appl can reduce the RAM requirements on the WS.
We've just looked at issues dealing with 3 different distributed appl
designs. Now lets look at the components involved in creating a
distributed application.
Designing a distributed application
Components
Client application
Server application
Client/server protocol
The agreed upon message exchange format between the client/server
Communication protocols
IPX/SPX, TLI, NetBIOS
Communication media
Client/Server Protocol
Online protocol
Service connection approach
WS requests connection, then makes requests, then terminates
Open service approach
WS just sends request to a server for processing w/o
previously requesting permission for service
Batch protocol
Queue Management Service
Client/Server Protocol 2
Layout of components for online protocol approach
Client makes DAP request.
Client DAP passes message to CP layer for network transmission
Client CP layer passes to CM
Server CM layer receives and routes to CP
Server CP Layer passes to DAP Layer
Server DAP Layer passes to server application
Client/Server Protocol 3
Layout of components for batch protocol approach
Client using NetWare QMS APIs creates a queue job
Either a server-based server appl or remote job server appl
services the request at some point in the future.
Service Advertising and Locating
Distributed application needs a way to locate the components
i.e. how does client appl find server appl?
SAP API can be used
Bindery can be used (QMS does this)
Now, to actually writing a distributed application
Prototyping with RPC
Overview of caller/called procedure
Prototyping with RPC 2
Discuss the way RPC works
>> Fill this in... spec file, blah blah blah
Distributed Application Example
Network Calculator Utility
Uses service connection approach
Built on IPX
Fully modular
DOS Library of CP Layer and DAP Layer
DAP Layer client/server single source
Server split in to separate NLMs, CP NLM and DAP NLM
NLM Engine
DOS Client
Distributed Application Example 2
NLM Server
Server application built right in to DAP Layer
Communication Protocol Layer is a separate NLM
>> Should be a library NLM
DOS Client
Communication protocol and DAP APIs in separate library
Client provides presentation and data entry
Distributed Application Example 3
Server application does the session management (DAP Layer)
Receives new reqeusts from clients (CP Layer)
Application engine resides in server
Distributed Application Example 4
Client/Server Protocol
Allocate Session
DeAllocate Session
Add, Subtract, Multiple and DivideOperands
Store Value
Recall Value
Reset Calculator
Distributed Application Example 5
Request format
Sequence Number
Connection Number
Request Code
Request Data
Reply format
Sequence Number
Return Code
Return Data
Distributed Application Example 6
DAP Engine
CP Layer calls enqueue request
Enqueue request places new request in DAP recv queue
DAP Recv Service thread determines DAP type and executes service API.
Service API calls enqueue reply
Enqueue reply places reply in DAP send queue
DAP Send Service thread calls CP API to send reply
Distributed Application Example 7
Communication Protocol Engine
IPX queues message to Comm recv thread
Comm receive thread calls enqueue request
Send service thread calls Send reply API
Send reply API gives message to IPX for delivery
Distributed Application Example 8
Overall flow
Client calls DAP API
DAP API calls CP API to send request
CP API calls IPX to deliver message
IPX delivers message to recv queue
CP passes request to DAP
DAP calls service request
Service Request does work then calls DAP send
DAP send calls CP API to send reply
CP API calls IPX to deliver reply
Related Topics
Summary
Architectures
Design
Prototyping