Upload
shanon-cameron
View
222
Download
0
Embed Size (px)
Citation preview
Middleware for Nomadic Computing
Stefano Campadello
Presentation Outline
• Nomadic Computing issues• Communication Issues• Mobility Issues• Device Issues• Security Issues
• Middleware for Distributed Computing• WAP• Java RMI• Corba
Presentation Outline
• Enhancing the Middleware• Dolmen• Nomadic RMI• Wireless CORBA
• Conclusions
Nomadic Computing
What’s it?
Nomadic Computing
”The essence of a nomadic environment is to automatically adjust all aspects of user’s computing, communications, and storage functionality in a transparent and integrated fashion” – L. Kleinrock, 1997
Anytime, Anywhere
• A user wants to:• use her laptop during a flight and upload her
work once disembarked• follow financial information independently from
the location and time• instantiate a communication during a disaster
recovery mission• access the Internet or Intranet services while on
the move.
The Challenges in Mobile Computing
Communication Issues
• Low Bandwidth• sending long files requires long time: the chance of
experiencing network failures is high• a graphical user interface can act in a bizarre way
• High bandwidth variability• Bandwidth can increase/decrease four orders of
magnitude depending on local conditions (connected/wireless). Ex: videoconference
• Disconnection• File system can lock up for a remote server to allow
access• After reconnections conflicts are possible
Mobility Issues
• Address Migration• Physical location != network address• To communicate with a mobile computer is
necessary to know its most recent address
• Location-dependent information• Some information depend on location, as local
printers or local currency. • In a mobile environment these information
cannot be stored statically and they must be found dynamically
Devices Issues
• Power limitation• Energy supply is a bottleneck for mobile devices• Bigger batteries => more weight• The user wants long-lasting AND light devices
• User Interface and Display Issues• Size constrains force to use small user interface• Small display size makes access to remote service
difficult• Input devices must be redesign (keyboard -> pen-
based recognition)• Hand-writing and sound recognition
Security Issues
• Identification• Certification• Privacy• Insecure channels• Insecure devices (can be stolen)• ...
Middleware for Distributed Computing
Middleware for Distributed Computing
• Remote Procedure Call (RPC)• 1976. Provides communication across a network
between programs written in a high-level language• Using procedure calls mechanism is easier than
building a communication paradigm• It presumes the existence of TCP/IP or UDP• Its use is in decline: not implemented in object oriented
programming languages• Java RMI
• 1998. Same concept implemented in Java. • More later...
Machine A
Machine B
Clientprogram
Servicedaemon
Serviceexecutes
RPC Call
Invokeservice
Call service
RPC returns
requestedcompleted
return reply
Program continues
Remote Procedure Call (RPC)
Middleware for Distributed Computing
• Wireless Application Protocol• Designed for Nomadic devices• It provides Internet access for phones and small PDAs
WAP - Architecture
WAP – Architecture
WAP – Architecture 2.0
Middleware for Distributed Computing
• OMG CORBA• 1989. Provides interoperability between objects in a
heterogeneous, distributed environment• Interfaces specified in OMG IDL• Not suited for wireless networks, since it requires
reliable communication• Not suited for mobile device, since the terminal
cannot change its point-of-presence• Microsoft COM and DCOM
• COM allows binary interoperability between distributed objetcs
• NOT platform independent and proprietary protocols
InterfaceRepository
IDLCompiler
ImplementationRepository
ClientOBJ
REF
Object(Servant)
in argsoperation()
out args +return
DIIIDL
STUBS
ORB
INTERFACE
IDL
SKELDSI
Object Adapter
ORB CORE GIOP/IIOP
OMG CORBA – Architecture
Enhancing the Nomadic Layers
APPLICATIONSAPPLICATIONS
MIDDLEWARE(IIOP/RMI/ACTIVE-X)
MIDDLEWARE(IIOP/RMI/ACTIVE-X)
RADIO LINKRADIO LINK
TRANSPORT LAYER(TCP/IP)
TRANSPORT LAYER(TCP/IP)
Nomadic Computing - Layered
Improving Long Thin Networks
• Slow Start and Congesting Avoidance• the system assumes the network is congested while
packets are dropped for corruption
• Delayed ACKs• the dimension of the sender’s window depends on the
number of ACKs it receives. Adaptation is slow
• Three-way Handshake• data transfer is possible only after the handshake is
completed. Long latency makes short transactions unattractive
• Lenght of TCP/IP headers
Improving TCP over Wireless
• Solutions:• modify or eliminate slow start• Use larger initial windows• Count the data acknowlegde not the number of ACK• Change the spacingbetween ACKs• Compress headers or compress IP payload• SNOOP (Berkeley)
• Split connection approach, but maintaining end-to-end semantic
• retransmission of lost packets only locally• suppression of duplicate ACKs from receiver to
sender
Improving Client-Server Paradigm
• Satyanarayanan [1996]:• Extremes of adaptation: laissez-fair and application-
transparent Improving Client-Server Paradigm
Application-aware(collaboration)
Laissez-faire(no system support)
Application-transparent(no changes to applications)
Applications
File System Proxy
Mobile Host
MobileFile Server
Fixed Network
Mobile File System APIs
File System APIs
Enhancing the Communication Layer
• Example: Coda File System
Mowgli Project
Monads
• Adaptation agents for Nomadic Application.• The key work is ”prediction” through
learning
Addressing the Mobility Issues
• Mobile IP
Enhancing The Middleware Layer
Nomadic RMI
Remote Method Invocation
• RMI protocol interface lets Java objects on different hosts communicate with each other in a transparent way
• Clients can invoke methods of a remote object as if they were local methods
• Preserve the object oriented paradigm in distributed computing
Server Program
Skeleton (JDK 1.1)
Remote Reference Layer
Client Program
Stub
Transport Layer The Internet
Remote Reference Layer
Transport Layer
Logical Path
Java RMI - Layers
Client ObjectClient Object
StubStub
RegistryRegistry
ServerServer
Remote ObjectRemote Object
SkeletonSkeleton
13
8 56
74
Client Virtual Machine Server Virtual Machine
2
Java RMI - Protocol
Java RMI in a Nutshell
Client Server
RegistryRegistryRegistry
ServerServerServer
Server-stubStub-serverStub-server
DGC messages
ClientClientClient
Send the me stub
StubStub
Here is the stub
Hello is here
invokeMethod()
“ReturnValue”
Lookup(): where is Hello?
Java RMI in a Nutshell
Client Server
RegistryRegistryRegistry
ServerServerServer
Server-stubStub-serverStub-server
DGC messages
ClientClientClient
Send the me stub
StubStub
Here is the stub
Hello is here
invokeMethod()
“ReturnValue”
Lookup(): where is Hello?
“Hello World” Example
TCP 1
Header
Protocol Ack, EPId
EPId, Lookup()
ServerRef
Header
Protocol Ack, EPIdEPId, dirty()
LeasePing
Ping Ack
DGCAck
Ping
Ping Ack
sayHello()
“Hello World”
clean()
clean result
...
TCP 2
ParallelParallel
Client Registry Server
Data traffic analysis
Client to Server andRegistry(bytes)
Server andRegistry to
Client(bytes)
Total(bytes)
Registry Lookup 55 (6%) 276 (42%) 331 (20%)Invocation Data 41 (4%) 37 (6%) 78 (5%)
DGC Data 831 (85%) 305 (46%) 1136 (69%)ProtocolOverhead
52 (5%) 40 (6%) 92 (6%)
Total 979 (100%) 658 (100%) 1637 (100%)
RMI Optimization
• Maintain compatibility with Java RMI specifications
• Avoid redundancy in communication protocol
• Use compression and caching to minimize data transmission
Java RMI Optimization
• Protocol• Use of Mediators to minimize the exchange of
data through the wireless link.
• Data Communication• Optimized Communication: Compress and
Optimize data communication
• Class Loading• If possible, avoid to download stubs
Protocol Optimization
• The idea is to de-couple the connection between the client and the server using mediators.
Wireless Link
Mobile Node
RMIAgentRMIAgent
ClientClient
RMIProxyRMIProxy
NamingNaming
Access Node
Optimized RMIMobile Node
ClientClientClient
FakeStubsFakeStubFakeStub
ProxyProxyProxy
AgentAgentAgent
MonadsRegistry
MonadsRegistryMonadsRegistry
ClientClientClient
RegistryRegistryRegistry
ServerServerServer
RegistryRegistryRegistry
ServerServerServer
Access Node
Cac
he
Cac
he
Optimized RMIMobile Node
ClientClientClient
FakeStubsFakeStubFakeStub
ProxyProxyProxy
AgentAgentAgent
MonadsRegistry
MonadsRegistryMonadsRegistry
ClientClientClient
RegistryRegistryRegistry
ServerServerServer
RegistryRegistryRegistry
ServerServerServer
Access Node
Cac
he
Cac
he
Optimized Remote Invocation
RMI AgentRMI Agent RegistryRegistry ServerServer
Header
Protocol Ack
Lookup() lookup
ServerRef
dirty()
Lease
ClientClient RMI ProxyRMI Proxy
In cache?
Lookup()
InternalRef
AgentRef Cache and markfor sync First?
Header
Protocol AckHeader
Protocol Ackdirty()
Leasecount[ref]++
DGCAckHeader
Protocol Ack
DGCAck
sayHello () sayHello()sayHello ()
“Hello World”“Hello World”“Hello World”
clean()
clean resultclean resultclean result
...clean() clean()Last?
Comparison between RMI and RMI
RegistryInvocation
RemoteInvocation
Total
Java RMI 7.1 sec 1.3 sec 8.4 secOptimized
RMI1.7 sec 0.6 sec 2.3 sec
Improvement 417% 216% 365%
Test Arrangements
• Operating Systems• Clients:
• Windows98• Linux (Red Hat 6.1, kernel 2.2.14)
• Server• Windows NT (SP 6)• Linux (Red Hat 6.1, kernel 2.2.14)
Test Arrangements
• Java Virtual Machine• Sun JDK 1.2.2 (Linux and Windows)
• Wireless communication• GSM HSCSD (5 configurations)
• Benchmark Suite• KaRMI from University of Karlsruhe
Lookup Results (windows)
Lookup Differences
Invocation ResultsImage Uplink (Linux)
Invocation Results Two-way Text uplink
Nomadic RMI
• The previous solution does not support mobility
• If the connection between mobile host and RMI Agent is interrupted the system is in an unstable state
RMI (Nomadic RMI) Protocol addresses this problem
• It allows Handover between different access points
Nomadic RMI
Enhancing The Middleware Layer
Wireless CORBA
Issues of CORBA in Nomadic Environment
• IIOP servers are not expected to change their transport connection endpoint
• IIOP and the transport connections are supposed to be reliable
• It is not possible to change network interface during an IIOP connection
• Connections are expected to enjoy high bandwidth
Home domain
Visited domain
AccessBridge
AccessBridge
AccessBridge
AccessBridge
TerminalDomain
TerminalBridge
HomeLocation
Agent
GIOPtunnel
Wireless CORBA – Architecture
wCORBA Framework
• Mobile IOR• Identifies the terminal on which the target object
resides• And its Access Bridge
• Home Location Agent• Keeps track of the current location of the terminal
• Access Bridge• End-point of the GIOP tunnel in the network side
• Terminal Bridge• GIOP tunnel
wCORBA Framework
• Terminal Bridge• End-point of the GIOP tunnel on the terminal side
• GIOP tunnel• Is the means to transmit GIOP messages between
the Terminal Bridge and the Access Bridge
Terminal ORB Access Bridge ORB peer ORB
GIOP GIOP
GIOP messages
TCPTCPTCP byte stream
IIOPIIOPIIOP messages
GTP adaptation layer GTP adaptation layer
transport transport
GTP GTPGTP msgs
ObjectCORBA invocations
Object
Wireless CORBA - GIOP Tunneling Protocol
TB old AB new AB
start_handoff
HandoffTunnelRequesttransport_address_request
EstablishTunnelRequest
Establishment of transport connectivity
HLA
location_upadte
EstablishTunnelReply
HandoffTunnelReply handoff_completed
ReleaseTunnelRequest
ReleaseTunnelReplynotify other ABs
DepartingTerminalNotificationHandoffNotification
ArrivingTerminalNotification
report_handoff_status
Wireless CORBA – Handoff