Charles Nutter Presentations

Post on 15-May-2015

813 views 0 download

Tags:

Transcript of Charles Nutter Presentations

JRuby on RailsCharles Oliver Nutter

Agenda•Who Am I

•What Is JRuby

•Why JRuby on Rails

•Demos

•What Now

•Conclusion

Who Am I•Charles Oliver Nutter

•Senior Staff Engineer at Sun Microsystems

• JRuby Core Developer

•Rubyist wannabe living in a Java world

•Based in Minneapolis, Minnesota, USA

Why Go To Sun?

•Work full-time on JRuby

•Opportunity to make real progress

•Sun folks get it, want Ruby to succeed

•Java folks need Ruby

Why Stay in Minnesota

What Is JRuby•100% Java impl of Ruby...Ruby on

the JVM

•Pure interpreted, native threaded

•Born 2001, product of many developers

•Largely Ruby 1.8-compatible

•Slower than Ruby...for now

Ruby calling Java• require ‘java’

include_class “javax.swing.JFrame”include_class “javax.swing.JButton”

frm = JFrame.new(“My frame”)btn = JButton.new(“My button”)

frm.set_size(300, 300)frm.content_pane.add(btn)frm.show

Ruby calling Java• include_class \

“java.awt.event.ActionListener”

class MyListener < ActionListener def actionPerformed(event) event.source.text = “New text” endend

btn.add_action_listener(MyListener.new)

Why JRuby on Rails•Java is pervasive

•Java libraries are exhaustive

•Many still believe Java is the “everytool”

•Java webapp developers are unhappy

•Rails webapp developers are happy

What do Rails Devs Get•Scads of libraries; if you need it,

there’s a lib

•JDBC - universal database support

•“Good” EE stuff: clustering, failover, deployment, remote management

•Extensive monitoring capabilities

•A gateway to the “enterprise”

What do Java Devs Get

•A web framework that’s usable

•A useful schema management tool (finally)

•Markup that doesn’t suck

•Four extra days per week

•Happiness

Depot 2ActiveRecord-JDBC to MySQLRails integrated with Java EE

Java Management Extensions (JMX)

What Now: Short Term

•Fix broken bits

•Marshal-based session

•Interpreter bugs

•Performance

•Script-based Java EE/Java library support

What Now: Long Term• Implement remaining C extensions:

Mongrel, SSL, others you’d suggest?

•Continue expanding ActiveRecord-JDBC

•Abstract out schema definition

•Solidify automatic CRUD support

•More GUI tool support

Conclusion• JRuby on Rails mostly works right now

• JRuby will not be “done” until it’s fully working

•ActiveRecord-JDBC opens many doors

• Java EE is actually fun with Rails

•More Rails is more Rails...JRuby enables!

Information•Email: charles.o.nutter@sun.com

•Blog: headius.blogspot.com

• JRuby: www.jruby.org

•ActiveRecord-JDBC and Mongrel-Java: rubyforge.org/projects/jruby-extras

•More JRuby at RubyConf and JavaPolis