Abstract
Writing large Web applications is known to be difficult. One challenge comes from the fact that the application's logic is scattered into heterogeneous clients and servers, making it difficult to share code between both sides or to move code from one side to the other. Another challenge is performance: while Web applications rely on ever more code on the client-side, they may run on smart phones with limited hardware capabilities. These two challenges raise the following problem: how to benefit from high-level languages and libraries making code complexity easier to manage and abstracting over the clients and servers differences without trading this ease of engineering for performance? This article presents high-level abstractions defined as deep embedded DSLs in Scala that can generate efficient code leveraging the characteristics of both client and server environments. We compare performance on client-side against other candidate technologies and against hand written low-level JavaScript code. Though code written with our DSL has a high level of abstraction, our benchmark on a real world application reports that it runs as fast as hand tuned low-level JavaScript code.
- J. Ashkenas. Coffeescript, 2011.Google Scholar
- B. Bibeault and Y. Kats. jQuery in Action. Dreamtech Press, 2008. Google Scholar
Digital Library
- K. J. Brown, A. K. Sujeeth, H. J. Lee, T. Rompf, H. Chafi, M. Odersky, and K. Olukotun. A heterogeneous parallel framework for domain-specific languages. In Parallel Architectures and Compilation Techniques (PACT), 2011 International Conference on, pages 89--100. IEEE, 2011. Google Scholar
Digital Library
- N. Cannasse. Using haxe. The Essential Guide to Open Source Flash Development, pages 227--244, 2008.Google Scholar
- P. Chaganti. Google Web Toolkit: GWT Java Ajax Programming. Packt Pub Limited, 2007. Google Scholar
Digital Library
- E. Cooper, S. Lindley, P. Wadler, and J. Yallop. Links: Web programming without tiers. In Formal Methods for Components and Objects, pages 266--296. Springer, 2007. Google Scholar
Digital Library
- C. Elliott, S. Finne, and O. De Moor. Compiling embedded languages. Journal of Functional Programming, 13 (3): 455--481, 2003. Google Scholar
Digital Library
- R. Griffith. The dart programming language for non-programmers-overview. 2011.Google Scholar
- T. Hoare. Null references: The billion dollar mistake. Presentation at QCon London, 2009.Google Scholar
- J. Huang, Q. Xu, B. Tiwana, Z. M. Mao, M. Zhang, and P. Bahl. Anatomizing application performance differences on smartphones. In Proceedings of the 8th international conference on Mobile systems, applications, and services, pages 165--178. ACM, 2010. Google Scholar
Digital Library
- P. Hudak. Building domain-specific embedded languages. ACM Computing Surveys, 28, 1996. URL http://dsel.ps. Google Scholar
Digital Library
- U. Jørring and W. L. Scherlis. Compilers and staging transformations. In Proceedings of the 13th ACM SIGACT-SIGPLAN symposium on Principles of programming languages, pages 86--96. ACM, 1986. Google Scholar
Digital Library
- G. Kossakowski, N. Amin, T. Rompf, and M. Odersky. JavaScript as an Embedded DSL. In J. Noble, editor, ECOOP 2012 - Object-Oriented Programming, volume 7313 of Lecture Notes in Computer Science, pages 409--434, Berlin, Heidelberg, 2012. Springer Berlin Heidelberg. URL https://github.com/js-scala/js-scala/. Google Scholar
Digital Library
- J. Kuuskeri and T. Mikkonen. Partitioning web applications between the server and the client. In Proceedings of the 2009 ACM symposium on Applied Computing, SAC '09, pages 647--652, New York, NY, USA, 2009. ACM. ISBN 978-1-60558-166-8. URL http://doi.acm.org/10.1145/1529282.1529416. Google Scholar
Digital Library
- M. McGranaghan. Clojurescript: Functional programming for javascript platforms. Internet Computing, IEEE, 15 (6): 97--102, 2011. Google Scholar
Digital Library
- T. Mikkonen and A. Taivalsaari. Web applications - spaghetti code for the 21st century. In Proceedings of the 2008 Sixth International Conference on Software Engineering Research, Management and Applications, pages 319--328, Washington, DC, USA, 2008. IEEE Computer Society. ISBN 978-0-7695-3302-5. URL http://dl.acm.org/citation.cfm?id=1443226.1444030. Google Scholar
Digital Library
- M. Nanda and S. Sinha. Accurate interprocedural null-dereference analysis for java. In Software Engineering, 2009. ICSE 2009. IEEE 31st International Conference on, pages 133--143. IEEE, 2009. Google Scholar
Digital Library
- J. C. Preciado, M. L. Trigueros, F. Sánchez-Figueroa, and S. Comai. Necessity of methodologies to model rich internet applications. In WSE, pages 7--13. IEEE Computer Society, 2005. ISBN 0-7695-2470-2. Google Scholar
Digital Library
- R. Rodríguez-Echeverría. Ria: more than a nice face. In Proceedings of the Doctoral Consortium of the International Conference on Web Engineering, volume 484. CEUR-WS.org, 2009.Google Scholar
- T. Rompf. Lightweight Modular Staging and Embedded Compilers: Abstraction without Regret for High-Level High-Performance Programming. PhD thesis, ÉCOLE POLYTECHNIQUE FÉDÉRALE DE LAUSANNE, 2012.Google Scholar
- T. Rompf, A. Sujeeth, N. Amin, K. Brown, V. Jovanovic, H. Lee, M. Jonnalagedda, K. Olukotun, and M. Odersky. Optimizing Data Structures in High-Level Programs: New Directions for Extensible Compilers based on Staging. Technical report, 2012.Google Scholar
- S. Souders. High-performance web sites. Communications of the ACM, 51 (12): 36--41, 2008. Google Scholar
Digital Library
- A. Van Deursen, P. Klint, and J. Visser. Domain-specific languages: an annotated bibliography. ACM Sigplan Notices, 35 (6): 26--36, 2000. Google Scholar
Digital Library
- E. Visser. WebDSL: A case study in domain-specific language engineering. In R. Lämmel, J. Visser, and J. Saraiva, editors, Generative and Transformational Techniques in Software Engineering II, International Summer School, GTTSE 2007, volume 5235 of Lecture Notes in Computer Science, pages 291--373, Braga, Portugal, 2007. Springer. ISBN 978-3-540-88642-6. Google Scholar
Digital Library
Index Terms
Efficient high-level abstractions for web programming
Recommendations
Efficient high-level abstractions for web programming
GPCE '13: Proceedings of the 12th international conference on Generative programming: concepts & experiencesWriting large Web applications is known to be difficult. One challenge comes from the fact that the application's logic is scattered into heterogeneous clients and servers, making it difficult to share code between both sides or to move code from one ...
Tierless Web Programming in the Large
WWW '18: Companion Proceedings of the The Web Conference 2018Tierless Web programming languages allow combining client-side and server-side programming in a single program. This allows defining expressions with both client and server parts, and at the same time provides good static guarantees regarding client-...
High-level accelerated array programming in the web browser
ARRAY 2015: Proceedings of the 2nd ACM SIGPLAN International Workshop on Libraries, Languages, and Compilers for Array ProgrammingClient-side web programming currently means using technologies embedded in web browsers to run computations on the client computer. Most solutions imply using JavaScript which allows to describe computations, and modifications of the DOM displayed by ...







Comments