An Approach for FIPA Agent Service Discovery in Mobile ... - CiteSeerX

5 downloads 924 Views 310KB Size Report
tion organisation promoting development and specification of agent technolo- gies. Until now ... strate the benefits of FIPA agents in mobile ad hoc environments.
An Approach for FIPA Agent Service Discovery in Mobile Ad Hoc Environments Michael Pirker1, Michael Berger2, Michael Watzke2 1

Profactor Produktionsforschungs GmbH, Im Stadtgut A2, 4407 Steyr, Austria [email protected]

2

Siemens AG, Corporate Technology, Intelligent Autonomous Systems Group, Otto-Hahn-Ring 6, 81739 Munich, Germany {m.berger, michael.watzke}@siemens.com

Abstract. FIPA (Foundation for Intelligent Physical Agents) is a standardisation organisation promoting development and specification of agent technologies. Until now FIPA specifications have not been considering mobile ad hoc networks. In such environments agents depend on flexible discovery mechanisms to take advantage of services provided by other agents. This paper describes the major steps that led to the current integration of ad hoc features to the FIPA specification framework. Additionally, application examples demonstrate the benefits of FIPA agents in mobile ad hoc environments.

1 Introduction The notion of Ambient Intelligence is currently receiving considerable attention in research and industry. Ambient Intelligence combines two basic technological notions: the intelligent personal assistance and delegation with the ability to dynamically discover and interact with services in a digital ambience. That ambience is aware of the user’s presence, it is able to provide users with personalised services to their requirements, and it is able to anticipate their behaviour and responding to their presence. These two notions and the related shift from interactive to proactive computing are at the heart of Ambient Intelligence. Considering the technology for realizing that vision, agent technology will play an important role by providing intelligent, autonomous, proactive and adaptive software entities. Beside the intelligence, Ubiquitous Computing is a necessary prerequisite for Ambient Intelligence. According to [1], Ubiquitous Computing is “… the method of enhancing computer use by making many computers available throughout the physical environment, but making them effectively invisible to the user”. Effectively, a ubiquitous computing environment is a dynamic distributed network of embedded devices and systems that can interact with humans to satisfy their requirements and provide them with a variety of information, communication, or collaboration services [2]. To support Ubiquitous Computing environments, a standardized, open and flexible infrastructure is needed. Since agent technology is very important for Ambient Intelligence, it is essential to figure out how current agent platforms (APs) can also support the requirements for a Ubiquitous Computing infrastructure. The next two sections will analyse and discuss

how FIPA (Foundation for Intelligent Physical Agents) [www.fipa.org], as the leading organisation specifying standards for agent technologies, could extend the specifications for Ubiquitous Computing environments by adding ad hoc service discovery and collaboration. 1.1 FIPA’s Agent Platform Approach The FIPA AP provides an infrastructure for deploying agents. Although FIPA's main concern is about achieving interoperability between APs, FIPA requires that every FIPA-compliant AP implements three capabilities: The mandatory Agent Management System (AMS, white pages) [3], the mandatory Message Transport Service (MTS) [4], and the optional Directory Facilitator (DF, yellow pages) [3]. The AMS is responsible for agent creation and deletion, maintenance of a whitepage directory service for agents residing on the AP and the agent life-cycle management. Agents from different APs communicate over the MTS by exchanging Agent Communication Language (ACL) messages. The DF implements a very efficient search and matching mechanisms by using specific high-level DF-agent-descriptions (DAD) [3]. Based on the FIPA DF definition, the search of agent services in other APs (remote discovery) is accomplished by using DF federations: DFs—besides registering services offered by local agents—may also register other DFs. This allows them to extend the search for services to remote platforms. FIPA has also recognized the importance of mobile computing and provides agent standard like a bit-efficient ACL and envelope encoding for connections with low bandwidth [5, 6]. These solutions have been proved to be efficient in environments where slow wireless networks are involved [7]. An example of a distributed FIPA-compliant AP running agents hosted on PCs as well as on small mobile devices such as PDAs or mobile phones is Jade-Leap [8]. 1.2 Aims and Options for a FIPA Standard in Mobile Ad Hoc Environments In addition to the approaches for mobile devices and slow mobile connections, mentioned above, FIPA needs a solution for agents interoperating in Ubiquitous Computing environments with ad hoc communication. The DF federation mechanism is not efficient for flexible service discovery with mobile ad hoc communication, for example, because it uses a two step approach for finding services: first find the remote DF and afterwards look for the services registered there. FIPA started a Technical Committee (TC ad hoc1) in 2002 to develop a solution for FIPA platforms in ad hoc environments. Several proposals were made (e.g. [9], [10] and [11]). The TC made a classification and validation of the approaches. Paper [9] summarizes the discussion and describes requirements and possible approaches from an architectural point of view (Figure 1 shows two examples). Finally FIPA decided not to develop its own protocol for service discovery in ad hoc environments but to use already existing Discovery Middleware (DM). Two of the reasons for the decision are: Allowing registering and discovering agent services using existing Peer-to-Peer (P2P) / ad hoc discovery technologies that are specifically developed for these envi1 The authors are very grateful to all who contributed to the fruitful work of FIPA TC Ad Hoc.

