SlideShare ist ein Scribd-Unternehmen logo
1 von 21
4th International Conference in Central Europe
    on .NET Technologies




             Transparent Mobility of
      Distributed Objects using .NET
              Cristóbal Costa, Nour Ali, Carlos Millan, Jose A. Carsí
Contents




             > Background & Motivation

             > Search Agents case study

             > OOAttachments approach

             > Conclusions




                                          2
30/05/200 .NET Technologies 2006
Background

> Previous work in Component-Based Aspect-Oriented
  Software Architectures
> A characteristic is that the components neglect
  distributed nor local references of their partners
> Transparent entities called Attachments are
  responsible of:
     Interconnecting components
     Providing transparent mobility and communication


                Node1                  Node2

                 Component1                 Component2


                              Attachments

                                                         3
30/05/200 .NET Technologies 2006
Motivation

> To transfer previous experience in attachments to
  connect objects, instead of aspect-oriented
  components


> To provide a library to support the development of
  transparent mobility of distributed objects


> These features must be provided:
     A non intrusive and transparent way of programming
     Code should not be precompiled nor preprocessed
     Efficiency




                                                           4
30/05/200 .NET Technologies 2006
Motivation

> For example, it can be used by Client & Server
  architectures to manage both location changes in a
  transparent way

> Why the client object has to worry
  about its server?




                                   Server
         Client




                                                       5
30/05/200 .NET Technologies 2006
State of the art

> This problem has been dealt in Mobile Agent Systems
  Most of them are built on Java:
     Aglets, Nomads, MobJeX, Voyager, JADE, ProActive, …
> There are few approaches on .NET
  but still in development
     MAPNET, Nomad, EtherYatri.NET
> Common characteristics of these approaches:
     Agents are defined by means of inheritance.
     In most of them, the agent has to define all its functionality in one
      method (usually “Run”) with a specific signature
     Events are captured by overriding inherited methods
     Communication among agents is realized: by using generic proxies
      (like “AgentProxy”), by passing messages, or by implementing
      specific services



                                                                              6
30/05/200 .NET Technologies 2006
Strong vs Weak Mobility

         Strong Mobility                          Weak Mobility

Agent processes are interrupted in        The programmer must take care
a transparent way                         of their processes


In order to implement strong mobility     It is the programmer who saves
the ability of thread serialization is    processes information before moving
required.                                 and restores it after moving.

Two main alternatives:                    As no customization is needed, the
  By extending the Framework              solution is more portable
  (e.g. JavaThreads [Bouchenak03])
  → New releases of the Framework
  would make it useless

  By preprocessing the source or binary
  code (e.g. Brakes [Truyen00])
  → Less eficiency


                                                                                7
30/05/200 .NET Technologies 2006
Contents




             > Background & Motivation

             > Search Agents case study

             > OOAttachments approach

             > Conclusions




                                          8
30/05/200 .NET Technologies 2006
SearchAgents case study

> There are a lot of resources over the Internet from
  which we want to collect distributed information
> The search grows as a tree, so we need to be able to
  explore the resources dynamically in a distributed way
                                  A
                                       B
                              E
                                       C
                                   D
> Our solution: to send only a few agents capable of
  establishing transparent mobile communications
    Network resources are not overloaded, as there only are a few
     agents travelling through the network
    Agents can exchange new subsearches without realizing where the
     others are
    They are completely autonomous: they only come back with the
     results, so the sender could have been disconnected during the
     process (e.g. mobile clients)

                                                                       9
30/05/200 .NET Technologies 2006
SearchAgent implementation
                                   >   The inheritance is not limited: we do not
                                       have to inherit from a specific class to
                                       benefit from mobility

                                   >   By this way, an object is made remotely
                                       accessible to others
                                   >   A specific interface can be specified to
                                       restrict offered services



                                   >   An object obtains a reference of a remote
                                       object by specifying its ID and current
                                       location
                                   >   The remote reference is a transparent
                                       proxy that provides all the remote
                                       methods




                                   >   By this way, an object moves itself to
                                       another host

                                   >   There are no need to use specific methods
                                       and signatures for being called when
                                       object mobility finishes
                                   >   Parameters can also be provided (e.g. for
                                       providing initialization information)


                                                                            10
30/05/200 .NET Technologies 2006
Contents




             > Background & Motivation

             > Search Agents case study

             > The OOAttachments approach

             > Conclusions




                                            11
30/05/200 .NET Technologies 2006
The OOAttachments approach

> Features:
     Objects can move autonomously among computers without
      having to take into account how distributed communications with
      other objects are performed
     Since a connection is established, location-awareness is provided
     No need for a centralized infrastructure to manage mobility and
      object registration services
     Dynamic code generation and reflection is combined in order to
      be able of calling code dynamically, so code precompilation is not
      needed

