OntoWeaver-S: Integrating Web Services into Data-Intensive Web Sites Yuangui Lei, Enrico Motta, John Domingue Knowledge Media Institute the Open University Milton Keynes, MK7 6AA {y.lei, e.motta, j.b.domingue}@open.ac.uk ABSTRACT descriptions specify how to invoke a service and Designing web sites is a complex task. Ad-hoc rapid SOAP/XML [22] provides a uniform and standardised prototyping easily leads to unsatisfactory results, e.g. communication mechanisms, thus enabling easy poor maintainability and extensibility. However, existing interoperability. However, if a developer wants to bring web design frameworks focus exclusively on data web services into web sites, essentially he or she needs to presentation: the development of specific functionalities is do it entirely through low-level programming. With the still achieved through low-level programming. In this partial exception of WebML [3], none of the design paper we address this issue by describing our work on the frameworks mentioned above provides hooks to augment integration of (semantic) web services into a web design web sites with functionalities, based on web service framework, OntoWeaver. The resulting architecture, technology. Indeed, while WebML provides mechanisms OntoWeaver-S, supports rapid prototyping of service- to communicate with web services, the overall data-driven centred data-intensive web sites, which allow access to design framework has not been modified. For example, remote web services. In particular, OntoWeaver-S is the user interface constructs have not been extended for integrated with a comprehensive web service platform, enabling the access of remote web services. In other IRS-II, for the specification, discovery, and execution of words, as far as WebML is concerned, web services are web services. Moreover, it employs a set of not part of the design framework; they are simply comprehensive site ontologies to model and represent all functionalities, which can be invoked, much like any aspects of service-centred data-intensive web sites, and other web application. thus is able to offer high level support for the design and A number of web service platforms have been development process. developed to support the design, the publication, and the invocation of web services. Examples include the Java 1. Introduction Web Services Developer Pack (JWSDP) [12] and the IBM Web Services Toolkit (WSTK) [10]. However these Designing web sites is a complex task. Ad-hoc rapid platforms are very different from the web site design prototyping approaches easily lead to unsatisfactory frameworks mentioned above. Their role is to provide results, e.g. poor maintainability and extensibility. As a powerful programming environment to build applications consequence, a number of structured methodologies have based on web services, rather than providing high level been proposed to facilitate and guide the design and web site design support. Thus, we believe there is a need development processes [20, 8, 4, 9]. In particular, a of integrating web service technology into high level web number of methodologies and tools have been developed site design frameworks to facilitate the specification of to support the design of data-driven web sites at a high data-intensive web sites, which allow the access to remote level of abstraction. Examples include RMM [11], web services and the presentation of the results of web OOHDM [21], ARANEUS [2], WebML [5], OntoWebber services. So, our goal is to define mechanisms, which [13], and HERA [7]. The key feature of these approaches allow easy integration of web services into a structured, is that they provide high level support for web site design, high level support for web site design. In order to achieve from conceptualisation and specification down to this goal we make use of semantic web services [1, 6, 17], maintenance, by properly distinguishing between the which rely on semantic descriptions describing the different dimensions of web design and by organizing the functionalities of web services in a much more powerful development activities into well-structured processes. way than what available in WSDL/UDDI. Hence, by However, these approaches focus exclusively on data making use of semantic web services we can then provide presentation: the development of specific functionalities is high level support for bringing functionalities into a web still achieved through low-level programming. site, by focusing the interaction with the user (i.e., the Web service technology [24, 23, 22, 10, 12] enables web site developer) on the semantic aspects, rather than access to remote content and application functionalities, on the technical and implementation details. In particular, independently of specific implementations, or data we will take OntoWeaver [14, 15, 16], a sophisticated formats. Standardised registry mechanisms (e.g., in UDDI data-driven web design framework, as our starting point, [23]) specify the location of a service. WSDL [24] and we will augment it to support the high level integration of semantic web services into web sites. We specification of customization requirements. will call the resulting, extended architecture, OntoWeaver makes use of a customization engine to OntoWeaver-S. apply the specified rules to reason upon the site The paper is organized as follows: section 2 describes specifications according to the valuable user profiles the criteria we used to progress from OntoWeaver to (i.e. instantiations of the user models) to provide OntoWeaver-S; section 3 presents the OntoWeaver-S customization support. approach to modelling the typical user interfaces of service-centred data-intensive web sites; section 4 OntoWeaver employs RDFS [19] and RDF [18] to discusses the implementation of the OntoWeaver-S represent ontologies and specifications. Moreover, it mechanisms, which support the integration of web offers a tool infrastructure to support the entire life-cycle services into data-intensive web sites; and finally section of a customized data-intensive web site at a high level, 5 and section 6 describe related work and reiterate the including modelling, design, and maintenance. More main conclusions from this work. information about OntoWeaver can be found in [14, 15, 16]. Like other web modelling approaches mentioned 2. From OntoWeaver to OntoWeaver-S earlier, OntoWeaver focuses on data presentation and does not offer high level support for bringing web 2.1. OntoWeaver services into web sites. OntoWeaver approaches data-intensive web sites with 2.2. Evolution special focuses on dynamic data content manipulation (i.e. data content publishing, querying, and updating), user The main goal of OntoWeaver-S is to provide high interface composition, and customization design. In level support for the design of web sites that can access particular, it provides a site view ontology and a remote web services. Obviously, like OntoWeaver, presentation ontology to enable the declarative OntoWeaver-S is also a web design framework, which representation of data-intensive web sites. Moreover, provides explicit models to provide high level support for OntoWeaver proposes a generic customization framework the design of web sites. Hence, the design principles of for offering high level support for the specification of OntoWeaver-S are very much the same as OntoWeaver. customization requirements and for offering For example, the modular design architecture, which comprehensive customization support for web distinguishes different models to approach web site applications at run time. design, remains the same. The presentation ontology and The specification of a web site in OntoWeaver consists the customization framework do not need to be adapted of four perspectives: either, as they abstract the common features of the − The Domain Model abstracts the back-end data sources. presentation design and the customization design of web It contains a set of abstract concepts and relations, sites. representing data structures of the problem domain. On the other hand, the focus of OntoWeaver-S is on the integration of web services into data-intensive web − The Site View Model describes navigational structures sites. Hence, in moving from OntoWeaver to for web applications and compositional user interfaces OntoWeaver-S we have to introduce a number of for web pages in terms of the site view ontology. In changes: particular, the site view ontology provides a set of • The site view ontology, which describes navigational atomic user interface constructs as well as a set of structures and user interfaces, should be adapted to composite user interface constructs to enable the fine- support the design of the site view model for service grained level support for the composition of complex centred web sites. In particular, it should allow the user interfaces. Moreover, it provides a set of dynamic high level specification of web services within the user interface to facilitate the specification of dynamic user interface elements of target web sites. features for data-intensive web sites, including querying and manipulating the underlying domain • The tool infrastructure should be adapted towards the databases. goal of design and development of service centred web sites. In particular, the Site Designer should be − The Presentation Model specifies the visual appearance modified to offer support for the design and and layout for each component in the site view model development of this new kind of web sites. At the in terms of the presentation ontology. same time, a new run-time tool is needed to integrate − The Customization Model specifies customization web services into web sites. requirements for personalizing web pages towards individual users. It relies on the OntoWeaver As already mentioned, to enable the high level customization framework, which employs a user specification of web services in target web sites, model, a customization rule model, and a declarative OntoWeaver-S needs the support of semantic descriptions site model to enable the high level support for the describing web services. As a result, the service layer upon which site view models are built should be semantic. tool, called Service Integrator, to integrate IRS-II with Moreover, in order to integrate web services into the data-intensive web sites. Specifically, the Service target web site, OntoWeaver-S needs frameworks and Integrator collects information from a web site, then calls tools supporting the discovery and invocation of the IRS-II server (by means of IRS-II APIs) to invoke the appropriate web services by reasoning about their specified web service and gets results from IRS-II, and semantic descriptions. The IRS-II framework [17], which finally it passes the service results back to the web site. will be introduced in the next section, comes right in to fit the OntoWeaver-S framework. An 2.3. Integrating Web Services into Data-Intensive OntoWeaver-S Generated Data- OntoWeaver-S IRS-II Finding Service Web Sites Intensive Web Site Integrator Server Flights IRS-II [17] is an implemented infrastructure, which Figure 1 The process of accessing web services in has been developed in our lab, the Knowledge Media OntoWeaver-S generated data-intensive web sites Institute (http://kmi.open.ac.uk). It supports the publication, discovery, and execution of semantic web services. The following informal specification shows the OntoWeaver-S relies on a set of constructs, such as task description of a semantic web service, which answers DataComponent and KAComponent, to describe the user requests for flights in accordance with the given user interfaces for accessing web services and publishing requirements. results. These user interface constructs will be described Task Ontology: flight-service in the next section. Task Name: find-flights Input Roles: from-place (type: city) to-place (type: city) Site depart-time (type: time-point) hasIndexResource hasTask arrival-time (type: time-point) hasResource budget (type: amount-of-money) Output Roles: flights (type: Flight) SiteResource Task hasMetaData To invoke this semantic web service, a user simply hasComponent asks for the task to be achieved in terms of the task name MetaData hasSubComponent ResourceComponent find-flights and the task ontology name flight-service, the IRS-II broker then selects an appropriate problem solving hasSubResource hasCommand method (PSM) and then uses grounding information to hasOutput hasInput locate and invoke the corresponding web service – see [17] for a detailed description of IRS-II. In particular, the SubResource Output Input Command hasTask input roles carry parameters for executing the hasLinkItem hasTask hasTask corresponding web service; the output roles store the LinkItem Task service results. Please note that IRS-II only supports one output role at the moment. The data type of the output role can be primitive e.g. String, Integer, or non-primitive, Figure 2 An overview of the OntoWeaver-S site i.e. being domain classes. When the data type of the view ontology output role is not primitive, IRS-II uses XML to represent service results. For example, IRS-II uses XML to represent the results of the web service find-flights, which are instances of the class Flight. This class has been 3. Modelling Typical User Interfaces for defined in the domain ontology of the semantic web Accessing Web Services service. OntoWeaver-S employs IRS-II as a platform to Like OntoWeaver, OntoWeaver-S offers a site view integrate web services into data-intensive web sites. On ontology and a presentation ontology to allow the the one hand, OntoWeaver-S relies on IRS-II to enable declarative representation of all aspects of service-centred the access of remote web services, as IRS-II is able to data-intensive web sites. As shown in figure 2, the site locate and invoke remote web services and pass results view ontology consists of a set of navigational constructs, back. On the other hand, OntoWeaver-S uses IRS-II as a which facilitate the composition of navigational platform to allow the provision of web services for data- structures, and a set of user interface constructs, which intensive web sites. support the composition of user interfaces. In particular, Figure 1 shows the process of accessing remote web the site view ontology has been extended to model services in an OntoWeaver-S generated data-intensive service-centred data-intensive web sites. Specifically, a web site. In particular, OntoWeaver-S provides a run-time set of user interface constructs have been extended to allow the modelling of the typical user interfaces of entity. The following RDF [18] code defines one service-centred data-intensive web sites, including dynamic output element for publishing dynamic information visualization, which allows the visualization content of airline, which is one result field of the task of dynamic data content coming from the underlying find-flights (the namespace prefix 'svo' in this paper databases or remote web services, and information refers to the namespace of the OntoWeaver site view provision, which allows the provision of information for ontology: updating or querying the back-end domain data sources or xmlns:svo=”http://kmi.open.ac.uk/people/yuangui/sit for invoking remote web services. eviewontology#”). The navigational constructs are made up of Site, which models a site view as a collection of site resources i.e. web pages and a collection of task instances i.e. text descriptions of semantic web services, SiteResource, which abstracts web pages as nodes in the navigational network and as units of user interface composition, and LinkItem and DynamicLinkItem, which model the static or • Output describes the basic user interface elements dynamic link relationship between web pages. In addition, that present static information. Output elements are the constructs Parameter and ParameterClause are used to present explanations for dynamic values in proposed to allow the specification of contextual links data components. between pages. More information about the site structure • OutputComponent describes the composite user modelling can be found in [17]. interface element for publishing the value of the The user interface constructs can be classified into specified slot of the given class entity or the value of atomic constructs, which abstract basic user interface the specified output role of the given web service. An elements that can not be further decomposed into other output component typically comprises an output elements, and composite constructs, which model element, which presents explanations about the composite user interface elements. On one hand, these dynamic content, and a dynamic element, which user interface constructs can provide a fine grained level displays the dynamic content. support for user interface composition. On the other hand, • DataComponent abstracts the composite user these constructs support the high level specification of interface elements that visualize instances of a access to semantic web services. Specifically, within the specified class entity or results of a specified web user interface constructs, remote web services are service. described in terms of tasks, input roles, and output roles, which comply with the semantic representation approach employed in IRS-II [17]. Please note that the concept of output role in OntoWeaver-S is slightly different from IRS-II, when the data type of the output role of a web service is not a primitive data type but a class entity, which has a number of slots. In this case, the output roles in OntoWeaver-S refer to the slots of the result instances of the corresponding web service. 3.1. Information Visualization Figure 3 An user interface example for visualizing the results of the web service find-flights Information visualization in service-centred data- Figure 3 shows an example user interface for intensive web sites presents dynamic information, which visualizing the results of the web service find-flights. comes from the underlying databases, web resources or This user interface contains a number of dynamic output remote web services. OntoWeaver-S relies on the elements for visualizing the values of the web service following constructs to enable the composition of the user find-flights. The following code illustrates the interfaces for information visualization: composition of this data component. Please note that at • DynamicOutput models the basic user interface this stage, the layout of user interface elements is not elements that present the dynamic value of the considered. specified slot of a given class entity or the dynamic value of the specified output role of a given web service. It has a number of attributes: the attributes provision for the specified slot of the given domain class entity or for the specified input role of the … associated service. An input component typically field and an output element for presenting an explanation about the input field. … • KAComponent, which models the composite user 3.2. Information Provision interface elements that present forms for achieving the functionality of information provision. A The information provision is realized through knowledge acquisition component is typically made knowledge acquisition forms, which allow users to submit up of a set of input components and a command information to web sites. The submitted information can element. be records of the underling databases or information for invoking the specified service. Please note that in this Figure 4 shows an example user interface for accessing context, the service can be a built-in service provided by the remote web service find-flights. The user interface is OntoWeaver-S or a remote web service, which has been made up of a number of input fields and a command made available through IRS-II [17]. OntoWeaver-S button for allow end users to invoke the web service. The provides a set of built-in services for inserting data into following code illustrates the composition of this user the underlying databases and making queries over the interface. underlying databases. Hence, a knowledge acquisition component can be used for information provision, information query and web services access. OntoWeaver- S relies on a set of constructs to model the composition of knowledge acquisition forms: • Input, which abstracts the actual input fields for allowing end users specifying information for particular slots of the specified domain class entity or for particular input roles of the specified web service. The following example defines an input element, Figure 4 An user interface example for accessing which allows end users to enter information for the the web service find-flights input role of fromplace for the web service find- flights. …… • Command, which describes the interface elements for submitting information. In particular, the definition of a command element indicates the associated service and the result page node, which intends to publish earlier, the associated service can be a built-in service Figure 5 The process of accessing web services …… and publishing dynamic results coming from web services Each data component is mapped to an HTML table to publish dynamic content coming from the associated 4.1. Web Service Integration Process semantic web service. Moreover, additional server-side code is generated at the same time to enable the access of In this section, we get a closer look at the process of the specified web service and the publication of the accessing web services in the OntoWeaver-S generated service results. The following code shows the simplified data-intensive web sites. As illustrated in figure 5, the JSP code generated from the definition of the data process of accessing web services comprises the component example, which publishes results of the following steps: service find-flights. Please note that the sign of “<%” and (1) An end user opens the web page find-flights-page, “%” indicates that the wrapped code is server-side code, enters his or her requirements for finding flights and which is executed by web servers at run time. submits the input information to the web site. (2) The OntoWeaver-S Service Integrator investigates page making a request for accessing the specified web service, and gathers information from the input specified web service. <% //Part II: adding input roles for the specified task (3) The OntoWeaver-S Service Integrator calls the IRS-II function_find_flights.addInputRole("from-place", request.getParameter("kacomponent/from-place/input"); Server [17] to achieve the specified task find-flights function_find_flights.addInputRole("to-place", augmented with the given constraints. request.getParameter("kacomponent/to-place/input"); (4) The IRS-II Server invokes the corresponding web …… // Part III: achieving the specified task service. function_find_flights.achieveTask(); %> presentation modelling [11, 2, 21, 5, 13, 7]. However, as <%while (function_find_flights.hasNextResultOutput()) already pointed out, these frameworks do not provide { %> means to support access to web services. As a consequence, they limit the functionalities of the target web applications to the management of back-end data ……
<%=function_find_flights.get(“airline”) %>
<%=function_find_flights.get(“fromairport”) %>
sources. WebML [5, 3] and OntoWebber [13] are the <% }%> closest approaches to OntoWeaver-S. OntoWebber defines explicit site models to abstract The code comprises four parts: i) the first part data-intensive web sites, and uses ontologies as the instantiates a service integrator using the specified task foundation for web application design. It supports the name and the task ontology name according to the access to distributed heterogeneous data sources for the specification of the associated semantic web service; ii) target web applications by providing wrappers and the second part gathers input information from the translators to process data sources in different formats. corresponding input elements and passes the information However, OntoWebber does not support the integration of to the corresponding input roles, according to the (semantic) web services into web applications. specification of the corresponding knowledge acquisition WebML [5] relies on explicit site models to enable the component; iii) the third part achieves the specified task design and development of data-intensive web by calling the IRS-II Server; and iv) the fourth part applications. However, in comparison with OntoWeaver, presents the service results in a table repeatedly. the composition model, which provides means to enable As mentioned earlier, OntoWeaver-S provides a tool the composition of user interfaces for web pages, is not called Service Integrator to integrate semantic web expressive enough to enable the composition of complex services into web sites. The following Java code shows user interface as it does not provide constructs to model how the Service Integrator achieves this goal. First, it atomic user interface elements. Brambillla et al. [3] have calls the function achieveTask() from the IRS-II Server, recently extended WebML by means of a set of web augmenting the specified task name, task ontology name, service hypertext primitives for communicating with web and the values for the input roles. The result of this services. However, as already emphasised, they fail to function is written in XML (this has been indicated by the integrate web services into the WebML design semantic description of this web service). The framework; they simply treat them as functionalities, OntoWeaver-S Service Integration then gets the result which can be invoked, much like any other web from the IRS-II Server and processes the result, and application. makes it ready for the presentation. public void achieveTask() { 6. Conclusions String serviceResult = this.irsServer.achieveTask(this.taskName, this.taskOntologyName, This paper has shown how we have augmented this.InputRoles); this.processingResultOutputs(serviceResult); OntoWeaver, a data-driven web design framework, to } produce OntoWeaver-S, a semantic service driven //processing results and making it ready for publication framework, which supports rapid prototyping of web private void processResultOutputs(String serviceResult) service centred data-intensive web sites. OntoWeaver-S is { integrated with a comprehensive platform, IRS-II [17] for ResultOutputReader reader=new ResultOutputReader( serviceResult); the specification, discovery, and execution of semantic this.resultOutputList=reader.getResultOutputList(); web services. Moreover, OntoWeaver-S provides a set of } user interface constructs to support the modelling of the public boolean hasNextResult() typical user interfaces of service centred data-intensive { boolean hasNext= this.resultOutputList.hasNext(); web sites, including information visualization, which if (hasNext) allows the visualization of dynamic data content coming this.currentRowResult= this.resultOutputList.next(); from the underlying databases or remote web services, return hasNext; } and information provision, which allows the provision of //getting the value of the specified result field of the current row information for updating or querying the back-end domain public String get(String outputName) { data sources or for invoking remote web services. return this.currentRowResult.get(outputName); Tools have been implemented to support service } centred data-intensive web sites at design time as well as at run time. In particular, a Site Designer has been 5. Related Work implemented to offer graphic user interfaces to allow the design of data-intensive web sites; and the Service Modelling approaches to web site design typically Integrator has been prototyped to provide support for the approach the design of web applications at three levels: integration of web services into data-intensive web sites at domain modelling, navigation modelling, and run time. To our knowledge OntoWeaver-S is the first toolkit that attempts to integrate (semantic) web services into a [11] T. Isakowitz, E.A. Stohr, and P. Balasubramaninan, RMM: high level design framework. In the future, we will focus A Methodology for Structured Hypermedia Design, on defining constraints validating the complex site Communications of the ACM, August 1995. [12] Java Web Services Developer Pack, available online at specifications and provide tools helping developers to find http://java.sun.com/webservices/webservicespack.ht and correct the specifications that are either with errors or ml. being inconsistent in the entire site model. [13] Y. Jin, S. Decker, and G. Wiederhold, OntoWebber: Model-Driven Ontology-Based Web Site Management, References Semantic Web Workshop, Stanford, California, July 2001. [14] Y. Lei, E. Motta, and J. Domingue, An Ontology-Driven [1] A. Ankolekar, M. Burstein, J. Hobbs, O. Lassila, D. Martin, Approach to Web Site Generation and Maintenance, in D. McDermott, S. McIlraith, S. Narayanan, M. Paolucci, T. proceedings of 13th International Conference on Payne, and K. Sycara, DAML-S: Web Service Description Knowledge Engineering and Management, Sigüenza, Spain for the Semantic Web, in Proceedings of the 1st 1-4 October 2002, pp. 219-234. International Semantic Web Conference (ISWC 2002). [15] Y. Lei, E. Motta, and J. Domingue, Design of Customized [2] P. Atzeni, G. Mecca, and P. Merialdo, Design and Web Applications with OntoWeaver, in proceedings of the Maintenance of Data-Intensive Web Sites, in proceeding of International Conference on Knowledge Capture, Florida, the 6th int. Conference on Extending Database Technology October, 2003. (EDBT), Valencia, Spain, March 1998. [16] Y. Lei, E. Motta, and J. Domingue, Modelling Data- [3] M. Brambilla, S. Ceri, S. Comai, and P. Fraternali, Model- Intensive Web Sites with OntoWeaver, accepted in driven Development of Web Services and Hypertext International Workshop on Applications, SCI2003, Orlando, Florida, July 2003. Web Information Systems Modelling (WISM 2004), Riga, [4] S. Ceri, P. Fraternali, and S. Paraboschi, Design Principles Latvia, 2004. for Data-Intensive Web sites, SIGMOD Record, 24(1), [17] E. Motta, J. Domingue, L. Cabral, and M. Gaspari, IRS-II: March 1999. A Framework and Infrastructure for Semantic Web [5] S. Ceri, P. Fratenali, and A. Bongio, Web Modelling Services, in Proceedings of the 2nd International Semantic Language (WebML): A Modelling Language for Designing Web Conference 2003 ( ISWC 2003), 20-23 October 2003, Web Sites, WWW9 Conference, Amsterdam, May 2000. Sundial Resort, Sanibel Island, Florida, USA. [6] D. Fensel and C. Bussler (2002), the Web Service [18] Resource Description Framework (RDF) Model and Modeling Framework WSMF, available online at Syntax, W3C Proposed Recommendation. http://informatik.uibk.ac.at/users/c70385/wese/wsmf.bis200 http://www.w3.org/TR/PR-rdf-syntax/. 2.pdf. [19] Resource Description Framework (RDF) Schema [7] F. Frasincar, G. Houben, and R. Vdovjak, Specification Specification 1.0, W3C Candidate Recommendation. Framework for Engineering Adaptive Web Applications, in http://www.w3.org/TR/rdf-schema/. the Eleventh International World Wide Web Conference [20] W. Retschitzegger, W. Schwinger, Towards Modelling of WWW2002 Web Engineering Track. DataWeb Applications - A Requirement's Perspective, [8] P. Fraternali, Tools and Approaches for Developing Data- Proc. of the Americas Conference on Information Systems Intensive Web Applications: a survey, ACM Computing (AMCIS) Long Beach California, Vol. I, August 2000. Surveys, Sept. 1999. [21] D. Schwabe and G. Rossi, The Object Oriented [9] F. Garzotto, P. Paolini, and D. Schwabe, HDM—A Model- Hypermedia Design Model, Comm. Of the ACM, Vol.38, Based Approach to Hypertext Application design, ACM #8, pp 45-46, August 1995. Trans. Inf. Syst. 11, 1 (Jan. 1993), pp. 1 – 26. [22] Simple Object Access Protocol (SOAP) (2000). W3C Note [10] IBM Web Services Toolkit – A Showcase for Emerging 08. Available online at http://www.w3.org/TR/SOAP/. Web Services Technologies, available online at [23] UDDI Specification, available online at http://www- http://www.uddi.org/specification.html. 3.ibm.com/software/solutions/webservices/wstk-info.html. [24] Web Services Description Language (WSDL) (2001), W3C Note 15, available online at http://www.w3.org/TR/wsdl.