ronments can enable a more efficient management of service descriptions and directories. Furthermore, existing P2P and ad hoc technologies can also be used as mechanisms for agent (platform) societies in fixed networks.

Fig. 1. a) Architecture with discovery, b) Architecture with FIPA-defined discovery

Based on that decision, this paper describes a special proposal to FIPA with an approach where the FIPA architecture will be extended by a mechanism managing underlying DMs. In addition, this paper describes a specific DM. In Chapter 2, existing DM technologies are evaluated for their usability. Chapter 3 describes the proposal for extending FIPA platforms by DM components. Chapter 4 describes the current implementation and application. Chapter 5 summarizes and concludes the paper.

2

Evaluation of Discovery Middleware Technologies

Bluetooth [12], Universal Plug and Play (UPnP) [13], JXTA [14], Gnutella [15] and Chord [16] represent a considerable set of current technologies applicable to discovery in mobile ad hoc environments. Bluetooth and UPnP are ad hoc technologies specifying an extensive stack of protocols and application profiles. Distributed Hash Tables (DHTs) are becoming a wide-spread technology for P2P networks. DHT approaches like Chord allow more efficient discovery than traditional P2P protocols like Gnutella. JXTA is an emerging P2P networking standard, which lies between the Gnutella-like flooding protocols and DHT approaches. 2.1 Discovery Middleware Requirements One main requirement for a DM is, that the discovery process supported by the DM should also provide a template based search as specified for the DF in [3]. To enable this kind of discovery, first FIPA DADs must be mapped to the service representation of a DM. Second, these service representations must be efficiently discoverable. Although the overall focus for this work was on small mobile ad hoc networks comprising a couple of devices in single hop distance, another important DM feature is scalability. Future applications are likely to consist of an increasing number of mobile nodes, possibly in multi hop distance, sometimes operating in an infrastructureless environment and sometimes linked to a fixed network infrastructure. 2.2 Analysis of Discovery Middleware Technologies As Figure 2 shows, the focus for discovery is at the level of transport and service related mechanisms. The transport layer provides concepts and protocols to exchange data. Building on the transport layer, the service layer offers concepts and protocols for discovering and invoking services. All technologies introduced at the beginning of

this chapter cover with varying comprehensiveness these two layers. Next, important aspects of these technologies will be described and discussed. For details see [17].

Fig. 2. Overview of Discovery Middleware capabilities

