Mars: a Programmable Coordination Architecture for Mobile Agents
Total Page:16
File Type:pdf, Size:1020Kb
MARS: A Programmable Coordination Architecture MOBILE AGENTS for Mobile Agents GIACOMO CABRI, LETIZIA LEONARDI, AND FRANCO ZAMBONELLI University of Modena and Reggio Emilia raditional distributed applications are designed as sets of process- es—mostly network-unaware—cooperating within assigned exe- T cution environments. Mobile agent technology, however, promotes the design of applications made up of network-aware entities that can change their execution environment by transferring themselves while exe- cuting.1,2 Current interest in mobile agents stems from the advantages they provide in Internet applications: I bandwidth savings because they can move computation to the data, I flexibility because they do not require the remote availability of spe- cific code, and Mobile agents offer much I suitability and reliability for mobile computing because they do not require continuous network connections. promise, but agent mobility and Several systems and programming environments now support mobile- Internet openness make agent-based distributed application development.2 For wide acceptance and deployment, however, we need tools that can exploit mobility while coordination more difficult. providing secure and efficient execution support, standardization, and coordination models.1 Mobile Agent Reactive Spaces, Coordination between an agent and other agents and resources in the execution environment is a fundamental activity in mobile agent applica- a Linda-like coordination tions. Coordination models have been extensively studied in the context of traditional distributed systems;3,4 however, agent mobility and the open- architecture with programming ness of the Internet introduce new problems related to naming and tracing agents roaming in a heterogeneous environment.5 features, can handle a We believe that a Linda-like coordination model—relying on shared data paces accessed in an associative way—is adaptable enough for a wide and het- heterogeneous network while erogeneous network scenario and still allows simple application design. Fur- ther, allowing interaction events to be programmed for specific agent or exe- still allowing simple and flexible cution environment needs allows additional flexibility and security. The Mobile Agent Reactive Spaces (MARS) coordination architecture, developed application design. at the University of Modena and Reggio Emilia, provides both features. 26 JULY • AUGUST 2000 http://computer.org/internet/ 1089-7801/00/$10.00 ©2000 IEEE IEEE INTERNET COMPUTING MARS COORDINATION MODELS nation model, where interactions occur in shared Mobile agent coordination models fall into four data spaces, or blackboards, local to each execution categories: client-server, meeting oriented, black- environment. Blackboards serve as both common board based, and Linda-like. repositories for messages and as sources for access- ing locally published data and services. Client-Server Model Since agents communicate by leaving messages Most Java-agent systems—such as Aglets6 and D’A- on blackboards without knowing where receivers gents (formerly Agent-TCL)7—use a client-server are or when they’ll read the messages, blackboards coordination model, specific message-passing APIs, allow temporal uncoupling and thus suit mobile or both. By directly connecting the involved enti- computing. Blackboards also provide more securi- ties, this model entails both spatial coupling, where ty than other models because execution environ- agents have to explicitly name their communica- ments can monitor all local blackboard interac- tion partners, and temporal coupling, where agents must synchronize their activities.4,5 This leads to several drawbacks for mobile agent applications: Coordination among agents and I To communicate, mobile agents must use complex and highly informed tracing protocols. resources is a fundamental activity I Repeated interactions between agents require in mobile agent applications. stable network connections. I Mobile agent applications often dynamically create new agents, which makes it difficult to identify communication partners in a spatially tions. However, because agents must agree on a coupled model. common message identifier to communicate and exchange data—for example, a file name in Ambit Thus, client-server coordination is best reserved or a URL in ffMAIN—interactions are not spa- for sharing information in a local execution tially uncoupled. environment. Linda-like Model Meeting-Oriented Model Several recent proposals for interactive Internet The meeting-oriented coordination model, introduced applications—including PageSpace12 and Java- by Telescript8 and also implemented by the Ara sys- Spaces13—use a Linda-like coordination model,14 tem,9 solves the spatial coupling problem by letting which extends the blackboard-based model by agents interact at abstract meeting points without introducing associative mechanisms into the shared explicitly naming involved partners. An agent can data space. Information is organized in tuples and open a meeting, which other agents can join, explic- retrieved in an associative way through a pattern- itly or implicitly, and communicate and synchronize matching mechanism. with each other. Meetings are usually locally con- Therefore, in addition to having all the advan- strained to avoid remote communication problems tages of blackboards, associative blackboards—tuple such as unpredictable delay and unreliability. spaces—also allow spatial uncoupling. Because The meeting-oriented model’s major drawback tuples are accessed by content rather than by iden- is that it still requires a strict temporal coupling of tifier, agent coordination requires little mutual interacting agents, forcing them to be at the same knowledge, which suits mobile agent applications. place at the same time. This either undermines the In fact, in the wide and dynamic environment of autonomy and dynamics of agents, whose sched- the Internet, it is difficult or even impossible for ule and position cannot be easily predicted, or if agents to acquire complete and up-to-date knowl- those properties are preserved, increases the risk of edge of other agents or execution environments. missing interactions. PROGRAMMABLE TUPLE Blackboard-Based Model SPACES Some proposals—including the Ambit model for Despite allowing spatial and temporal uncoupling, mobile computations10 and the ffMAIN mobile the Linda-like coordination model lacks flexibility agent system11—use the blackboard-based coordi- and interaction control. In fact, both agent-to- IEEE INTERNET COMPUTING http://computer.org/internet/ JULY • AUGUST 2000 27 FEATURE Network node Agent server B A Reference B to the local tuple space C C Internet Tuple space D Metalevel tuple space Reaction Figure 1. The MARS architecture. Agents arrive at the site (A) and are provided with a reference to the local MARS tuple space (B). They access the tuple space (C), which can react with a programmed behavior (D). agent and agent-to-execution environment inter- ty of data and resources while better protecting actions depend on the tuple spaces’ built-in data- them. Also, if application-specific programming is oriented pattern-matching mechanism, which may properly constrained to only affect the application not be suitable. It may be difficult, for example, to itself, agents from other applications will not expe- realize and control complex interaction protocols rience unexpected tuple space behavior. with just Linda-like pattern matching, and Linda’s data-oriented interaction model does not provide MARS COORDINATION an easy way to access a site’s services. ARCHITECTURE Programmable tuple space models—where MARS implements a portable and programmable tuple-space access events trigger certain computa- Linda-like coordination architecture for Java-based tional activities—solve these problems.5,15 This mobile agents. It does not implement a whole new reactivity offers several advantages for mobile agent Java agent system, but instead complements exist- applications: ing agent systems. Because it is not bound to any specific implementation, MARS can be associated I A site administrator can monitor access events with different Java-based mobile agent systems with and implement specific security policies for the only slight modification. The current implementa- execution environment. tion, available for downloading at http://sirio. I Tuples can be dynamically produced on demand, dsi.unimo.it/MOON, has already been tested with enabling a simple data-oriented mechanism for Aglets, Java-to-go, and SOMA. accessing a site’s services. For example, an agent’s As shown in Figure 1, MARS consists of many attempt to read a specific tuple can trigger the independent tuple spaces. Each tuple space is asso- execution of a local service that produces it. ciated with a node and is accessed by locally exe- I Application-specific coordination rules can be cuting agents. Integrating MARS with a mobile imposed. agent system therefore requires only that the agent server—which accepts and executes incoming One drawback of programmable tuple spaces is that agents on a node (step A in Figure 1)—supply irrational programming can distort application agents with a reference to the local MARS tuple interactions and cause users to lose control over space (step B). Agents on a node can then access the agent execution. Rather than altering application local tuple space through a well-defined set of semantics, however, site administrators are more Linda-like primitives (step C), and each MARS likely to be