QoS Agency: An Agent-based Architecture for Supporting Quality of Service in Distributed Multimedia Systems L.A. Guedes
P.C. Oliveiray
DEE - CT Federal University of Para Belem, PA, Brazil, 66000-000
CNPTIA EMBRAPA Campinas, SP, Brazil, 13083-970
L.F. Fainaz
E. Cardozox
DEINF - CETEC Federal University of Uberl^andia Uberl^andia, MG, Brazil, 38400-902
DCA - FEEC State University of Campinas Campinas, SP, Brazil, 13083-970
Abstract
Quality of service (QoS) is a core issue in multimedia systems. Intuitively, QoS states how good the services provided by a multimedia system are. As a rule, QoS is established through negotiation between users and service providers. The negotiation involves allocation and management of resources in order to attend a desired level of quality. Examples of such resources are peripherals, CPU, network bandwidth, data formats and synchronization levels. The process of negotiation is simple if the resources are managed by a single entity (eg. operating system) or by a set of entities supporting a common negotiation protocol. Unfortunately, in distributed multimedia systems the negotiation and management of resources are far from being simple tasks since resources are diversi ed, distributed and managed by dierent entities. In order to minimize such diculties, an agent-based architecture for QoS negotiation and management is proposed in this paper. The architecture combines xed and mobile agents that interact with the aim of establishing and maintaining certain level of QoS in a distributed multimedia system. This paper also describes a partial implementation of the proposed architecture using well accepted standards such as CORBA (Object Management Group's Common Object Request Bro a
[email protected] y
[email protected] z l
[email protected] x
[email protected]
ker Architecture), RTP (Internet's Real Time Protocol), products like Aglets Workbench (a Java based mobile agent framework from IBM) and the Orbix family from Iona.
1 Introduction
Multimedia systems are computing systems that employ several types of media ranging from static ones, such as text and graphics, to dynamic (continuous) ones such as audio, video and animation. A multimedia system is often a distributed system in the sense that its components are located in dierent processing nodes of a local or wide area network. The manipulation of a continuous medium encompasses the capture, processing, transmission and presentation of large amounts of data during long periods of time. More stringent than dealing with large amounts of data are the timing constraints imposed by continuous media such as synchronization levels and end-to-end delays. In order to manipulate continuous media, a distributed multimedia system (DMS) must have an eective policy for resources management that dictates how resources are allocated, monitored, optimized and released. Since a DMS frequently runs over autonomous domains, resource management must be based on negotiation. Due to the characteristics described above, distributed multimedia systems demand sophisticated information management systems, distributed computing infrastructures and communi-
cation apparatus (networks). Unfortunately, there are few experiences accumulated regarding a methodological design and implementation of DMS. This is explained by the fact that it is dicult to incorporate continuous media manipulation into the current distributed computing technologies. Also, the standardization eorts in the eld of distributed computing are far from eectively incorporating multimedia processing into the proposed architectures. Early proposals of methodologies for incorporating QoS into DMS follow a centralized approach [1]. Recently, proposals based on brokerage [2] and client/server [3] schemes have been published. In the brokerage scheme a negotiation protocol links brokers (resource managers) located in each node of a network. A broker may act as a buyer when gathering resources or as a seller when oering available resources. In the client/server approach an application (client) interacts with a set of resource managers (servers) for resources negotiation and monitoring purposes. An extensive survey concerning the most promising schemes for supporting QoS in DMS is presented in [4]. The proposed schemes, however, are not comprehensive enough for open distributed environments. This paper proposes an architecture that relies on agent-based systems (ABS) for supporting QoS in distributed multimedia systems [5]. The architecture encompasses a set of static and mobile agents that cooperate in order to provide QoS negotiation and management capabilities to DMS. The agent-based approach favors exibility and autonomy, and presents a set of characteristics and aggregate advantages that makes it an unique paradigm for distributed systems development [6]. The remaining of the paper is organized as follows. Section 2 presents a brief introduction on QoS. Section 3 describes the process of negotiation and management of QoS for distributed multimedia systems. Section 4 addresses a negotiation and management scheme based on agents. Section 5 contains a partial implementation of the proposed architecture. Finally, section 6 presents the concluding remarks.
2 Quality of Service (QoS) in Distributed Multimedia Systems
Intuitively, quality of service is a measure of how good are the services provided to the user by a system. In order to measure the performance of a system it is necessary to focus on some mensurable parameters that match the subjective notion of \quality" from the user's point of view. Clearly, the quality of a given media (or ow) is a function of the amount of resources allocated to the
ow. Resources include CPU, network bandwidth, type of peripherals, storage capacity and software systems (user interfaces, media processing facilities, middleware facilities, and so on). A ow is composed of a sequence of segments each one consisting of the output of a capturing device (camera, microphone, etc.) sampled at a constant rate. The segments demand some processing before storage or transmission such as coding, ltering, compression and encrypting. The source and sink sides of a ow must agree on the format of the segments. For instance, for video-conferencing, 200x300 pixels of 8 bits each (256 colors) sampled at 20 frames per second and encoded according to the MPEG format is a common choice [7] [8]. In general, from the user's standpoint, QoS can be stated in terms of the following parameters (user's level parameters) [5]:
resolution: how precise the digitalization process of a media segment is (a function of bits per segment, sampling rate, etc.); distortion: a measure of information loss per media segment due to transmission errors, lossy compression strategies, etc.; synchronization level: a measure of how stable is the presentation of media segments, either in the same ow (synchronization intra-media) or in dierent, but related medium (synchronization inter-media or skew); interactiveness: how useful the media is for online cooperative work.
Usually the system works with a set of xed QoS parameters or interacts with the user in order to choose them. In the latter case the user states quality in terms of subjective parameters such as \audio of CD quality", \video of poor quality", and so on. From the system's standpoint, common QoS parameters (system's level parameters) are [7]:
end-to-end delay: the elapsed time between the generation or access of a media segment and its presentation; delay jitter: the variation of the end-to-end delay; bit error rate (BER): the percentage of bits affected by transmission failures; package error rate (PER): the percentage of packets discarded due to transmission failures.
In general terms, end-to-end delay aects interactivity; jitter aects synchronization; and BER/PER aects distortion. Usual limits for these parameters in distributed multimedia systems are 100-250 milliseconds for end-to-end delay; 5-10 millisecond for jitter; 0.001-0.01% for PER and 0.01-0.1% for BER [7]. The lower these parameters are, the higher the quality of service is.
3 Quality of Service Negotiation and Management
We understand negotiation of quality of service as the de nition of a policy for allocation of resources and the selection of a con guration for the system. This process, due to the con icting nature of the requirements involved, is a non trivial task. In order to better understand the process of negotiation of QoS, rst we present the life cycle of a multimedia system as proposed by [9]. This life cycle is divided into three phases:
Establishment phase: where the resources are allocated for the session; Management phase: where the resources are used and managed; Clearing phase: where the resources are released back to their managing entities.
The establishment phase starts with the speci cation of the QoS parameters at the user's level (that is, the \subjective" parameters). The speci cation usually states the desired level of quality plus some acceptable margins. Next, these parameters are mapped into the system's level QoS parameters, and from these to resources. Then, a negotiation starts in order to gather the resources necessary to attend the desired QoS at the system's level. In the management phase the system measures the quality of service by inspecting the system's level QoS parameters assigned to the ow (sampling and presentation rates, PER, etc.). If the degradation is caused by a shortage of resources (eg. during a network congestion) it is often desired to redistribute the remaining resources among the ows in order to degrade \gracefully" the system's overall quality of service. Re-negotiation can also be triggered by the user if he/she decides to change the QoS parameters at run-time. The re-negotiation process is similar to the negotiation process except that it must be conducted while the system is running. The cleaning phase is characterized by the releasing of the resources allocated to the system.
Three important issues arise from the analysis of the life cycle of a multimedia system regarding QoS: 1. the mapping of user's level to system's level QoS parameters; 2. the mapping of system's level QoS parameters to the amount of resources needed to achieve such level of QoS; 3. negotiation / renegotiation in order to acquire / adjust the resources as needed. Negotiation mechanisms based on autonomy and decentralization can address the issues mentioned above properly. Decentralization is demanded as a consequence of the distributed nature concerning the involved resources (spatial location and management). Also negotiation can be better conducted if the negotiator has the autonomy to make its own decisions during the course of the negotiation process. It is worth to mention that autonomy and decentralization are characteristics of agents.
4 An Agent-based Approach for QoS Negotiation and Management
Agent-based systems (ABS) are computing systems where the basic computational units are agents [6], [10]. Agents can be de ned as autonomous entities which act on behalf of their owners in order to accomplish tasks. The following characteristics are considered as fundamental for agents: delegation - users or other programs can delegate tasks to an agent and vest it with authority to act on their behalf; autonomy - an agent can make its own decisions, based on its owner's statement of goals, preferences and policies; communication - the ability agents have to interact with their peers, with the environment that hosts them, and with their owners; exibility - agents do not assume xed roles; they may act like clients, servers, observes, etc., depending on their current needs; equity - agents act like peers, in the sense that there is no hierarchical relationship among them. Partitioning a system into agents enforces modularity and encapsulation. Also, parallelism can be explored. Although not considered as fundamental, the characteristics described bellow are strongly related to agents:
cooperation - agents can act in a collaborative manner in order to achieve common goals; intelligence - the ability agents have to reason and learn from the interaction with other agents, users and the environment that hosts them; mobility - agents can move across heterogeneous computer networks, aiming to progressively accomplish tasks that were assigned to them.
Agent-based systems constitute a exible distributed computing paradigm since agents do not assume xed roles and the system's functionality is partitioned into various components (performing speci c tasks) which can be evolved or replaced without a strong impact to the whole system. New agents can be also easily added in order to enhance system's functionality. The set of characteristics presented by ABS makes it an unique approach for distributed systems development. This section presents an architecture for QoS negotiation and management based on agents. The architecture contains an agency located at each network node where a DMS runs. The QoS agency (Fig. 1) is composed of agents, a factory and a contract server (solid arrows depict communication among the components). QoS Agency contracts
fixed agents
contract server
attribute-value pairs. The attributes state QoS desired characteristics (presentation rate, etc.). Values state the accepted ranges for the attributes of a ow. Contracts are negotiated in order to acquire the resources demanded by their ows. A contract server manages contracts. The negotiation takes place in all the QoS agencies where the system manipulates ows (that is, has sources or sinks of media). A contract can be renegotiated when the resources allocated to it can not be honored by the underlying infrastructure, or when the system decides to change the contract's parameters (by adding/removing ows, changing the quality of ows, etc.). The agents that compose a QoS agency are described as follows.
4.1 Agents with Fixed Structure
In the proposed architecture there are seven agents types with xed structure which are presented in the sequel:
interface agent interacts with the DMS in order
QoS mapper agent maps the user's level QoS pa-
resource estimator agent performs the mapping
QoS monitor agent is responsible for the measure-
resource manager agent is responsible for the
local negotiator is responsible for the negotiation
QoS adaptor is noti ed when some QoS parame-
instantiation
factory instantiation
mobile agents
Fig. 1: Components of the QoS Agency. The agents have dierent structures which can be xed or mobile. By xed structure we mean a piece of code that runs at the same agency where it was instantiated (created). On the other hand, mobile structure means a piece of code that \migrates" from agency to agency carrying both the code itself and the data it manipulates. Agents are instantiated by a factory. A contract de nes multimedia ows and their QoS parameters. QoS parameters are speci ed as a set of
to obtain and to report the quality of service at the user's level;
rameters into their corresponding system's level parameters. The mapping is direct when the QoS is being speci ed or reverse when the QoS is being reported; between QoS parameters at the system's level and the computing resources demanded by such quality of service; ment of the quality exhibited by the local ows;
management of resources at its hosting node. This agent interacts with the operating system and network infrastructure for resource reservation, allocation, deallocation and reallocation; and renegotiation of the resources needed at its hosting node. It interacts with the resource manager when performing its task; ter gets out of bounds and it tries to correct the problem locally by interacting with the resource manager agent.
4.2 Agents with Mobile Structure
The proposed architecture contains three types of mobile agents. These agents perform tasks related to contract negotiation, renegotiation and monitoring. Such tasks have a global nature, that is, they depend on actions taken in more than one agency. The mobile agent types are:
contract negotiator agent performs global con-
tract negotiation. It travels from agency to agency trying to acquire resources needed by the
ows. This agent interacts with the local negotiators in each agency it migrates to; contract re-negotiator is similar to the contract
negotiator agent. This agent acts in behalf of the DMS when some parameters of the contract are changed (by adding or removing ows, for instance), or in behalf of the QoS adaptor agent, when it decides to re-negotiate a contract facing a severe degradation of its parameters;
negotiator in a similar way. In Fig. 2 the remote negotiation is illustrated by the messages 10 through 20. QoS Agency
Interface Agent
1 - user’s parameters
8 - local negotiation Ok!
Contract Negotiator QoS Mapper 2 - system’s parameters
Negotiator
3 - resource estimation
7 - local negotiation Ok!
Resource Estimator
In order to avoid con icts and deadlocks during resource allocation, all the mobile agents follow the same direction when they travel. The network node address (IP number) can be used to establish a direction for an agent's route. A global contract negotiation scenario involving two QoS agencies is illustrated in Fig. 2. The negotiation takes place during the establishment phase of a multimedia session. Fig. 3 illustrates the monitoring of a contract during the management phase of a multimedia session. The numbered arrows depicted in Fig. 2 and 3 correspond to the temporal sequence of the inter-agent message exchange. In Fig. 2 the interface agent passes the stated user's level parameters to the QoS mapper agent (1). This agent computes the corresponding system's level parameters and passes them to the local negotiator agent (2). This agent tries to reserve the resources needed at its hosting node by interacting with the resource estimator agent (local negotiation, 3-7). If the local resources can be reserved, the local negotiator agent instantiates a contract negotiator agent in order to negotiate the resources outside its hosting node (remote negotiation, 9). When arriving at remote nodes, the negotiation process is conducted by the contract
Resource
6 - reservation Ok!
Manager 4 - reservation
5 - reservation
Local Resources
contract monitor agent travels periodically to the
agencies where the DMS processes ows (and thus acquired resources). Its mission is to report how the ows generated by a source are being received by their corresponding sinks.
9 - start global negotiation Local
migration
QoS Agency
Interface Agent 12 - user’s parameters 13 - accepted negotiation
Contract Negotiator
QoS Mapper 19 negotiation Ok!
10 - remote negotiation
Local
11 - system’s parameters
Negotiator
20 negotiation Ok!
14 - resource estimation
18 - negotiation Ok! Resource
17 - reservation Ok!
Manager 15 - reservation
Resource Estimator
16 - reservation
Local Resources
Fig. 2: Global Contract Negotiation Scenario. Fig. 3 shows a global management scenario where rstly a contract monitor agent interacts with the local QoS monitor agent. In this interaction the mobile agent informs how the ows generated at the current node are being received by the destination nodes (1), and acquires the QoS exhibited by the ows terminating at the current node (2). As a result of this interaction, the QoS monitor informs the interface agent (3, 4) and the QoS Adapter (5) about the reception of the ows generated at the current node. If a moderate QoS degradation is detected, the QoS adapter reallocates the resources (6, 7). Otherwise, the QoS adapter
informs the contract violation (severe QoS degradation) to the interface agent (8). Then the interface agent can instantiate a contract re-negotiator agent (9), that will try to restore the contract's QoS. If the contract can not be successfully re-negotiated, it is terminated (all the ows of the contract are closed). QoS Agency
Interface Agent
4 - global parameters
9 - contract negotiation
migration
QoS
QoS
Mapper
Adapter
3 - system’s parameters
Contract Renegotiation
8 - contract violation
QoS Monitor
5 - global information
6 - realocation
2 - local information
Contract Monitor
1 - remote information
local information
Resource Management
7 - realocation
Local Sensors
Local Resources
migration
Fig. 3: Global Contract Management Scenario.
5 QoS Agency: Design and Implementation
A distributed multimedia system with quality of service supported by the QoS agency is shown in Fig. 4. The Object Request Broker (ORB), the QoS agency, and application objects are three key implementation components. The ORB is a software bus that provides interoperable communication for components of a distributed system. The Common Object Request Broker Architecture (CORBA) is an open speci cation of an ORB architecture proposed by the Object Management Group (OMG) [11]. The Orbix family (Orbix and OrbixWeb) of produts from Iona Technologies, Inc. [12] was adopted for supporting ORB capabilities. These products are CORBA-compliant implementations: Orbix supports C++ and OrbixWeb supports Java programming languages. The Qos Agency is composed of an agent-based framework, a contract server and an ORB Interface. The contract server was developed as an ORB object implementation in OrbixWeb. The IBM's Aglets Workbench (AWB) version alpha 5 [13] was chosen as the agent-based framework.
AWB is based on the Java programming language and is available for the Solaris and Windows 95/NT platforms. The main components of AWB currently available are: the server, the visual agent manager called Tahiti and the Agent Transfer Protocol (ATP). The ATP is used for transferring agents over the network and relies on Uniform Resource Locators (URL) for agent resource location. The Aglets Workbench provides agents migration transparently and also powerful inter-agent communication mechanisms. However, security issues still need to be addressed in a more comprehensive manner. Mobile and xed agents are being implemented as Java aglets and communicate through AWB message exchange. The factory was also implemented as an aglet agent. Since OrbixWeb [12] is a Java ORB implementation, no ORB interface is required. Application objects are domain speci c pieces of code. The proposed architecture for QoS negotiation and management is being deployed in the teleconferencing domain. However, the architecture is generic enough to be used in some other distributed multimedia domains such as video on demand and groupware. The application objects that compose a teleconference system are basically: camera, microphone, speaker, display, sources and sinks of continuous media ( ows). These objects were developed as an ORB objects implementation. The Real Time Protocol (RTP) [14] was chosen as the transport protocol supporting multimedia systems. RTP is known as a real time protocol because the amount of control information transmitted is very small. In our implementation, RTP was realized over UDP. On each ow sink there are QoS sensors that currently obtain, at the RTP level, the following QoS parameters: packet transfer rate, bandwidth, jitter and packet error rate. RTP does not assure that the established QoS parameters are met during a session. However, it measures and makes available the QoS parameters information mentioned previously. This information is employed in QoS management and QoS adaptation activities. A prototype implementation of the QoS agency is under development. Currently, it addresses the QoS monitoring step of the management phase. A teleconferecing testbed was set on SUN workstations running the Solaris operating system, connected in a local area Ethernet network. Fig. 5 illustrates this testbed. The XIL [15] library provided by Sun is used for video support, where each video ow source or sink is a Unix process. On the other hand, each audio source or sink is implemented as a thread inside an audio server
migration channel
Multimedia Transport Protocol Application Objects
QoS Agency mobile agents
flow stream
flow stream
Source
Sink
instantiation
contracts
factory
contract server
instantiation fixed agents
Agent-based Framework
ORB Interface
Object Request Broker
Fig. 4: A distributed multimedia system with QoS negotiation and management supported by the QoS Agency.
Real Time Protocol video stream
audio stream
sink
source
sink
sink
source
sink
Orbix / OrbixWeb fixed agents
fixed agents
instantiation factory
Node #1
AWB QoS Agency
factory
instantiation contract server
mobile agents
instantiation
factory
instantiation contract server
fixed agents
instantiation
Node #2
instantiation contract server
mobile agents
AWB QoS Agency
Node #3
mobile agents
Agent Transfer Protocol
Fig. 5: Teleconferencing testbed for the QoS agency prototype.
AWB QoS Agency
which is a Unix process. Some of the agents that compose the QoS agency were implemented as part of the prototype: the contract monitor, the interface agent, and the QoS monitor. QoS sensors are ORB object implementations that obtain QoS related information at the RTP level. The QoS monitor is a xed agent that measures the local performance by processing the information provided by the QoS sensors. The contract monitor is a mobile agent that migrates to the hosts where the
ows sink. As stated earlier, when the contract monitor arrives at a host, it interacts with the local QoS monitor aiming to check if the QoS parameters established in the contract are being met. After performing its task in the current host, the contract monitor moves to the next host in its itinerary. The application objects were coded in C++ as CORBA object implementations. In order to verify the feasibility of deploying a mobile agent-based approach for QoS negotiation and management, the prototype performance was checked against another approach based only on CORBA ( xed) objects. The response time for requesting the QoS through the ORB was about three times smaller than the time for the mobile agent to travel to a ow sink and get the needed information. Taking into account that AWB is based on Java which is an interpreted language, the dierence in performance between the two approaches does not make the agentbased approach unfeasible. On the contrary, when considering the advantages that such approach provides, the performed benchmarks have even encouraged us to continue using it.
6 Concluding Remarks
This paper presents a QoS negotiation and management architecture for distributed multimedia systems based on agents and a partial implementation of this architecture. Since the QoS agency is an architecture that has an unique set of characteristics, such as autonomy, exibillity, mobility and intelligence (as a direct consequence of being agent-based) it constitutes a promising approach for QoS negotiation and management in distributed multimedia systems. The contract negotiation is a complex and rich process, so we decided to specify it using formal languages such as SDL [16] and MSC [17]. This activity has already nished, and the negotiation step will be soon added to our prototype [18]. Other steps that will be addressed in a near future are: the implementation and validation of the QoS adaptors and resources estimators agents. Such agents will allow us to assess
some adaptation strategies based on AI techniques.
Acknowledgments
This research is partially support by FAPESP (grant 92/3507-0), CNPq (grant 300723/93-8) and CAPES (which provides PhD scholarships to the rst and third authors). The National Research Center for Computing Applied to Agriculture (CNPTIA/EMBRAPA) supports the second author.
References
[1] A. Campbell, G. Coulson, and D. Hutchim, A
Multimedia Enhanced Transport Service in a Quality of Service Architecture, Workshop on Network
and Operating System Support for Audio and Video'93, Lancaster, England, November. 1993. [2] K. Nahrstedt and J. Smith, The QoS Broker, IEEE Multimedia, Spring 1995, pp. 53-67. [3] B. Kerherve et al., On Distributed Multimedia Presentational Systems: Functional and Computational Architecture and QoS Negotiation, Proc. 4th
Int. Workshop on Protocols for High-Speed Networks, Chapman & Hall, London, 1994, pp. 1-17. [4] C. Aurrecoechea, A. Campbell, L. Hauw, A Review of Quality of Services Architectures, ACM Multimedia Systems Journal, November, 1995. [5] L.A. Guedes, P.C. Oliveira, E. Cardozo, An Agent-
based Approach for Quality of Service Negotiation and Management in Distributed Multimedia Systems, Mobile Agents, Vol. 1219, pp. 1-12, April,
[6] [7] [8] [9]
1997. H. S. Nwana, Software Agents: An Overview, Knowledge Engineering Review, Vol. 11, No 3, pp. 1-40, September, 1996. A. Vogel et al., Distributed Multimedia and QoS: A Survey, IEEE Multimedia, Summer 1995, pp. 10-18. B. Furht, Multimedia Systems: An Overview, IEEE Multimedia, Spring 1994, pp. 47-59. A. Ha d and G. v. Bochmann, An Approach
to Quality of Service Management for Distributed Multimedia Systems, International Conference on
Open Distributed Processing (ICODP-95), Australia, Feb. 1995, pp. 319-340. [10] P.C. Oliveira, E. Cardozo, Mobile Agent-Based
Systems: An Alternative Paradigm for Distributed Systems Development, Computer Networks Brazil-
ian Symposium, May, 1997.
[11] Object Management Group, Common Object Request Broker Architecture 2.0 Speci cation, OMG Technical Document PTC/96-03-04. [12] Iona Technologies Ltd., Iona's Orbix WWW Page, WWW URL: http://www.iona.com/Orbix/index.html. [13] IBM Corporation - Tokyo Research Laboratory, IBM Aglets Workbench-Home Page, WWW URL: http://www.trl.ibm.co.jp/aglets/. [14] H.Schulzrinne, R. Frederick and V. Jacobson,
RTP: A Transport Protocol for Real-Time Systems, Computer Communications, Jan. 96. [15] Sun Microsystems Inc., Solaris XIL 1.2 Programmer's Guide and Reference Manual, [16] Belina, F. et al., SDL with Systems from Protocol Speci cation, Prentice Hall International Ltd.,
1991. [17] E. Rudolf et all.,
sage Sequence Charts,
Tutorial on Mes-
WWW URL: http://www.win.tue.nl/win/cs/fm/sjouke/msc.html [18] L.A. Guedes, E. Cardozo, Especi caca~o de um Protocolo para Negociaca~o de Qualidade de Servico em Sistemas Multimdia (Speci cation of a Protocol for Quality of Service Negotiation in Multimedia Systems) , Computer Networks Brazilian
Symposium, May, 1997.