Bluetooth service records consist of mandatory and user definable attribute/value pairs describing an offered service. Within a service record Bluetooth only supports the search for attributes, and not for attribute/value pairs. In addition, searchable attributes must be predefined Universally Unique Identifiers (UUIDs). After a device has been discovered, a search query consisting of some UUIDs can be directed to the device and returns handles to matching service records. A handle can then be used to access the attribute/value pairs. Bluetooth is targeted at small mobile ad hoc networks organized in piconets of at maximum eight concurrently active devices, one master and seven slaves. Scalability is achieved by combining several piconets to a scatternet where some devices must participate in two piconets to act as a bridge. UPnP service description documents are XML documents describing service actions and their arguments, and state variables. UPnP only supports the search for certain service types listed within the device description document. First a certain type of device has to be discovered and its device description document must be retrieved. Then for each matching service type listed in the device description document the service description document can be retrieved. UPnP depends on multicasts, using one dedicated UPnP multicast address. JXTA advertisements are XML encoded resource descriptions. Although several predefined types of advertisements exist, extended or new types of arbitrarily nested advertisements may be introduced. Advertisements can be discovered on all or certain nodes of a peer group, depending on attribute/value pairs that must exist in matching advertisements. Peer groups are clusters of certain JXTA services provided by network nodes. By default only search queries using predefined attributes, like Type or ID, are possible. JXTA implements a DHT (Distributed Hash Tables) algorithm [18] that takes effect beyond a peer's local (multicasting based) neighbourhood. Additionally JXTA offers relays and the Endpoint Routing Protocol (ERP) to increase the number of peers efficiently. Relays can be used to bridge different physical or logical networks by forwarding messages on behalf of peers that can not directly address each other. The multi hop ERP connects peers within the virtual JXTA network, even across firewalls. Gnutella has no structure for storing service representations. It only supports the transmission of an arbitrary query string within a descriptor but does not deal with its

processing. Descriptors are the basic unit of information. They are transported in TCP datagrams and are routed by flooding the network. Flooding simply forwards descriptors to all known peers, which in turn do the same. As a Gnutella extension supernodes route descriptors and forward them to ordinary (edge)nodes. DHT approaches like Chord always need an additional structure to represent services. DHT algorithms provide good scalability. For n peers they offer access times of O(log n) and the size of routing tables has a logarithmic dependence on the number of nodes. DHTs also offer a high probability of finding existing services on the network. 2.3 Evaluation Results – Choosing JXTA as a First Discovery Middleware Bluetooth and UPnP assist in finding a certain service on a certain device based on an ID like search criterion, namely UUIDs or service types. Also in DHTs a key(word) is used to distribute and locate service representations. Hence a search for a DAD could only be performed with the key used to compute the hash value but not with arbitrary attribute/value pairs. Bluetooth’s scalability based on scatternets might turn out to be too sedate for dynamic environments. Gnutella flooding and DHTs offer better scalability but are even less suited for dynamic environments, because flooding is sedate and causes heavy network, and DHTs require a regular update for their routing and resource tables. Although multicasting causes notable network load, the dynamic topology of the targeted small networks can be managed quite efficiently with it. JXTA should be considered as a first DM because it can be adapted with reasonable effort to map and discover DADs. The nested structure of DADs is well reflected by JXTA advertisements and JXTA’s open design allows the addition of a template based discovery mechanism using arbitrary attribute/value pairs. JXTA’s scalability and its mixture of multicasting and DHTs guarantees operability in small mobile ad hoc networks and large scale fixed ones. In future applications this would allow the efficient linking of large scale fixed and small mobile networks. Moreover, since JXTA is an emerging and non-proprietary de facto standard for P2P computing it is likely to gain high acceptance in the FIPA community.

3 Ad Hoc Agent Service Discovery: Concept and Realisation Although JXTA can be used as a first DM, all current P2P / ad hoc technologies have strengths and weaknesses. Standardizing only one DM means to focus on just one (restricted) technology. An open architecture that allows the mapping of FIPA concepts to several (current and future) DMs seems to be the best solution to this problem. 3.1 Architecture Approach To offer agents one uniform (ad hoc) network discovery functionality, regardless of the utilized DM(s), the Agent Discovery Service (ADS) was introduced (Figure 3 (a)). The ADS is an AP component lying within the FIPA architecture at the same level as the MTS. The ADS manages one or more DMs, which are accessed via a standardised DM interface. The DMs take DADs, convert them to their internal representation, perform discovery and return DADs to the ADS. As the ADS does not affect existing FIPA AP components like the DF, it is a handy (ad hoc) network discovery test bed for different DMs.

Fig. 3. (a) The ad hoc agent service discovery architecture. (b) The JXTA DM configuration

