<<

trends, people, incurrents the news [ projects Features Editor: Dale Strok ■ [email protected] The Web Toolkit Shines a Light on Frameworks

Greg Goth

he ’s public debut conference, and within hours some developers and rapid maturing have brought atten- became true believers, while others took a tion to the myriad tools and frame- more cautionary view of its -to-JavaScript works for facilitating Web applications, paradigm. The fact that it came from Google, particularly those written with Ajax— however, almost guaranteed close industry- T Asynchronous JavaScript and XML (for wide examination and the subsequent spec- more on Ajax, see the sidebar). One Ajax tech- trum of opinion. nology veteran, Charles Kendrick, says GWT’s “Everything Google releases gets a lot of debut had significance for the industry far be- scrutiny,” says Bret Taylor, senior product yond Google itself. manager for Google’s developer group. “We “I think it was a lot like what love the feedback even if it’s a little feisty at did for Ajax technology in general,” says times. But I think really what I see is a lot of Kendrick, chief architect of Isomorphic Soft- language warfare. Because it’s a Java-centric ware, which develops the commercial Smart- product right now, folks who aren’t big Java Client Ajax framework. “It legitimized the fans are probably not big GWT fans either. All idea of an Ajax component framework and these toolkits offer a lot of value, and it really made Ajax frameworks more visible. Google comes down to the programming environment was out there saying, ‘You don’t want to roll and languages you’re most familiar with.” your own.’” Taylor’s observations perhaps illustrate the Kendrick isn’t alone in asserting that difficulty of empirically evaluating GWT and GWT’s debut signals a new era of visibility for other Ajax frameworks side-by-side. Their ca- Ajax frameworks. Joshua Gertzen, lead devel- pabilities are similar enough that they seem to oper for ThinWire (www.thinwire.com), an be aiming toward the same end point—dynamic open source Ajax framework, says GWT’s re- Web applications that are more easily devel- lease is a continuation of the Ajax trajectory oped. Those same capabilities are also divergent Google followed with the creation of Google enough that getting a handle on what frame- Maps and Google Mail. work works best for which programming task “Something like GWT does have its merits, is sometimes confusing. Rather than a clear-cut and I think Google is to be credited with bring- comparison of apples and oranges, Ajax devel- ing widespread Ajax adoption to the fore- opers face the subtleties of comparing what front,” Gertzen says. “There’s no question that Kendrick concurs to be “apples and a different Google Maps and Google Mail played a large kind of apples.” part in that, a lot more so than the coining of ThinWire’s Gertzen says you can roughly the term Ajax itself.” separate the current Ajax market into “two distinct groups—the public-facing applications New tool from deep pockets and the business, enterprise-class applications. GWT (http://code.google.com/webtoolkit) The public-facing applications have really got- debuted at the May 2006 JavaOne developers’ ten most of the limelight.”

94 IEEE SOFTWARE Published by the IEEE Computer Society 0740-7459/07/$25.00 © 2007 IEEE CURRENTS

What could confuse developers trying to evaluate GWT’s suitability, Gertzen The Google Web Toolkit: Big Pea in the Ajax Pod says, is the seeming incompatibility be- tween its development environment— GWT might be the most visible manifestation of the Ajax framework, herald- pure Java, far more popular for server- ing more widespread use of the popular dynamic development model. side development than for Web The term Ajax, for Asynchronous JavaScript and XML, was coined in 2005 applications—and its stated goal of help- by Jesse James Garrett, president of Adaptive Path, a technology strategy and ing developers more easily write Web ap- design firm. Ajax development adds a layer of software in the traditional Web plications with Java. interface. But rather than slow down data retrieval, Ajax speeds it up by letting “GWT is interesting to me because the application load only the updated elements of the desired Web page. it kind of wants to be enterprise, but it Ajax, as its name implies, isn’t a single technology but rather a group of kind of doesn’t,” Gertzen says. “GWT technologies that deliver a desired action. Its components include XHTML and is using Java, trying to make it seem CSS (cascading style sheets) for presentation, the for like it’s a structured environment, but display and interaction, asynchronous data retrieval via XMLHttpRequest, inter- they also seem to be saying ‘We have change via XML and XSLT (Extensible Style Sheet Language Transformation), and no real significant components, we JavaScript. haven’t thought through about what’s The performance premium that Web developers (and users) obtain with Ajax needed to build more data-centric, has been its main attraction. However, the intricacies of JavaScript development data-input types of applications instead on the most popular browsers have caused many headaches; subtle incompati- of Web pages types of applications.’ So bilities from browser to browser delay application deployment. So, Google touts I think there’s still a little bit of room in GWT as offering developers both the ability to compile Java code to JavaScript terms of how things will pan out, but and browser-to-browser compatibility. just the fact it has such a huge name “The reason we released GWT was to improve the number and quality of behind it means it will be a key player.” Ajax applications,” says Google product manager Bret Taylor. “We run a fairly Isomorphic’s Kendrick, too, says large search engine here and think what’s good for the Web is good for Goo- GWT’s emphasis on Java seems incon- gle. So we released it to give developers access to some of the knowledge and gruous considering the toolkit’s likely experience we’ve developed with Ajax.” environment. GWT is just one of dozens of open source and commercial Ajax frameworks. “When we are in licensing discussions Its importance might increase now that it has become an open source project with ISVs [independent software ven- under the Apache 2.0 license. Already, developers are praising its ability to let dors], other frameworks such as Tibco or them develop Web applications in tandem with tools from the open source Backbase will come up, but never GWT platform. With additional third-party tools and widgets being developed espe- to date,” he says. “ISVs haven’t shown cially for GWT, its impact bears watching. much interest in it. To me, it’s something that appeals to somebody who is already an expert Java developer and knows a lot of Java tools, which isn’t your typical almost like going a little backwards,” the things he’s most proud of are the Ajax developer. A lot of Ajax develop- Taylor says. “But the reason we re- Java-to-JavaScript compiler and the ers like PHP or come from a Web- leased it is, when you’re developing a amount of work programming background. I think it ap- really large product like or have put into eliminating the idiosyn- peals to those who see the necessity of Google Maps and have a large devel- cratic behavior that identical code of- Ajax for their applications but are a bit opment team, things like having types ten exhibited on different platforms be- terrified of the browsers and JavaScript in your language, and well-defined in- fore GWT’s release. and that stuff, and GWT lets them stay terfaces, and modularity matter a lot “There were a lot of people in Sili- on their home turf.” more. In projects like this, you need to con Valley who maybe were really fa- Google’s Taylor says the increasing share code, automatically generate in- miliar with the idiosyncrasies of Java- complexity of Web-based application formation about interfaces, and use Script in browsers who felt very development will mandate that pro- code completion and things like that, comfortable doing Ajax,” Taylor says. gramming teams adopt a hybrid lan- that are virtually impossible with lan- “And, I think there’s also a class of guage approach—one that GWT is guages like JavaScript.” professional developers who are famil- well suited to fill. iar with languages like Java and were a “For people who are very familiar So who wants to play with it? little intimidated by the prospect of hav- with scripting languages, the prospect In the short time that developers ing to understand the idiosyncrasies of of going from a dynamic scripting lan- outside Google have been using GWT, four different browsers and three differ- guage to a more strictly typed tradi- it has garnered kudos for several of its ent operating systems. So it’s been pop- tional language like Java might seem technical hallmarks. Taylor says two of ular with that group, which didn’t want

March/April 2007 IEEE SOFTWARE 95 CURRENTS

IBM and Universities in Open Source Collaboration

Terry Costlow

ndustry-academia collaborations and basic research often velopment for the open source movement. IBM’s move “recog- get hung up by legal wrangling, but open source soft- nizes open source as a legitimate licensing regime,” says I ware’s burgeoning popularity might break down some Michael Tiemann, a pioneer in the open source movement walls. In a move that some see as a boon for early-stage who’s now Red Hat’s vice president of open source affairs. R&, IBM has linked up with seven universities, pledging to make the results of joint projects available as open source Long-term focus software. The move also underscores a shift from short-term, prod- IBM and its university partners will be doing basic re- uct-related research to investigations into long-term technolo- search in areas such as software quality, mathematical opti- gies. “IBM was hunkered down for a while, but now we’re mization, and privacy, exploring topics that have no commer- putting down a marker to say ‘this is important,’” Feldman cial-product links or even expectations of short-term solutions. says. “These are long-term, evolutionary problems where we don’t As the software field evolves, leaders in academia and in- expect a single ‘aha’ moment to crack,” says Stuart Feldman, dustry alike are beginning to focus more on end results, IBM Research’s vice president of computer science. putting less emphasis on the software technologies used to IBM’s Open Collaborative Research program aims to sim- provide answers. Open source software is increasingly be- plify collaborative programs between the corporation and coming the base for solutions in many fields. academia, eliminating intellectual-property rights by openly “The emphasis is shifting from software as being the key publishing results and offering them royalty free. product of IT industry to information, knowledge artifacts, The company’s partners are some of the leading research and services becoming the key product. Such a shift will re- universities: Carnegie Mellon University, Columbia University, sult in new, challenging questions, such as the intellectual the Georgia Institute of Technology, Purdue University, Rutgers property of knowledge artifacts,” says Elisa Bertino, a Purdue University, the University of California, Berkeley, and the Uni- computer science professor. versity of California, Davis. As in other fields, early-stage research in software often yields results that can be years from becoming a marketable Quick takeoff product. “We continually do research in computer sciences Although the agreement is just a few months old, it’s al- and software at a fundamental level. When we see an op- ready bearing fruit. “This has opened up three-way collabo- portunity to put it into a new architecture or tool, we will ration. IBM T.J. Watson, Carnegie Mellon, and Purdue are make it a research project, though it may still be a couple working together on privacy and security issues. Researchers years from being something truly useful to our company,” are very enthusiastic about how quickly things are happen- says Rod Alferness, senior VP of research at Alcatel-Lucent’s ing,” Feldman says. The three partnerships “cement our rela- Bell Labs. tionships,” he added. Feldman is bullish on the benefits, but he noted that the Significant shift project holds some pitfalls. “There is the risk that we may give If the move sparks a trend toward openness and collabo- away something that’s the equivalent of the patent for peni- ration, it will mark a significant change from the past couple cillin,” he says. of decades. In 1980, the Baye-Dole Act changed the way The move is a big step for these universities and others that federally funded university research was handled, letting uni- might follow their lead, and it’s being viewed as a positive de- versities patent research results instead of the government.

to learn what comes down to memo- (http://gwt-widget.sourceforge.net) Java and integrated develop- rization of esoteric knowledge, as op- and is writing GWT in Action: Easy ment environment—is becoming its posed to programming methodology.” Ajax with the Google Web Toolkit true calling card. Software developer Rob Hanson, (Manning Publications), scheduled for “For me, the part that really makes who was first intrigued by the Java-to- release in the middle of this year. Han- it powerful is Java—not the language JavaScript compiler when GWT was son says while the compiler is indeed itself but everything that goes with released, has become a champion of impressive, the ecosystem growing it.” the technology. He maintains the around GWT—including developers’ UK-based software development Sourceforge.net GWT widget library tools such as the Eclipse Foundation’s consultant Phil McCarthy, who wrote

96 IEEE SOFTWARE www.computer.org/software CURRENTS

Universities responded by patenting their IP in hope of turn- IBM that have embraced open source software as the basis ing a profit. for product development. Companies will always patent some “Things were skewed after the Baye-Dole Act; every uni- technologies. versity was concerned about its own technology, and there Although IBM is making a big commitment to opening up was very little collaboration,” says Mark Webbink, Red Hat’s research, the firm won’t stop working with universities to de- deputy general counsel. velop proprietary IP. “This won’t replace the other things IBM As universities focused on patent rights, collaboration be- does. If we want ownership, we know how to set that up, came increasingly more complicated. “It could take a year to even if it’s not always easy,” Feldman says. get an agreement for a one-month interaction,” Feldman says. While open source software and globalization are both Universities might find that putting research in the open major trends in today’s technical world, legal issues currently source world improves their bottom line. “Almost every uni- limit the Open Collaborative Research program to American versity has lost money on licensing once you add in legal and schools. management expenses,” Feldman says. Some studies show “All our projects are with US universities so far; the law- the loss is as high as US$40 for every dollar in revenue, Tie- yers had enough trouble getting things aligned here. We will mann says. look into other countries later,” Feldman says. Profit and loss is only one reason colleges and corpora- However, Bell Labs facilities in foreign countries are doing tions collaborate. “It’s important for us to interact with big a fair amount of collaborative research. “We have a lab in companies. They have interesting problems to solve, and we Ireland that has a university-government partnership. They need to make those relationships for our students,” says Nila also work with a consortium there, focusing on platforms and Bhakuni, Rice University’s director of technology transfer. supply chain management,” Alferness says. Corporations, of course, like the fresh ideas outsiders pro- Bell Labs also has a facility in China that partners with vide, as well the comparatively low cost. “It’s hard for compa- area universities, he adds. nies to let freewheeling organic creative processes flourish. If Although many technical and legal issues are common to they put in many rules, innovation withers,” Tiemann says. all universities and companies, the many trade-offs and indi- Still another benefit might come from students and faculty vidual views are perhaps more important than geographical who decide to start companies. Open source software might concerns. These entities take different stances on IP licensing open up opportunities. and the benefits of offering open source software based on “This gives students far greater opportunity without the their goals, which differ regardless of location. While some roadblocks that come when code is closed and there are roy- foreign universities freely work with corporate partners, some alty issues with the universities,” Webbink says. domestic universities are reluctant to partner with US compa- nies to create open source software, still preferring to license Fewer skirmishes their IP. The open approach might also eliminate much of the in- “A lot of universities have policies that are not very en- fighting at universities, where debates over patent rights and lightened in terms of open source software,” Webbink says. royalty-free, open source software often get contentious. “In Change is coming faster at private universities than at many the computer science department, this is like a religious issue; public schools because many public universities can’t change a lot of strong dialogue goes on,” Bhakuni says. financial policies without their state legislature’s involvement, These issues also arise in corporations, even those such as he adds.

an early review of GWT for the IBM bytecode within the Java virtual ma- GWT attractive to developers com- developerWorks series (www-128.ibm. chine and therefore able to take advan- fortable with Java might also be its com/developerworks/java/library/ tage of Java’s debugging facilities and greatest downfall. j-ajax4), concurs with Hanson’s assess- remain within an IDE) and the GWT “I’m concerned that Java developers ment. He’s most impressed with “the shell, allowing you to interactively de- will plunge into GWT without some ambition and completeness of the bug your entire Web-app codebase, good basic knowledge of HTML, HTTP, GWT development environment. The client- and server-side, inside Eclipse.” the browser , and JavaScript and real value of GWT is hosted mode (in Ironically, McCarthy wonders that they are going to wind up in trouble which the application is run as Java whether the very features that make when things go wrong,” McCarthy says.

March/April 2007 IEEE SOFTWARE 97 CURRENTS

“Yes, when everything works as adver- Google’s Taylor says that, as Ajax ple build on top of the source code.” tised, you can write GWT apps with little technologies mature, security issues Hanson acknowledges that develop- more than a knowledge of basic Java will be discovered and addressed over ers were concerned with a void of in- APIs. But there are plenty of things that the entire ecosystem, including GWT. formation in the first few months can go wrong on the client side, especially “Ajax is really about using tech- GWT was available. However, he says in , related to nasty, nologies in ways they weren’t origi- that the GWT team has made few false hard-to-trace subtleties like naming colli- nally intended to be used,” he says. steps in communicating with the devel- sions between element IDs and built-in “For example, the HTML DOM [Doc- oper community during the process of objects, overzealous security settings, ument Object Model] is being used to opening the project. caching problems, and so on.” display very graphically intense appli- “They weren’t ready for all this in- One of GWT’s other outside champi- cations, whereas it was originally in- terest in the product, and there was a ons is developer and ZDNet Ed tended to display documents. And long delay between releases where Burnette (http://blogs.zdnet.com/Burnette), JavaScript is being used to implement there were a lot of bugs in the system,” author of Google Web Toolkit: Taking very complex high-availability, high- he says. “People were not getting a lot the Pain out of Ajax (Pragmatic Pro- performance applications, when it was of answers as to why the bugs and why grammers). Burnette also says the seem- really designed as a scripting language so long between releases. Now that it’s ing ease of coding in GWT might hide originally. completely open, all the answers are some problems. “I think we are exposing a lot of se- there. We know what’s going on on a “If there are any shortcomings, I’d curity concerns in the process, and it daily basis, every bug that’s being say that GWT may make your job a lit- will be an interactive process between worked on, every patch. Beyond that, tle too easy, and you may get compla- the makers of toolkits and makers of the community is spinning patches cent,” Burnette says. “There are still browsers to find the right balance be- themselves. It’s really becoming a true some ‘gotchas’ to worry about—for tween user experience and security. All open source project.” example, CSS [cascading style sheet] the toolkit makers have been doing a Isomorphic Software’s Kendrick isn’t differences between browsers—so you pretty good job of trying to reduce the sure GWT will emerge as a dominant still have to test your application on possibility of introducing cross-site player, even with its open source status. different browsers to verify it looks scripting attacks and things like that. “I would probably say the market and works okay.” There’s certainly no easy solution for ev- will shape up into one or two major Another aspect of GWT that con- eryone, but everyone’s aware of them.” open source players, and if I were plac- cerns both McCarthy and ThinWire’s ing bets I’d say it would probably be Gertzen is the potential security short- Culture, not binaries, Dojo (http://dojotoolkit.org), and then coming. might be the key some commercial vendors at the high “You can make the argument that If any one factor spells success for end,” he says. “I see GWT as a bit of re- GWT in its current state might scale on GWT, it could be when Google made action against how scary Ajax is, and I a public-facing environment to 100,000 GWT an open source project under the think that given the trend of Ajax tools users more easily than ThinWire,” Gert- Apache 2.0 license in December 2006. rapidly getting better, and browser ven- zen says, “because it resides more on the Some developers’ early criticism and hesi- dors paying more attention to develop- client, but you’re exposing significantly tancy to use GWT were due to its original ers’ needs, the desire to stay in Java larger portions of your application. proprietary nature. when working with Ajax is going to in- GWT exposes multiple services and Taylor says the plan was to release it creasingly look like a reclusive reaction, endpoint calls to the server, and each as an open source project all along, but and that will cause GWT to get a bit one is a potential security risk. Thin- the GWT team wanted to make sure the marginalized.” Wire channels everything through a spe- platform had reached a certain level of Burnette says GWT will likely cific endpoint that only accepts requests maturity before opening the source to a shake up the Ajax framework market that are valid based on the current state global audience. to some extent but will probably be of the application.” “When we first released it, there was neither a behemoth nor an Edsel-like “Any code that executes in a Web a lot of stuff under the covers we wanted footnote. browser can be tampered with, or by- to change very rapidly,” he says. “We “You can look at GWT one of two passed completely, by a malicious user,” knew once we released the source code, ways. Either it threatens all other Ajax McCarthy wrote in his post-release re- people would be building on it at differ- frameworks because it largely obviates view. “GWT provides a high level of ent levels, and your ability to refactor the the need for them, or it’s complemen- that mitigates the problem entire thing changes a little bit. We re- tary to all other frameworks because, to a degree, but a secondary point of at- leased Mac OS X support before open- through the JavaScript Native Interface, tack remains: any HTTP traffic that sourcing it, and that was one of our big- you can make calls from GWT Java travels between your GWT client and ger milestones. Once we did that, we code into existing libraries. The truth is its services.” were very comfortable having other peo- probably somewhere in between.”

98 IEEE SOFTWARE www.computer.org/software