> Constraints:
     Weak mobility is provided, so objects must take care of their
      threads before moving
     In order to establish the first connection, a client object needs to
      know where the server object is located
     Each mobile object must be marked as Serializable
     The middleware must be running in each computer

                                                                             12
30/05/200 .NET Technologies 2006
The OOAttachments approach

   > Objects are connected through entities called
     Attachments
                                                                                     Host A                                                                         Host B
                                                                    [Serializable]                                                              [Serializabl e]




                                                                                          Attachment
                                                        «generated-code»                                                  AttachmentServ er
                                                         Serv er-AttClient
                                                                                                          objectName: string
                       IDeserializationCallback
                                                         1                                                «NonSerialized» objRef: object



    Search                                                                                                                                                        Search
                                                                  [Serializable]                          objType: T ype
                                                   AttachmentClient                                       attClientsURLs: string [0..*] (ArrayList)
                                     methodInformation: MethodInfo [1..*]                                 serverIsMovi ng: bool
                                     parentType: stri ng
                                     serverURL: string                                                    AttachmentServer(objRef, objectName, objType)




    Agent 1                                                                                                                                                       Agent 2
                                     serviceIsConsum ing: bool[]                                          BeginServerMobility() : void
                                                                                                          EndServerMobility(objectReference) : void
                                     Process(methodID, args) : object
                                     BeginClientMobility() : void
                                     EndClientMobili ty() : void                                                           [NonSerialized] 1
                                     StopProcessingServices() : void
                                                                                                                                        MarshalByRefObject
                                                                                                                        AttachmentServ erMediator
                                 [NonSerialized]
                           1
                                                                                                              methodsList: Delegate[]
                                           MarshalByRefObject
                               AttachmentClientMediator
                                                                                                              RegisterClient(attClientURL) : MethodInfo[1..*]
                      ServerM obilityBegan() : void                                                           UnRegisterClient(attClientURL) : void
                      ServerM obilityEnded(newURL) : void                                                     RedirectService(methodID, args) : object




Client behaviour:                                                                                                             Server behaviour:
It invokes “NotifyNewLocation”                                                          Object layer   It offers the “NotifyNewLocation” service

Client behaviour:                                                                                                                               Server behaviour:
provided by the AttachmentClient                                                      Attachments layer                          provided by the AttachmentServer

                                                                                      .NET Remoting layer


   > Attachments are created through the AttachmentsManager class

                                                                                                                                                                        13
   30/05/200 .NET Technologies 2006
How it works: Communication

                             Host A                                                           Host B

                                    Attachment
  Search                                                                                 Search
  Agent 1                                                                                Agent 2


> Server-behaviour is defined by
> Server-behaviour is defined by                                      AttachmentServ er
                                                                                             [Serializable]



  the AttachmentServer object
   the AttachmentServer object
                                                      objectName: string
                                                      «NonSerialized» objRef: object
                                                      objType: Type
     Incoming request services are forwarded
        Incoming request services are forwarded       attClientsURLs: string [0..*] (ArrayList)
                                                      serverIsMoving: bool
       towards the server object
        towards the server object                     AttachmentServer(objRef, objectName, objType)
     It notifies about mobility to its connected
        It notifies about mobility to its connected
                                                      BeginServerMobility() : void
                                                      EndServerMobility(objectReference) : void
       objects
        objects
     One entity is serializable (Marshal By
        One entity is serializable (Marshal By
                                                                       [NonSerialized]1
                                                                                   MarshalByRefObject
       Value), so its state can be migrated, and
        Value), so its state can be migrated, and                   AttachmentServ erMediator

       the other is accessible remotely (Marshal
        the other is accessible remotely (Marshal         methodsList: Delegate[]

       By Reference)
        By Reference)                                     RegisterClient(attClientURL) : MethodInfo[1..*]
                                                          UnRegisterClient(attClientURL) : void
                                                          RedirectService(methodID, args) : object



                                                                                                     14
 30/05/200 .NET Technologies 2006
How it works: Communication

                                                              Host A                                                Host B

                                                                   Attachment
          Search                                                                                              Search
          Agent 1                                                                                             Agent 2

                                             [Serializable]
                                 «generated-code»
                                  Serv er-AttClient
                                                              > Client-behaviour is defined by the
                                                              > Client-behaviour is defined by the