For agents the ADS offers a high-level DF-like interface supporting (de)registration and search of DADs. In contrast to the DF, the ADS additionally offers a subscribe mechanism supporting an asynchronous search for DADs: Once a DAD search template has been passed to the ADS, all matching DADs will be returned until unsubscribe is invoked. Agents can apply the offered ADS mechanisms either to selected DMs or to all available ones. This means that the network accessible via the ADS is a compound of all networks supported by the invoked DMs. 3.2 The JXTA Discovery Middleware Component The Generic Discovery Service (GDS), see Figure 3 (b), was defined within JXTA to discover GDS advertisements. GDS advertisements are a container for arbitrary attribute/value pairs and carry a small amount of meta-information to be processable by the GDS. DAD advertisements are defined with XML-Schema and are one special instance of GDS advertisements. DAD advertisements are used to represent FIPA DADs and DAD search templates within JXTA. The GDS uses JXTA's resolver service for the transport of GDS advertisements and uses JXTA's discovery service to discover them. Compared to JXTA’s discovery service the GDS provides template based search and subscribe mechanisms that work with arbitrary attribute/value pairs for matching. The GDS implements a simple protocol, the Generic Discovery Protocol (GDP) to discover and exchange GDS advertisements. The GDP is a request/response protocol, comprising the GenericDiscoveryQuery and GenericDiscoveryResponse messages. The GenericDiscoveryQuery is used for emitting discovery queries and contains a GDS advertisement being the search template. The GenericDiscoveryResponse contains matching GDS advertisements. The Agent Peer Group (APG) was defined for hosting the GDS. The APG is, like all JXTA peer groups, a child of the JXTA Net Peer Group. The APG must be joined by all peers that want to invoke the GDS, because the APG is the scope of the GDS. 3.3 Integration in the FIPA Framework The integration of the described architecture approach with the existing FIPA framework was realized by integrating the key features of the ADS into the DF. (Hence the DF of Figure 3 (a) can be omitted and the ADS of Figure (a) becomes the new DF.) As a consequence the Agent Management Specification [3] had to be extended and the new JXTA Discovery Middleware Specification [19] had to be introduced.

The DF was extended to manage DMs, to have a subscribe mechanism and to offer introspection. While providing the usual high-level interface for agents, a DF may also wrap DMs. In this way agents become discoverable on different kinds of (ad hoc) networks depending on the underlying DM technologies. Additionally the DF may provide a subscribe mechanism as explained in Section 3.1. DF introspection provides agents with information about the internal configuration of a DF, e.g. its DMs. With this information, agents can register, search or subscribe using only selected DMs. Making available a new DM to the DF requires creating a new DM related specification. The first of this kind adheres to the JXTA DM design described in Section 3.2. The specification defines how a JXTA DM manages to map DADs to JXTA DAD advertisements and how to facilitate a template based search with the means of JXTA.

4 Implementation and Application The ADS architecture described in Section 3.1 was integrated in the Jade-Leap 3.01b Personal Java version. A JXTA DM as described in Section 3.2 was implemented on top of the JXTA 1.0 Personal Java version. The whole prototype was tested on WLAN enabled iPAQ PDAs running Windows CE and Jeode Personal Java 1.2 by means of three simple Agents: The PublishAgent registers and deregisters its DAD in random time intervals to simulate the dynamic environments. The SearchAgent permanently emits search queries and the SubscribeAgent subscribes with a DAD template to find eventually registered PublishAgent DADs. In order to demonstrate and evaluate the benefits that the proposed FIPA ad hoc solution will bring to users we are porting existing demonstrators to the new platform. The first demonstrator (shown by Siemens at the Cebit fair in Hannover in February 2002) (see [20]) provides an application ”Jukebots” giving a mobile phone or PDA the capability of generating and adapting automatically a music profile for its user. With the profiles of different users e.g. in a bar scenario, their mobile phones or PDAs will decide which songs are to be played by the disc jockey (human or computer) through a partly automated voting process. The second demonstrator implemented by Siemens CT shows a mobile ad hoc advertisement application “Mobile Ad” (see [9]). People having that application on their device may edit a profile which is describing which goods they advertise for which price and which they are looking for. During walking on the street, the mobile application detects other users and matches the profiles. If there are common interests in selling and buying, the contact information will be exchanged. Both demonstrators will use the capabilities of the DM approach. Further application examples can be seen in office environments (e.g. control of printing devices), home environments (control of TV) or in hospitals for managing medical devices.

