This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Modeling Web Interactions and Errors star Shriram Krishnamurthi 1 , Robert Bruce Findler 2 , Paul Graunke 3 ,starstar , and Matthias Felleisen 3 1 Brown University, Providence, RI, USA 2 University of Chicago, Chicago, IL, USA 3 Northeastern University, Boston, MA, USA Summary. Programmers confront a minefield when they design interactive Web programs. Web interactions take place via Web browsers. Browsers permit consumers to whimsically navigate among the various stages of a dialog, leading to unexpected outcomes. Furthermore, the growing diversity of browsers means the number of interactive operations users can per- form continues to grow. To investigate this programming problem, we develop a foundational model of Web inter- actions that reduces the panoply of browser-supported user interactions to three fundamental ones. We use the model to formally describe two classes of errors in Web programs. The de- scriptions suggest techniques for detecting both classes of errors. For one class we present an incrementally-checked record type system, which effectively eliminates these errors. For the other class, we introduce a dynamic safety check that employs program annotations to detect errors. 1 Introduction Over the past decade, the Web has evolved from a static medium into an interactive one. A representative article claims that more than half of all Web transactions are interactive , and this ratio only grows in favor of interactivity. Indeed, entire corpo- rations (including book retailers, auction sites, travel reservation services, and so on) now interact primarily or solely through the Web. These interfaces no longer present static content but rather consume user input, perform computation based on these in- puts, and generate corresponding output. As a result, the Web has been transformed into an important (and increasingly dominant) medium of interactive computation. This rapid growth in the volume of interactively generated content might suggest that Web page developers and programmers have mastered the mechanics of inter- active Web content. In practice, however, as this paper demonstrates, consumers still star This research is partially supported by NSF grants CCR-0305949, ESI-0010064 and CAI- 0086264. starstar Current affiliation: Galois Connections, Inc. 2 Krishnamurthi, et al. encounter many, and sometimes costly, program errors as they utilize these new ser- vices. Furthermore, many of these errors are caused precisely when users employ the interactive operations supported by Web browsers. A strong foundation for interac- tive computation must therefore study and address the world of Web programs. A Web program’s execution consists of a series of interactions between a Web browser and a Web server. When a Web browser submits a request whose path points to a Web program, the server invokes the program with the request via any of a number of protocols (CGI , Java servlets , or Microsoft’s ASP.NET ). It then waits for the program to terminate and turns the program’s output into a response...
View Full Document
- Fall '09
- Web page, World Wide Web, Web server, S. Krishnamurthi