<<

Web Application Development and/or

Toni Ruottu Why Develop Web Apps?

secure portable easy good quality debugger everywhere Really Short Computer System History

1. mainframe 2. mainframe - cable - multiple terminals 3. (PC) 4. PC - cable - PC 5. PC - acoustic coupler - phone - acoustic coupler - PC 6. PC - modem - PC 7. bulletin board system - modem - multiple PCs 8. multiple servers - - multiple PCs The Early Internet

Servers that reveal hierarchies: ftp Usenet news gopher HyperText (HTML)

a new (at that time) hypertext format text with links Standard Generalized Markup Language (SGML) based web 1.0 is born! html2 standardization html3 lists web forms ~feature complete Clean-up

html4 styling markup separated to xhtml1 changed from SGML to XML as base xhtml2 move out "as much as possible" (, xframes) making the syntax elegant Xhtml2 Implementations

not too much support from industrial browser-vendors , , IE instead separate translators Chiba (-side "browser") Deng (flash based browser in a browser) special -browsers X-smiles (TKK heavily involved afaik) The Era of , and NPAPI Plug-ins

(x)html focuses on textual documents you can use , but it is sloooow and the sandbox is lacking lots of useful interfaces to do something "cool" you need to use the Plug- in Application Programming (NPAPI) which makes doing something "cool" less cool the most used NPAPI plug-ins include: flash, java, pdf, audio, and video still, there are empires built on top of these plug-ins no-one can deny impact of flash in taking the web forward ( e.g. http://badgerbadgerbadger.com/ ;-) even as we speak the fresh hit game called Minecraft is being developed with Java, and served as a Web 2.0

empty web sites that anyone can fill blogs users stop writing html and start using it instead publishing available to everyone regardless html-skills regardless of access to servers because published information in blogs has a predetermined format, it can be easily converted to other formats feeds, feeds social enrichment of content starts this means "comments on news sites" in layman's terms The Golden Era of Webapp Markups

(x)html 5 ditch SGML ditch XML (to some degree) define parsing rules for xml, html, and broken markup css3 module explosion transformations in time and space, and what not simple meta format good for developing simple formats not a multi-dimentional tree with multiple encodings and namespaces (like xml is) The html5 Specification

Written at WhatWG and W3C simultaneously focus on making the impossible possible not prettifying the language similar to the theoretical philosophy department in a university as soon as something useful is invented a separate thread is spawned for it the ever shrinking specification currently only ~700 a4 pages the index alone is more than 10 pages occasional access difficulties due to size gets larger at times What is html5 really?

answer: It is a buzz word! even the spec discusses vagueness of the term see chapter 1.1 "Is this HTML5?" it is used to refer to any recent improvement in -side web technologies this could be some API, or javascript optimizations developer of html5 game-engine Aves stated in his lecture that they do not use actual html5 stuff for most things javascript speed improvement important conventional html and css more efficient and convenient, as it has received lots of optimization over years html5 canvas used to parse images, not for rendering! Style of html5 Process

Lots of top down designs complex/common use easy simple/rare use hard For example video and audio: adding ogg vorbis file easy playing sine wave hard libraries, like dynamicaudio.js, help in transitional phase uses whatever present might end up using Flash if html5 API is not present used by jsmodplayer (music player) and jsnes (game console emulator) New File Interfaces

make it possible to read files into browsers memory without posting them to a server first also the other way around support for selecting multiple files at once in addition to the old fashioned file selector Web Workers

introduce multi threaded programming into the browser both good and bad sides of it user interfaces become more responsive you may get some good old threading problems Cross Origin Resource Sharing

Cross Origin Resource Sharing (CORS, makes it possible to do cross-origin services used together with XmlHTTPRequest (XHR) hosted 3rd party services for web pages simple, requires only setting a few http headers most importantly Access-Control-Allow-Origin: * postmessage

adds communication support between iframes may be used to build mashups pieces of content from different providers types of things you could do Facebook page with multiple app slots eat.fi restaurant site with embedded map might not be used in the said example services, as it is relatively new previously hard to do (see Subspace: secure cross-domain communication for web mashups ) WebSocket

make it easy to have a live message pipe from browser to servers simple API connect to a ws:// define callback onmessage use method send(string) browsersocket our work makes it possible to run a server from a webpage browser-to-browser networks "Offline" APIs

Application Cache offline sites possible Session Storage easy short term storage Local Storage easy longer term storage Database more advanced storage see forevercookie library identifies 15 means of storage uses 13 at the moment is self-healing Installable Webapps

Google Chrome WebStore "hosted app" v.s. "packaged app" extra permissions: notifications geolocation infinite storage pricing free, free preview, one-time payment, monthly fee (10% cut I think) Mozilla Open Web App Store an open alternative Browser Based

EyeOs hosted OS desktop UI model ChromeOS porting a browser to run on hardware benefits device independence (hardware failures do not matter) speed (no extra stuff to load) security (disk encryption, backups) no filesystem that eats files (only external disks) zero maintenance (true auto-updates) most importantly: my parents, not calling me because of some uninteresting OS issue Abandoning The Desktop

Flash Smokescreen, Adobe's Flash java-applets PPAPI, NaCl, PNaCl pdf in-built pdf-reader, or a web based pdf-reader media video/audio tags, free format webM legacy applications porting to NaCl, virtualization dependecy on complete legacy system remote desktop and ssh Semi-Open Questions

printing browsers do not know how to print without an OS requires lots of drivers solution: cloud print printing as a service home printers register with an online service makes printer access control easier offline use how does my computer know what I need while I am offline? what is a good for managing this? what should be deleted when disk becomes full? How About BrowserOS for Servers

virtual servers are trendy (e.g. Amazon Web Services) server are picking up javascript (see node.js) 1+1=2 running headless browsers in a data center might be the model of the future convenient programming model i.e. you just point your farm of computers to a page that defines server behavior claims made here, as well as earlier in this presentation, are highly unscientific. do not base your startup on them without knowing better :-) Go Explore!

also, questions?