IDeserializationCallback
                                  1
                                           [Serializable]       AttachmentClient object
                                                                AttachmentClient object
                            AttachmentClient

              methodInformation: MethodInfo [1..*]            > Composed by:
                                                              > Composed by:
              parentType: string
              serverURL: string                                     A runtime generated proxy (MSIL) of the
                                                                       A runtime generated proxy (MSIL) of the
              serviceIsConsuming: bool[]
                                                                      remote object
                                                                       remote object
              Process(methodID, args) : object
              BeginClientMobility() : void                          A remote accessible object which allows
                                                                       A remote accessible object which allows
              EndClientMobility() : void
              StopProcessingServices() : void                         to be notified about server mobility
                                                                       to be notified about server mobility
          [NonSerialized]                                           A serializable object that
                                                                       A serializable object that
    1
                    MarshalByRefObject                                 manages the attachmentClient state,
                                                                        manages the attachmentClient state,
        AttachmentClientMediator
                                                                       forwards services to the attachmentServer
                                                                        forwards services to the attachmentServer
ServerMobilityBegan() : void
ServerMobilityEnded(newURL) : void

                                                                                                                      15
        30/05/200 .NET Technologies 2006
How it works: Communication

> Inter-object communication is a very frequent operation: it must be as faster as possible

> Communication is established dynamically on demand, so dynamic code invocation must be used
    Its performance is:
     Reflection < Delegates << Direct Calls (code generation)


> We dynamically generate code on establishing a connection in order to reduce these costs




> Total introduced communication costs:
        3 direct calls + 1 dynamic invocation (through delegates) ≈ +11%


                                                                                                16
30/05/200 .NET Technologies 2006
How it works: Mobility

> The MoveObject service performs several steps:
     The object to be moved and its communication processes
      (attachments) are packaged in a MobilityPackage object
     This is serialized and transferred to the target host
     Before unpacking, it is checked whether the required assemblies are
      available. If not, they are downloaded from the source host
     The information is unpacked and, when communication processes
      are restored, the transferred object runs by invoking its specified
      method
     If anything fails, all information is restored properly
> Simultaneous mobility is also supported
     An object can move to another host while other objects, that are
      connected to it, are being moved at the same time
> The mobility process depends on the role of the object
  to be moved

                                                                         17
30/05/200 .NET Technologies 2006
How it works: Mobility

> Client behaviour:
     If it has service requests being processed, the mobility process
      waits until they finish properly (weak mobility)
     When mobility finishes, object state is restored, including its
      connections with remote objects


> Server behaviour:
     Before moving, pending requests from client objects must
      finish first
     New requests from client objects are blocked (at the attachment
      level) until mobility finishes.
     When mobility finishes, all communication processes are restored
      and client requests are processed




                                                                         18
30/05/200 .NET Technologies 2006
Contents




             > Background & Motivation

             > Search Agents case study

             > The OOAttachments approach

             > Conclusions




                                            19
30/05/200 .NET Technologies 2006
Conclusions & Future work

> An application can be easily adapted to benefit from
  these features:
     Objects do not have to take into account what communication
      technology is used
     Objects benefit from transparent (weak) mobility and distributed
      communications in a non-intrusive way
     After establishing a connection, location-awareness of connected
      objects is provided
> Further work:
     Adaptability to Service-Oriented infrastructures, such as WCF
     To provide security features to validate incoming code, such as by
      signing assemblies and by establishing trusted relations


> OpenSource project home page:
  http://workspaces.gotdotnet.com/OOAttachments
                                                                           20
30/05/200 .NET Technologies 2006
Questions




                                   21
30/05/200 .NET Technologies 2006

Weitere ähnliche Inhalte

Ähnlich wie Transparent Mobility of Distributed Objects using .NET

Remote Method Invocation
Remote Method InvocationRemote Method Invocation
Remote Method InvocationSabiha M
 
Decentralized access control with anonymous authentication of data stored in ...
Decentralized access control with anonymous authentication of data stored in ...Decentralized access control with anonymous authentication of data stored in ...
Decentralized access control with anonymous authentication of data stored in ...LeMeniz Infotech
 
Cisco Automation with Puppet and onePK - PuppetConf 2013
Cisco Automation with Puppet and onePK - PuppetConf 2013Cisco Automation with Puppet and onePK - PuppetConf 2013
Cisco Automation with Puppet and onePK - PuppetConf 2013Puppet
 
Overview of Microsoft .Net Remoting technology
Overview of Microsoft .Net Remoting technologyOverview of Microsoft .Net Remoting technology
Overview of Microsoft .Net Remoting technologyPeter R. Egli
 
Security for cloud native workloads
Security for cloud native workloadsSecurity for cloud native workloads
Security for cloud native workloadsRuncy Oommen
 
what is OpenStack ? a breif documantation
what is OpenStack ? a breif documantationwhat is OpenStack ? a breif documantation
what is OpenStack ? a breif documantationmoeincanada007
 
