Experimenting Mobility Policies in a Java Environment - PowerPoint PPT Presentation

1 / 37
About This Presentation
Title:

Experimenting Mobility Policies in a Java Environment

Description:

Code on Demand (COD) Mobile Agent (MA) Design Paradigms. B. Resource. Know-how. A. Know-how ... COD (Code on Demand) REV (Remote Evaluation) MA (Mobile Agent) ... – PowerPoint PPT presentation

Number of Views:26
Avg rating:3.0/5.0
Slides: 38
Provided by: crs4
Category:

less

Transcript and Presenter's Notes

Title: Experimenting Mobility Policies in a Java Environment


1
Experimenting Mobility Policies in a Java
Environment
  • Giuliano Armano
  • DIEE Dipartimento di Ingegneria Elettrica ed
    Elettronica
  • Università di Cagliari

2
Outline of the Talk
  • Conceptual framework for classifying mobility
    mechanisms (and design paradigms)
  • Distribution, Concurrency, Mobility in Java
  • Introducing MODE (Mobile Objects in a Distributed
    Environment)
  • Setting up experimental results
  • Experimental results
  • Conclusions and Future Work

3
Conceptual Framework
  • Mobility mechanisms
  • Design paradigms

4
Mobility Mechanisms
  • Code and execution state management
  • Data space management

5
Mobility Mechanisms
  • Code and execution state management
  • Strong mobility
  • Migration
  • Remote cloning
  • Weak mobility
  • Code shipping
  • Code fetching

6
Mobility Mechanisms
  • Data space management
  • Binding removal
  • Network reference
  • Re-binding
  • By copy
  • By move

7
Design Paradigms
  • Client Server (CS)
  • Remote Evaluation (REV)
  • Code on Demand (COD)
  • Mobile Agent (MA)

8
Design Paradigms
9
Technological Framework
  • Agent TCL
  • Ara
  • Mole
  • Obliq
  • Sumatra
  • Java
  • Java Aglets
  • INFOBUS
  • JINI

10
Why Java?
  • Portable
  • Clean
  • Easy to learn
  • General purpose
  • Platform independent
  • Web oriented

11
Java Features along
  • Distribution
  • Concurrency
  • Mobility

12
Distribution in Java
  • Client-server model
  • Location awareness
  • Remote Method Invocation (RMI)

13
Concurrency in Java
  • Monitor-like model (passive objects)
  • Light-weight processes (threads)
  • wait / notify / notifyAll

14
Mobility in Java
  • Code mobility ()
  • Serialization mechanism
  • Data mobility as a side effect of RMI
  • () network-based class loading

15
Distribution in Java
  • Pros
  • Simple
  • Standard
  • Benefits from platform independence
  • Unique references through RMI Registry
  • Cons
  • Handling parameters in a method call
  • No integration with concurrency handling
  • Class versioning

16
Concurrency in Java
  • Pros
  • Simple
  • Standard
  • Cons
  • Semantics not completely specified in the JVM
    Specs
  • Only monitor-like support (for passive objects)

17
Mobility in Java
  • Pros
  • Embedded into the JVM (class loading)
  • WEB oriented
  • Cons
  • Obtainable only as a side-effect of method
    invocation
  • The transitive closure of a slot reference may be
    very big

18
Experimenting Mobility Policies
  • In a Java-like Environment

19
Goals
  • Investigating some mechanisms to move / copy code
    and data separately
  • Simplifying the syntax for representing
    context-aware computations
  • Eventually, defining a framework able to support
    collaborative work

20
Conceptual Framework
  • Mobility mechanisms
  • Code and execution state management
  • Weak mobility
  • Code fetching gtCM
  • Data space management
  • By move gtDMM / DMV
  • CM weak Code Mobility (only code fetching)
  • DMM Data Mobility by Move / DMV Data Mobility
    by Visit

21
Conceptual Framework
  • Supporting all design paradigms
  • CS (Client Server)
  • COD (Code on Demand)
  • REV (Remote Evaluation)
  • MA (Mobile Agent)
  • Design Paradigms (focused on object creation and
    method invocation)

22
Technological Framework
Mobile Objects in a Distributed Environment
23
JMODE
  • Is an extension of Java that allows the
    programmer to handle code and data mobility
    (without going into unnecessary details)
  • Adds 4 keywords to Java
  • on
  • mobility
  • move
  • movable

24
JMODE Syntax An Example
  • package weatherstation
  • import Barometer mobility DMV
  • import RainGauge
  • public class WheatherStation implements
    IWheatherStation
  • private movable Barometer barometer
  • private RainGauge rainGauge
  • public WheatherStation()
  • barometer new Barometer() on crs4 //
    default CM
  • rainGauge new RainGauge() on unica mobility
    DMM
  • barometer.getRain(rainGauge) move rainGauge

25
MODEP Jmode Preprocessor

distribution
file
Mode source
(
extended syntax)
MODEP
.jmode
.java
MODEPATH
Java source
(
pure
java syntax)
configuration files
26
MODES
  • Is the support layer that enforces distribution
    and mobility in a Java environment
  • Services
  • local or remote object creation
  • local or remote method invocation (object meeting)

27
MODED
  • Is a daemon that allows to execute MODE on all
    nodes involved in a given project.

MODE
MODE
MODE
MODE
28
MODEGUI
  • Editor
  • Support for collaborative work
  • Run-time supervisor

29
Experiments Setting
  • Object Creation
  • O1 and C1 are located in the same node
  • O1 and C1 are located in different nodes
  • Method Invocation
  • O1 and C1 are located in the same node
  • O1 and C1 are located in different nodes
  • O1 an object C1 the corresponding
    class

30
Experiments Setting
  • Code Mobility
  • actually code cloning, as currently there is
    no support for class deletion from a JVM
  • Exploiting the capabilities of (network) class
    loaders
  • Data Mobility
  • no data cloning severe synchronization
    problems may arise
  • Exploiting the common technique of data
    marshalling

31
Experimental Results
  • Object Creation
  • O1 and C1 are located in the same node

32
Experimental Results
  • Object Creation
  • O1 and C1 are located in different nodes

33
Experimental Results
  • Object Creation
  • O1 and C1 are located in different nodes

34
Experimental Results
  • Method Invocation
  • O1 and the C1 are located in the same node

35
Experimental Results
  • Method Invocation
  • O1 and C1 are located in different nodes

36
Conclusions
  • Location awareness is possibly error-prone in
    pure Java
  • Need for a suitable support for dealing with
    location-awareness (i.e., JmodeMODEPMODES)
  • Naive code and data mobility are easy to perform
    in Java, exploiting class loading and enforcing
    data marshalling
  • As expected, code mobility is usually more
    efficient (as typical JVM implementations keep
    information about classes that have been loaded
    so far)

37
Future Work
  • Implementing monitor-based synchronization for
    passive objects in a distributed environment
  • Implementing active objects and rendez-vous
    (CSP-style synchronization) in a distributed
    environment
Write a Comment
User Comments (0)
About PowerShow.com