Ur/Web: A Simple Model for Programming the Web. Adam Chlipala MIT CSAIL POPL 2015 January 15, 2015

Similar documents
Ur/Web, a Domain-Specific Functional Programming Language for Modern Web Applications. Adam Chlipala

Ur/Web Programing Language: a brief overview

Advance Mobile& Web Application development using Angular and Native Script

STARCOUNTER. Technical Overview

JAVA COURSES. Empowering Innovation. DN InfoTech Pvt. Ltd. H-151, Sector 63, Noida, UP

Oracle - Developing Applications for the Java EE 7 Platform Ed 1 (Training On Demand)

Comet and WebSocket Web Applications How to Scale Server-Side Event-Driven Scenarios

DDS Connector Sept, Gianpiero Napoli, Senior Software Engineer

Java SE7 Fundamentals

Ten interesting features of Google s Angular Project

Copyright is owned by the Author of the thesis. Permission is given for a copy to be downloaded by an individual for the purpose of research and

CSC 309 The Big Picture

PHP. MIT 6.470, IAP 2010 Yafim Landa

Full Stack Developer with Java

HTML5 Evolution and Development. Matt Spencer UI & Browser Marketing Manager

Surrogate Dependencies (in

Varargs Training & Software Development Centre Private Limited, Module: HTML5, CSS3 & JavaScript

Project Horizon Technical Overview. Steven Forman Principal Technical Consultant

Web 2.0 and AJAX Security. OWASP Montgomery. August 21 st, 2007

Project Horizon Technical Overview. Bob Rullo GM; Presentation Architecture

Enterprise Software Architecture & Design

Index LICENSED PRODUCT NOT FOR RESALE

Web Applications. Software Engineering 2017 Alessio Gambi - Saarland University

MarkLogic Server. Reference Application Architecture Guide. MarkLogic 9 May, Copyright 2017 MarkLogic Corporation. All rights reserved.

Active Endpoints. ActiveVOS Platform Architecture Active Endpoints

The NoPlsql and Thick Database Paradigms

RKN 2015 Application Layer Short Summary

Nick Terkay CSCI 7818 Web Services 11/16/2006

PROCE55 Mobile: Web API App. Web API.

Full Stack boot camp

Intelligent Performance Software Testing

Tooling for Ajax-Based Development. Craig R. McClanahan Senior Staff Engineer Sun Microsystems, Inc.

<Insert Picture Here>

Kaazing Gateway: An Open Source

Migrating traditional Java EE applications to mobile

CNIT 129S: Securing Web Applications. Ch 3: Web Application Technologies

JavaScript Context. INFO/CSE 100, Spring 2005 Fluency in Information Technology.

Web Technology for Test and Automation Applications

Web Robots Platform. Web Robots Chrome Extension. Web Robots Portal. Web Robots Cloud

Rich Web Applications in Server-side Java without. Plug-ins or JavaScript

Rich Web Applications in Server-side Java without. Plug-ins or JavaScript

Developing ASP.NET MVC Web Applications (486)

Module 6 Node.js and Socket.IO

Interactive XML Visualization - using XSLT 2.0 on the Browser. Phil Fearon - Saxonica

Top 10 AJAX security holes & driving factors

Web Client Architecture Guide

Qt for Device Creation

Deploying to the Edge CouchDB

DATABASE SYSTEMS. Database programming in a web environment. Database System Course, 2016

Lesson 14 SOA with REST (Part I)

Web Application with AJAX. Kateb, Faris; Ahmed, Mohammed; Alzahrani, Omar. University of Colorado, Colorado Springs

Comprehensive Angular 2 Review of Day 3

86% of websites has at least 1 vulnerability and an average of 56 per website WhiteHat Security Statistics Report 2013

Transactum Business Process Manager with High-Performance Elastic Scaling. November 2011 Ivan Klianev

MATLAB as a Financial Engineering Development Platform Delivering Financial / Quantitative Models to the Enterprise Eugene McGoldrick

Chapter 10 Web-based Information Systems

Oracle APEX 18.1 New Features

02 - Distributed Systems

20480C: Programming in HTML5 with JavaScript and CSS3. Course Code: 20480C; Duration: 5 days; Instructor-led. JavaScript code.

Shankersinh Vaghela Bapu Institue of Technology

Full Stack Web Developer Nanodegree Syllabus

An Overview of. Eric Bollens ebollens AT ucla.edu Mobile Web Framework Architect UCLA Office of Information Technology

02 - Distributed Systems

Java EE 7 is ready What to do next? Peter Doschkinow Senior Java Architect

Database Driven Web 2.0 for the Enterprise

20486-Developing ASP.NET MVC 4 Web Applications

"Charting the Course... Comprehensive Angular. Course Summary

Advance Dotnet ( 2 Month )

Homework 8: Ajax, JSON and Responsive Design Travel and Entertainment Search (Bootstrap/Angular/AJAX/JSON/jQuery /Cloud Exercise)

Send me up to 5 good questions in your opinion, I ll use top ones Via direct message at slack. Can be a group effort. Try to add some explanation.

Apex TG India Pvt. Ltd.

COMET, HTML5 WEBSOCKETS OVERVIEW OF WEB BASED SERVER PUSH TECHNOLOGIES. Comet HTML5 WebSockets. Peter R. Egli INDIGOO.COM. indigoo.com. 1/18 Rev. 2.

GRITS AJAX & GWT. Trey Roby. GRITS 5/14/09 Roby - 1

Networking & The Web. HCID 520 User Interface Software & Technology

Architectural Styles I

Integration Test Plan

Enterprise Web based Software Architecture & Design

Real-Time SignalR. Overview

All About Open & Sharing

Implementing a Numerical Data Access Service

Stencil: The Time for Vanilla Web Components has Arrived

Modern and Responsive Mobile-enabled Web Applications

RESTful APIs ECS 189 WEB PROGRAMMING. Browser s view. Browser s view. Browser s view. Browser s view. Which will It be for photobooth?

Develop Mobile Front Ends Using Mobile Application Framework A - 2

IBM Workplace Web Content Management and Why Every Company Needs It. Sunny Wan Technical Sales Specialist

Development of web applications using Google Technology

Editor - Project Browser

Networking & The Web. HCID 520 User Interface Software & Technology

Best Practices. For developing a web game in modern browsers. Colt "MainRoach" McAnlis

10/18/2017. Announcements. NoSQL Motivation. NoSQL. Serverless Architecture. What is the Problem? Database Systems CSE 414

Featherweight Firefox

Standard 1 The student will author web pages using the HyperText Markup Language (HTML)

Etanova Enterprise Solutions

HTML5 - INTERVIEW QUESTIONS

Master Project Software Engineering: Team-based Development WS 2010/11

Azure Integration Services

Adobe ColdFusion (2016 release)

Flex 3 Pre-release Tour

Introduction to Web Application Development Using JEE, Frameworks, Web Services and AJAX

Project Zygote. Rapid prototyping for the Internet of Things

Transcription:

Ur/Web: A Simple Model for Programming the Web Adam Chlipala MIT CSAIL POPL 2015 January 15, 2015

Ur / Web Ur A new general-purpose typed functional language λ Web Tools for implementing modern three-tier web applications Motto: the compiler understands the structure of your web app. Focuses on: Programmer productivity Security Performance (especially server-side, for scaling) 2

There are at least several users whom I have never met! The first commercial Ur/Web application: BazQux Reader, by Vladimir Shabanov Feed reader with comments http://www.bazqux.com/ On the order of 1000 paying users daily 3

TechEmpower Web Framework Benchmarks <http://www.techempower.com/benchmarks/> 3rd-party benchmarking initiative 93 frameworks in test to the right Ur/Web's performance: 4th best throughput (~100 krps) Best latency (2.1 ms) At the top of the chart in the preview results for the next round 4

This is reasonably real. You can download it and build some nifty Web apps. Open source at: http://www.impredicative.com/ur/ Bonus talk content: 1) Background: a general model for programming distributed applications 2) Background: the mess that is today's mainstream Web development techniques 3) Ur/Web's simpler model for programming Web apps, with 2 big ideas: a) Encapsulation that crosses nodes of a distributed system b) A simple concurrency model for distributed systems 4) Code demo 5

Distributed Systems (Hard) Node Message Message (look of mistrust) Message Node Message Node Message Node Message Node 6

Why Distributed Systems? Physics forces distribution in space to scale performance. Mutually distrusting users controlling distinct resources Challenges: Mutable state Concurrency Security 7

The Restricted Model of Many Web Apps Simple communication topology: only edges are between server and clients Server Most optimization work focused on server, especially for scaling Client Thin client : most client Centralized security: server state is ephemeral. under tight control; clients can do whatever they want. We don't care if troublemakers corrupt their own state, and server state is behind an API. Client... Client flashy UI flashy UI flashy UI 8

What Web programmers expect today Web Server SQL Database HTTP, HTML, URLs HTTP, HTTP, URLs XML/ JSON HTTP, XML/JSON Browser All represented as normal strings in most frameworks! Hello, code injection attacks! Browser Browser... Browser AJAX! JavaScript The DOM (a big old mutable global variable, modified by looking up nodes by string ID) Comet (long polling) or WebSockets 9

The Ur/Web model An application is written entirely in Ur/Web source code, exposing this view: Typed message-passing channels stored in DB and passed to clients. Strongly typed SQL syntax tree Web Server Database write Browser... List of records of native Ur values Key point: semantics says First-class Strongly typed First-class Native Ur Key value point 1: threads are spawned requests are contains run one at function a time to Native Ur value in Ur/Web code and themselves document (the tree standard transaction function to run on server run Ur/Web code. abstraction). run on server Browser Browser (marked as AJAXstyle) read Thread Thread... Thread Key point 2: client-side threading Document is cooperative, with thread... Mutable switches cells only at well-defined points (a natural choice in function for rendering based on contents JavaScript). (functional-reactive GUI style) 10

Big Language Design Idea #1: Encapsulation What should we encapsulate? Server Module encapsulating bits of state across the system [On server:] Database tables RPC endpoints Message-passing channels [On client:] Subtrees of a client-side page Cookies (persistent store) Client Client... Client flashy UI flashy UI flashy UI 11

Threads Big Language Design Idea #2: Concurrency Server may also send Later, server runs it messages RPC goes to other into clients, a queue atomically and places and all deliveries on the server. re: the result back on client. same RPC appear to happen atomically. Semantics A thread ends is that, its cooperative any time, slice just with one certain thread actions, is running like across an RPC the to whole the server. system! Client f(a) f(a) Server Big Idea: Semantics presents the illusion that just one thread is running at a time, across the whole system! c User interactions may trigger creation of new threads. Client... Client b flashy UI flashy UI flashy UI 12

Demo time! 13

λ Open source at: http://www.impredicative.com/ur/ 14