baq haidri j rubyifying linked in's front-end

13
JRubifying LinkedIn’s Front-end http://www.linkedin.com/in/baquera http://sna-projects/sna

Upload: marakana-inc

Post on 16-Apr-2017

2.854 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Baq haidri j rubyifying linked in's front-end

JRubifying LinkedIn’s Front-end

http://www.linkedin.com/in/baquerahttp://sna-projects/sna

Page 2: Baq haidri j rubyifying linked in's front-end

[“iterate rapidly”, “re-use code”, “jvm”, “hire ruby people”, “have fun”].each { |important_thing| important_thing.capitalize!}

Page 3: Baq haidri j rubyifying linked in's front-end

require ‘background’

Page 4: Baq haidri j rubyifying linked in's front-end

homepage

profile

inbox

service

service

service

front-end back-end

Page 5: Baq haidri j rubyifying linked in's front-end

JRuby

Existing full-featuredcustom Java web application frameworkusing Spring MVC anda custom JSP compilerdeployed to Tomcat

?

Page 6: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request- production webapps deployed as wars

Page 7: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVC

- security- authentication- tracking- service layer

Page 8: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVCSiteMesh

- 3rd party open source library- header, footer control

Page 9: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVCSiteMesh

JRuby-Rack- bridge between Servlet and Rack- customized LinkedIn Rack servlet for special case error handling- control transferred via named dispatcher

SiteMesh

Page 10: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVCSiteMesh

JRuby-RackSiteMesh

Sinatra- custom service DSL for making asynchronous backend calls (based on protobufs)- custom Sinatra extensions that wrap Java framework fxnality:---> url generation---> logging---> authentication---> resource formatting

Page 11: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVCSiteMesh

JRuby-RackSiteMesh

Sinatraget ‘/hello’ do

erb :layoutend

<html> <head>

<title>Hi</title></head><body>

Hello from JRuby!</body>

</html>

Page 12: Baq haidri j rubyifying linked in's front-end

Tomcat < Servlet API

Request

Custom LinkedIn Filters + Servlet < Spring MVCSiteMesh

JRuby-RackSiteMesh

Sinatraget ‘/hello’ do

erb :layoutend

<html> <head>

<title>Hi</title></head><body>

Hello from JRuby!</body>

</html> Response

Page 13: Baq haidri j rubyifying linked in's front-end

require ‘demo’