lift introduction

32
Dave Briccetti @dcbriccetti Indrajit Raychaudhuri @indrajitr

Upload: indrajit-raychaudhuri

Post on 29-Jan-2018

1.383 views

Category:

Technology


0 download

TRANSCRIPT

Page 2: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Page 3: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

• Secure

• Interactive

• Designer Friendly

Page 4: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

• Secure

• Interactive

• Designer Friendly

• Scalable

Page 5: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

• Secure

• Interactive

• Designer Friendly

• Scalable

Super Easy !!

Page 6: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

About Us• Dave Briccetti

• Veteran software developer

• Teacher in love with programming

• Indrajit Raychaudhuri

• Active Lift committer

• Hacker trying to do programming

Page 7: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project

Page 8: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project• Started by David Pollak (@dpp) in 2006

• Community (> 3000 members in ML)

• Committers from around the world

• Stable master philosophy

Page 9: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project

• Developers ≠ Plumbers

• Best concepts from other frameworks

Page 10: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project

Page 11: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project• Open Source (Apache 2.0 License)

• Ready on a JVM near you

• Full Java EE compliance

• Works in all modern servlet containers

• Batteries included (user replaceable)

Page 12: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

The Project• Best implementation on JVM for

Comet Ajax

REST Templating

Page 13: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Secure Lift

Page 14: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

• Definitive strategy tackles OWASP Top 10

• So you don’t have to bother

Secure Lift

Page 15: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

• Definitive strategy tackles OWASP Top 10

• So you don’t have to bother

Secure Lift

“.name *” #> “<script>alert(‘hi’);</script>”

Page 16: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift

Page 17: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

Page 18: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

serve { case "api" :: "user" :: AsLong(id) :: _ XmlGet _ => <b>ID:{id}</b> case "api" :: "user" :: AsLong(id) :: _ JsonGet _ => JInt(id) }

Page 19: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

Page 20: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

// HTML<div class="lift:FetchTicker?parallel=true">  Ticker server #1: <span class="ticker">The Ticker</span></div>// Snippetobject FetchTicker {  def render = {    Thread.sleep(500 millis) // The call    ".ticker" #> Thread.currentThread.getName // The result  }}

Page 21: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

Page 22: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Interactive Lift• Great support for Comet and AJAX

• Great REST Support

• Parallel Rendering of Snippets

• Lazy Rendering of Snippets

// HTML<div class="lift:LazyLoad">  <span class="lift:LongTime"> I started this computation at    <span id="start">start</span> and it    completed at <span id="end">end</span>.  </span></div>// Snippetobject LongTime {  def render = {    val start = now    Thread.sleep(randomLong(15 seconds))    "#start" #> start.toString &    "#end" #> now.toString   }}

Page 23: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Designer Friendly Lift

Page 24: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Designer Friendly Lift• Step 1: Get designers to write pure XHTML, HTML5

• Step 2: There isn’t any!

Page 25: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Scalable

Page 26: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Scalable• Fast path for handling REST/Ajax/Comet

• No additional layers (e.g. bolt-on security)

• Foursquare and UK Guardian serve millions of pages a day with Lift

Page 27: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Summary• Tremendously secure

• Highly Interactive Web apps simple

• Very friendly to designers

• Successful large scale deployments

Page 28: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Resources• Source [github.com/lift]

• Books

• Simply Lift [simply.liftweb.net]

• Exploring Lift [exploring.liftweb.net]

• Wiki [wiki.liftweb.net]

• Mailing List [googlegroups.com/group/liftweb]

Page 29: Lift Introduction

Scala: A Quick Primer

Page 30: Lift Introduction

Copyright © 2011 Lift Web Framework, Worldwide Conferencing, LLC

Smarter Java• Runs on JVM, interoperated with any JVM language

• Functional (and OO too!)

• It’s a lot easier than you think

• Stories from the trenches

Page 31: Lift Introduction

Demo: TalkingPuffin Web

Page 32: Lift Introduction

Questions?