(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive OverviewBob Killen
 
Cloud Computing : Security and Forensics
Cloud Computing : Security and ForensicsCloud Computing : Security and Forensics
Cloud Computing : Security and ForensicsGovind Maheswaran
 
Eucalyptus - An Open-source Infrastructure for Cloud Computing
Eucalyptus - An Open-source Infrastructure for Cloud ComputingEucalyptus - An Open-source Infrastructure for Cloud Computing
Eucalyptus - An Open-source Infrastructure for Cloud Computingelliando dias
 
IRJET - Cloud based Datacenter in Virtual Private Network
IRJET - Cloud based Datacenter in Virtual Private NetworkIRJET - Cloud based Datacenter in Virtual Private Network
IRJET - Cloud based Datacenter in Virtual Private NetworkIRJET Journal
 
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaLorenzo Carnevale
 
Kubernetes acomprehensiveoverview
Kubernetes acomprehensiveoverviewKubernetes acomprehensiveoverview
Kubernetes acomprehensiveoverviewAnkit Shukla
 
Kubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewKubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewBob Killen
 
Sumo Logic Cert Jam - Advanced Metrics with Kubernetes
Sumo Logic Cert Jam - Advanced Metrics with KubernetesSumo Logic Cert Jam - Advanced Metrics with Kubernetes
Sumo Logic Cert Jam - Advanced Metrics with KubernetesSumo Logic
 
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaLorenzo Carnevale
 
Object and component based middleware for distributed system development
Object and component based middleware for distributed system developmentObject and component based middleware for distributed system development
Object and component based middleware for distributed system developmentektabhalwara
 

Ähnlich wie Transparent Mobility of Distributed Objects using .NET (20)

Remote Method Invocation
Remote Method InvocationRemote Method Invocation
Remote Method Invocation
 
Decentralized access control with anonymous authentication of data stored in ...
Decentralized access control with anonymous authentication of data stored in ...Decentralized access control with anonymous authentication of data stored in ...
Decentralized access control with anonymous authentication of data stored in ...
 
Cisco Automation with Puppet and onePK - PuppetConf 2013
Cisco Automation with Puppet and onePK - PuppetConf 2013Cisco Automation with Puppet and onePK - PuppetConf 2013
Cisco Automation with Puppet and onePK - PuppetConf 2013
 
Overview of Microsoft .Net Remoting technology
Overview of Microsoft .Net Remoting technologyOverview of Microsoft .Net Remoting technology
Overview of Microsoft .Net Remoting technology
 
Security for cloud native workloads
Security for cloud native workloadsSecurity for cloud native workloads
Security for cloud native workloads
 
what is OpenStack ? a breif documantation
what is OpenStack ? a breif documantationwhat is OpenStack ? a breif documantation
what is OpenStack ? a breif documantation
 
Netkit
NetkitNetkit
Netkit
 
(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview
 
Cloud Computing : Security and Forensics
Cloud Computing : Security and ForensicsCloud Computing : Security and Forensics
Cloud Computing : Security and Forensics
 
Eucalyptus - An Open-source Infrastructure for Cloud Computing
Eucalyptus - An Open-source Infrastructure for Cloud ComputingEucalyptus - An Open-source Infrastructure for Cloud Computing
Eucalyptus - An Open-source Infrastructure for Cloud Computing
 
IRJET - Cloud based Datacenter in Virtual Private Network
IRJET - Cloud based Datacenter in Virtual Private NetworkIRJET - Cloud based Datacenter in Virtual Private Network
IRJET - Cloud based Datacenter in Virtual Private Network
 
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
 
Kubernetes acomprehensiveoverview
Kubernetes acomprehensiveoverviewKubernetes acomprehensiveoverview
Kubernetes acomprehensiveoverview
 
Kubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewKubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive Overview
 
OpenStack Security
OpenStack SecurityOpenStack Security
OpenStack Security
 
Ch12
Ch12Ch12
Ch12
 
Sumo Logic Cert Jam - Advanced Metrics with Kubernetes
Sumo Logic Cert Jam - Advanced Metrics with KubernetesSumo Logic Cert Jam - Advanced Metrics with Kubernetes
Sumo Logic Cert Jam - Advanced Metrics with Kubernetes
 
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
 
Object and component based middleware for distributed system development
Object and component based middleware for distributed system developmentObject and component based middleware for distributed system development
Object and component based middleware for distributed system development
 
20 74-1-pb
20 74-1-pb20 74-1-pb
20 74-1-pb
 

Kürzlich hochgeladen

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 

Kürzlich hochgeladen (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 

Transparent Mobility of Distributed Objects using .NET

  • 1. 4th International Conference in Central Europe on .NET Technologies Transparent Mobility of Distributed Objects using .NET Cristóbal Costa, Nour Ali, Carlos Millan, Jose A. Carsí
  • 2. Contents > Background & Motivation > Search Agents case study > OOAttachments approach > Conclusions 2 30/05/200 .NET Technologies 2006
  • 3. Background > Previous work in Component-Based Aspect-Oriented Software Architectures > A characteristic is that the components neglect distributed nor local references of their partners > Transparent entities called Attachments are responsible of:  Interconnecting components  Providing transparent mobility and communication Node1 Node2 Component1 Component2 Attachments 3 30/05/200 .NET Technologies 2006
  • 4. Motivation > To transfer previous experience in attachments to connect objects, instead of aspect-oriented components > To provide a library to support the development of transparent mobility of distributed objects > These features must be provided:  A non intrusive and transparent way of programming  Code should not be precompiled nor preprocessed  Efficiency 4 30/05/200 .NET Technologies 2006
  • 5. Motivation > For example, it can be used by Client & Server architectures to manage both location changes in a transparent way > Why the client object has to worry about its server? Server Client 5 30/05/200 .NET Technologies 2006
  • 6. State of the art > This problem has been dealt in Mobile Agent Systems Most of them are built on Java:  Aglets, Nomads, MobJeX, Voyager, JADE, ProActive, … > There are few approaches on .NET but still in development  MAPNET, Nomad, EtherYatri.NET > Common characteristics of these approaches:  Agents are defined by means of inheritance.  In most of them, the agent has to define all its functionality in one method (usually “Run”) with a specific signature  Events are captured by overriding inherited methods  Communication among agents is realized: by using generic proxies (like “AgentProxy”), by passing messages, or by implementing specific services 6 30/05/200 .NET Technologies 2006
  • 7. Strong vs Weak Mobility Strong Mobility Weak Mobility Agent processes are interrupted in The programmer must take care a transparent way of their processes In order to implement strong mobility It is the programmer who saves the ability of thread serialization is processes information before moving required. and restores it after moving. Two main alternatives: As no customization is needed, the By extending the Framework solution is more portable (e.g. JavaThreads [Bouchenak03]) → New releases of the Framework would make it useless By preprocessing the source or binary code (e.g. Brakes [Truyen00]) → Less eficiency 7 30/05/200 .NET Technologies 2006
  • 8. Contents > Background & Motivation > Search Agents case study > OOAttachments approach > Conclusions 8 30/05/200 .NET Technologies 2006
  • 9. SearchAgents case study > There are a lot of resources over the Internet from which we want to collect distributed information > The search grows as a tree, so we need to be able to explore the resources dynamically in a distributed way A B E C D > Our solution: to send only a few agents capable of establishing transparent mobile communications  Network resources are not overloaded, as there only are a few agents travelling through the network  Agents can exchange new subsearches without realizing where the others are  They are completely autonomous: they only come back with the results, so the sender could have been disconnected during the process (e.g. mobile clients) 9 30/05/200 .NET Technologies 2006
  • 10. SearchAgent implementation > The inheritance is not limited: we do not have to inherit from a specific class to benefit from mobility > By this way, an object is made remotely accessible to others > A specific interface can be specified to restrict offered services > An object obtains a reference of a remote object by specifying its ID and current location > The remote reference is a transparent proxy that provides all the remote methods > By this way, an object moves itself to another host > There are no need to use specific methods and signatures for being called when object mobility finishes > Parameters can also be provided (e.g. for providing initialization information) 10 30/05/200 .NET Technologies 2006
  • 11. Contents > Background & Motivation > Search Agents case study > The OOAttachments approach > Conclusions 11 30/05/200 .NET Technologies 2006
  • 12. The OOAttachments approach > Features:  Objects can move autonomously among computers without having to take into account how distributed communications with other objects are performed  Since a connection is established, location-awareness is provided  No need for a centralized infrastructure to manage mobility and object registration services  Dynamic code generation and reflection is combined in order to be able of calling code dynamically, so code precompilation is not needed > Constraints:  Weak mobility is provided, so objects must take care of their threads before moving  In order to establish the first connection, a client object needs to know where the server object is located  Each mobile object must be marked as Serializable  The middleware must be running in each computer 12 30/05/200 .NET Technologies 2006
  • 13. The OOAttachments approach > Objects are connected through entities called Attachments Host A Host B [Serializable] [Serializabl e] Attachment «generated-code» AttachmentServ er Serv er-AttClient objectName: string IDeserializationCallback 1 «NonSerialized» objRef: object Search Search [Serializable] objType: T ype AttachmentClient attClientsURLs: string [0..*] (ArrayList) methodInformation: MethodInfo [1..*] serverIsMovi ng: bool parentType: stri ng serverURL: string AttachmentServer(objRef, objectName, objType) Agent 1 Agent 2 serviceIsConsum ing: bool[] BeginServerMobility() : void EndServerMobility(objectReference) : void Process(methodID, args) : object BeginClientMobility() : void EndClientMobili ty() : void [NonSerialized] 1 StopProcessingServices() : void MarshalByRefObject AttachmentServ erMediator [NonSerialized] 1 methodsList: Delegate[] MarshalByRefObject AttachmentClientMediator RegisterClient(attClientURL) : MethodInfo[1..*] ServerM obilityBegan() : void UnRegisterClient(attClientURL) : void ServerM obilityEnded(newURL) : void RedirectService(methodID, args) : object Client behaviour: Server behaviour: It invokes “NotifyNewLocation” Object layer It offers the “NotifyNewLocation” service Client behaviour: Server behaviour: provided by the AttachmentClient Attachments layer provided by the AttachmentServer .NET Remoting layer > Attachments are created through the AttachmentsManager class 13 30/05/200 .NET Technologies 2006
  • 14. How it works: Communication Host A Host B Attachment Search Search Agent 1 Agent 2 > Server-behaviour is defined by > Server-behaviour is defined by AttachmentServ er [Serializable] the AttachmentServer object the AttachmentServer object objectName: string «NonSerialized» objRef: object objType: Type  Incoming request services are forwarded Incoming request services are forwarded attClientsURLs: string [0..*] (ArrayList) serverIsMoving: bool towards the server object towards the server object AttachmentServer(objRef, objectName, objType)  It notifies about mobility to its connected It notifies about mobility to its connected BeginServerMobility() : void EndServerMobility(objectReference) : void objects objects  One entity is serializable (Marshal By One entity is serializable (Marshal By [NonSerialized]1 MarshalByRefObject Value), so its state can be migrated, and Value), so its state can be migrated, and AttachmentServ erMediator the other is accessible remotely (Marshal the other is accessible remotely (Marshal methodsList: Delegate[] By Reference) By Reference) RegisterClient(attClientURL) : MethodInfo[1..*] UnRegisterClient(attClientURL) : void RedirectService(methodID, args) : object 14 30/05/200 .NET Technologies 2006
  • 15. How it works: Communication Host A Host B Attachment Search Search Agent 1 Agent 2 [Serializable] «generated-code» Serv er-AttClient > Client-behaviour is defined by the > Client-behaviour is defined by the IDeserializationCallback 1 [Serializable] AttachmentClient object AttachmentClient object AttachmentClient methodInformation: MethodInfo [1..*] > Composed by: > Composed by: parentType: string serverURL: string  A runtime generated proxy (MSIL) of the A runtime generated proxy (MSIL) of the serviceIsConsuming: bool[] remote object remote object Process(methodID, args) : object BeginClientMobility() : void  A remote accessible object which allows A remote accessible object which allows EndClientMobility() : void StopProcessingServices() : void to be notified about server mobility to be notified about server mobility [NonSerialized]  A serializable object that A serializable object that 1 MarshalByRefObject manages the attachmentClient state, manages the attachmentClient state, AttachmentClientMediator forwards services to the attachmentServer forwards services to the attachmentServer ServerMobilityBegan() : void ServerMobilityEnded(newURL) : void 15 30/05/200 .NET Technologies 2006
  • 16. How it works: Communication > Inter-object communication is a very frequent operation: it must be as faster as possible > Communication is established dynamically on demand, so dynamic code invocation must be used  Its performance is: Reflection < Delegates << Direct Calls (code generation) > We dynamically generate code on establishing a connection in order to reduce these costs > Total introduced communication costs:  3 direct calls + 1 dynamic invocation (through delegates) ≈ +11% 16 30/05/200 .NET Technologies 2006
  • 17. How it works: Mobility > The MoveObject service performs several steps:  The object to be moved and its communication processes (attachments) are packaged in a MobilityPackage object  This is serialized and transferred to the target host  Before unpacking, it is checked whether the required assemblies are available. If not, they are downloaded from the source host  The information is unpacked and, when communication processes are restored, the transferred object runs by invoking its specified method  If anything fails, all information is restored properly > Simultaneous mobility is also supported  An object can move to another host while other objects, that are connected to it, are being moved at the same time > The mobility process depends on the role of the object to be moved 17 30/05/200 .NET Technologies 2006
  • 18. How it works: Mobility > Client behaviour:  If it has service requests being processed, the mobility process waits until they finish properly (weak mobility)  When mobility finishes, object state is restored, including its connections with remote objects > Server behaviour:  Before moving, pending requests from client objects must finish first  New requests from client objects are blocked (at the attachment level) until mobility finishes.  When mobility finishes, all communication processes are restored and client requests are processed 18 30/05/200 .NET Technologies 2006
  • 19. Contents > Background & Motivation > Search Agents case study > The OOAttachments approach > Conclusions 19 30/05/200 .NET Technologies 2006
  • 20. Conclusions & Future work > An application can be easily adapted to benefit from these features:  Objects do not have to take into account what communication technology is used  Objects benefit from transparent (weak) mobility and distributed communications in a non-intrusive way  After establishing a connection, location-awareness of connected objects is provided > Further work:  Adaptability to Service-Oriented infrastructures, such as WCF  To provide security features to validate incoming code, such as by signing assemblies and by establishing trusted relations > OpenSource project home page: http://workspaces.gotdotnet.com/OOAttachments 20 30/05/200 .NET Technologies 2006
  • 21. Questions 21 30/05/200 .NET Technologies 2006

Hinweis der Redaktion

  1. Good morning, I’m Cristobal Costa. I come from the Polytechnic University of Valencia, Spain And I’m going to present our work about “Transparent Mobility of Distributed Objects using .NET “
  2. First, I’ll present the background and motivation of this work. Then, I describe the case study on which we have applied our approach, and which illustrate the concepts Next, I’ll give you the main implementation details of our appproach Finally, I’ll present you the conclusions
  3. In our research group we are working in component-based, aspect-oriented software architectures. A characteristic of components in Sofware Architectures is that they neglect distributed nor local references of their partners. Therefore, specific entities called Attachments are responsible of interconnecting components and providing transparent mobility and communication.
  4. As a result, we have thought of transferring our experience in attachments to connect objects, instead of aspect-oriented components So, our objective was to provide a library, to the object-oriented community, to support the development of distributed objects capable of moving in a transparent way. These features must be provided in a non intrusive and transparent way of programming, the code should not be precompiled nor preprocessed, and the efficiency must be taken into account.
  5. For example, imagine that in a Client &amp; Server architecture, a server needs to change dynamically its location. With our library we want to achieve that the client objects of the server don’t have to worry about the change of location. Why the client object has to worry about its server?
  6. As there is no focused in the same way, there are several approaches to provide mobility in the area of mobile agent systems. However, most of them are built on Java, such as Aglets, JADE or ProActive. In .NET, there are a few approaches that are still in development. However, only EtherYatri.NET has a downloadable prototype. The common characteristics of these approaches are these: Agents are defined by means of inheritance In most of them, the agent has to define all its functionality in one method, whith a specific signature (usually called “Run”, with no parameters) Events are captured by overriding inherited methods Communication among agents is realized by several ways: by using generic proxies, by passing messages, or by implementing specific services NOTE: We have to mention MAPNET as a worse and inexistent platform, Aglets (the oldest one) and ProActive (as the best now, but in Java), Nomad (not a library), Etheryatri (no public documentation (papers), but well effort of porting).
  7. There are two ways of implementing mobility: there is Strong Mobility and WeakMobility. In Strong Mobility, agent processes are interrupted in a transparent way. This is the better one to perform mobility. However the ability of thread serialization is required. There are two main alternatives in current research works, mainly for Java Frameworks: By extending the Framework, like JavaThreads did. The problems arises when new releases of the framework appears, so new adjustements may be needed. By preprocessing the source or binary code, like Brakes did. The problem here is, as there are no direct access to Thread information, the eficiency is worst than in the previous approach. On the other hand, in weak mobility is the programmer who saves and restores processes information before and after mobility. Although it is less transparent than strong mobility, it’s more portable, so we have chosen this approach.
  8. From now on, i’m going to explain our approach using the case study of Search Agents. There are a lot of distributed resources among the Internet on which we want to collect information from. However, a characteristic of these resources is that the search grows as a tree. We need to explore the resources dynamically in a distributed way. Instead of sending one agent to each database (as there can be a lot of them), there will be better to use only a pair of agents capable of establishing mobile communications, that is, the ability of communicate with the others without taking into account where the others are. By this way, we won’t overload network resources, as there will only be a few agents travelling through the network. Moreover, agents will be able to exchange new subsearches: the others can perform the new subsearch before moving to another host. The manager doesn’t need to remain connected, as the agents can work in an autonomous way. When they finish, they can synchronize the results and wait till the manager is connected.
  9. For example, here is the implementation of a simplified version of the SearchAgents case study using our approach. Here, the agents only synchronize its new search location, in order to avoid that two agents performs the search in the same resource. One important difference is that the inheritance is not limited as in other approaches. Mobility and communications are provided entirely by an external object, as a pluggable library. An object is made accessible to others by registering through the AttachmentsManager. A specific interface can be specified to restrict offered services. To establish a mobile connection an object only has to invoke the ConnectTo service by specifying the current address of the object to which it wants to connect to and its ID. An object of the same type is obtained, which is a transparent proxy of the remote object. Calling this service an object can be moved in an autonomous way, by specifying any method to be executed when mobility finishes. There are no method signature restrictions. So you can see that an application can be easily adapted to support transparent mobility and communication.
  10. So, with our library, objects can move autonomously among computers without realize how distributed communications with other objects are performed. When a connection is established, location-awareness is provided. Moreover, there are no need for a centralized infrastructure to manage mobility and object registration services. Dynamic Code Generation has been used to be able of calling code dynamically. There are a few constraints to consider: Only weak mobility is provided, so objects must take care of their threads before moving. In order to establish the first connection, a client object needs to know where the server object is located And each mobile object must be marked as Serializable
  11. Let’s suppose that Search Agent 2 offers the service “NotifyNewLocation”. It provides a Server Behaviour. Search Agent 1 invokes this service, so it has a client behaviour. The role of each one is important in order to understand the following concepts. Then, we say that both objects are connected through an attachment, which in fact is divided in smaller, specific entities. The ServerBehaviour is provided by the AttachmentServer object, and the ClientBehaviour by the AttachmentClient object. We can say that these objects constitute the AttachmentsLayer, built over .NET Remoting. The attachments are created by invoking the corresponding services of the AttachmentManager class, that is, the middleware that must be running in each computer where mobility can take place.
  12. On the one hand, the AttachmentServer object is responsible for forwarding incoming request services from the AttachmentClient to the Server object, that is, “SearchAgent2”. It also notifies about mobility to its connected objects. It is also divided in two entities: one is serializable so its state can be migrated to other computers, and the other is accessible remotely. This is because of in .NET Remoting an object can not be both serializable (marshal by value) and accessible remotely (marshal by reference).
  13. On the other hand, the AttachmentClient is responsible for collecting client requests and forwarding to the other side, the Attachment Server. It is composed by a runtime generated proxy of the remote object, a remote accessible object which allows to be notified about server mobility, and a serializable object that manages the attachmentClient state and forwards services to the attachmentServer.
  14. As inter-object communication is a very frequent operation, it must be as faster as possible. However, as communication is created dynamically on demand, our infrastructure must rely on dynamic code invocation. There are several ways of doing that, but the better performance is achieved by direct call invocation, of course. For this reason, we preferred to dynamically generate code in order to make direct calls. The total introduced communication costs are not expensive, as there are only 3 direct calls and 1 dynamic ¡nvocation by using delegates, with an average cost of 11%.
  15. Mobility is performed in several steps, as stated here: First, the object to be moved and its communication processes (the attachments) are packaged This package is serialized and transferred to the target host The next step is to check out whether the required assemblies are available. If not, they are downloaded from the source host. The information is unpacked and, when the attachments are restored, the specified method of the transferred object is executed If anything fails, all information is restored properly. Moreover, simultaneous mobility is also supported. That is, an object can move to another host while the other objects, which are connected to it, are being moved at the same time. However, the mobility process depends on the role of the object to be moved.
  16. On the one hand, when the object has a client behaviour, mobility will not take place until all its service requests being processed are finished properly. When mobility finishes are restored both the object state and all remote connections with mobile objects On the other hand, if the object has a server behaviour, new requests from client objects are blocked (at the attachment level) until mobility finishes. Then, when all the service requests being processed finish, the mobility takes place. Finally, all communication processes are restored and client requests are unblocked and processed. By this way, clients don’t realize about the mobility of the server. Total mobility costs: Communication costs (transference of attachments + object state) Code migration, if needed (transference of required assemblies) Processing costs (deserialization of data &amp; communication restablishment)
  17. Finally, we can conclude that an application can be easily adapted to benefit from these features: Objects don’t have to take into account what communication technology is being used Objects benefit from transparent (weak) mobility and distributed communications in a non-intrusive way. After establishing a connection, location-awareness of connected objects is provided As a further work, it has to be considered the possibility of adaptation to Service-Oriented infrastructures, such as Windows Communication Foundation (or “Indigo”) Moreover, security is an important subject to take into account once the infrastructure is designed. For instance, we have considered the possibility of signing assemblies in order to validate what incoming code is acceptable or not. We are going to release our library as an OpenSource project, available in the following address. Nowadays it’s in Alpha state, but we planned to have our first release this summer.
  18. Thanks by your attention. Any question?