5 Summary and Outlook Ubiquitous Computing combined with agent technology is a good basis for the highly dynamic and complex nature of Ambient Intelligence services and applications. We described an ongoing technical work within FIPA standardization organization enabling FIPA-compliant agent systems to operate in mobile ad hoc environments. FIPA decided not to develop its own protocol for service discovery but to exploit already

existing Discovery Middleware. An evaluation of selected P2P / ad hoc DMs showed that the mapping of FIPA concepts to several (current and future) DMs is the best solution because no DM fulfils all requirements and is appropriate for all ad hoc environments. We outlined a flexible approach that allows the integration of existing and upcoming DMs with the FIPA architecture, and described a possible JXTA DM. We showed that these extensions enable programmers to use high-level agent development in ad hoc environments to build reliable Ambient Intelligence applications. As foundation for many new and exciting applications the most important next step will be to define a FIPA standard for mobile ad hoc environments. Developing other DMs such as a Bluetooth DM will also be paying, because Bluetooth is already available in many mobile devices. Further research into a transition from single to multi hop DMs and the linking of large scale fixed and small mobile networks is also needed.

References 1. M. Weiser: Some Computer Science Issues in Ubiquitous Computing. ACM, July 1993 2. M. Calisti and D. Greenwood: On the Road to Ambient Intelligence. Proc. 2nd European Workshop on Multiagent Systems (EUMAS), 2003 3. FIPA: Agent Management Specification, Dec. 2002 4. FIPA: Agent Message Transport Service Specification, Dec. 2002 5. FIPA: ACL Message Representation in Bit-Efficient Specification, Dec. 2002 6. FIPA: Agent Message Transport Envelope Representation in Bit Efficient Spec., Dec. 2002 7. H. Helin and M. Laukkanen: Performance Analysis of Software Agent Communication in Slow Wireless Networks. In: Proc. of the 11th International Conference on Computer Communications and Networks (ICCCN’02), pp. 354-361, Oct. 2002 8. M. Berger et al.: Towards an Agent-Based Infrastructure for Distributed Virtual Organizations. In Proc. of the 10th IEEE International Workshops on Enabling Technologies: Infrastructure for Collaborative Enterprises (Wetice 2001), pp. 354–355. 2001 9. M. Berger, M. Watzke, H. Helin: Towards a FIPA approach for Mobile Ad hoc Environments. ICIN’03 (Intelligence in Next Generation Networks), Bordeaux, April 2003 10.J. Lawrence: Leap into ad hoc networks. Workshop on Ubiquitous Agents, AAMAS’02, Bologna, July 2002 11.C. Campo: Service Discovery in pervasive Multi-Agent Systems. Workshop on Ubiquitous Agents, AAMAS’02, Bologna, July 2002 12.Bluetooth SIG: Specification of the Bluetooth System, Vol. 1, Core, V. 1.1, Feb. 2001 13.Microsoft Corporation: Universal Plug and Play Device Architecture, V. 1.0, June 2000 14.Sun Microsystems: Project JXTA v2.0: Java Programmer's Guide, March 2003 15.Clip2: The Gnutella Protocol Specification, Version 0.4, 2000 16.I. Stoica et al.: Chord: A Scalable Peer-to-peer Lookup Service for Internet Applications. In: Proc. of the 2001 ACM Conference on Applications, Technologies, Architectures, and Protocols for Computer Communication. ACM Press, New York, pp 149–160, 2001 17.M. Pirker: A Concept for the Interoperability of FIPA Agents in Mobile Ad Hoc Environments. Diploma Thesis, Technical University Graz & Siemens AG, Sept. 2003 18.B. Traversat et al: A Loosely-Consistent DHT Rendezvous Walker. Sun , March 2003 19.FIPA: JXTA Discovery Middleware Specification, Oct. 2003 20.M. Berger et al.: Porting Distributed Agent-Middleware to Small Mobile Devices. Workshop on Ubiquitous Agents, AAMAS’02, Bologna, July 2002