Wednesday, July 26, 2006

OSCON 06 Day 3 - Afternoon Sessions

Session 1
Driving Rails Deep into the Back Office
Fernandez

Financial presures to reduce costs are big.
Be ready for the build vs. buy decision because it will come up.
Obstacles: "good enough" legacy systems, BI tools, reporting packages/
Better and faster in rails? Yes!

One idea: the trojan application.

The Race approach: parallel or same teams do the same project in rails and java/.net/whatever.

The Pilot: do a small bit of an app as a proof of concept.

The Rescue: catch a failing project and redo it in rails

The Undercut: (risky) Come it, and because you're so productive you can do it in far less time than other solutions.

Case Study:
the "PCS" Project
-Small team
-Three months
-Replaced homegrown PL/SQL solution
-DSL-centric solution

Lesson 1: optimize and raise your levels of abstraction
How? Know what each piece of the stack does and doing a custom DSL.

Lesson 2: Rails really breathes life into XP
All the benefits of XP really click with Rails.

Lesson 3: Don't sweat performance and scaling. Most back-office sysmts have relatively few users.



Session 2
Streamlined
Stuart Halloway
Relevance LLC

In the beginning, there was ruby and rails...
Along came Streamlined, which replaces the basic scaffolding.

Streamlined is generates pages with a basic stylesheet, ajaxified creation/edit/update/delete, on the fly filtering of all fields, sort by clicking column headers, export to csv/xml,

New 'app/streamlied' directory that contains view code (that looks amazingly like rails models). It picks up object relationships from the rails models, and reflects them in the ajaxy goodness. But the new streamlined directory contains all the view-related stuff and putting it in one place. All the views (.rhtmls) are generated and fully open to being customized. If there's no customization, it

All the CRUD stuff gets refactored from each and every controller up to the streamlined_controller. All are overridable if need be. Or, if deleted entirely, there's an automatic fallback to a functional generic version.

Streamlined is Alpha
0.02 is out now
0.03 is out next Monday


Streamlined produces:
-Production-ready Enterprise scaffolding.
-Generic enterprise CRUD
-Simplicity of ActiveRecord for views and controllers

Generator options fall into 3 categories:
-semantic (--no-relationships, --no-views)
-look (--no-header, --no-about)
-theme (css=vendor.css or whatever)

UI Options
-relationship - choose view and summary
-user_columns - which columns to display

Licensed under MIT license.

Download http://www.streamlinedframework.org/
Documentation: same place
Submit patches: http://collaboa.streamlinedframework.org/

Things to look at:



Session 3
Ruby for Java Programmers
Ugo Cei

Why?
-Leveraging exsiting Java libraries, source and infrastuctre

How?
-RubyJavaBridge http://arton.no-ip.info/collabo/backyard/?RubyJavaBridge
Works best if you wrap Java methods in simpler wrappers.

  • No mappomg for ruby iterators on java collections.

  • No date convertors

  • Weak ejb getter/setter property converters.



-SWIG - http://www.swig.org/
Jakarta POI, nifty library for manipulating Microsoft OLE2 Office fiiles uses SWIG to provide Ruby bindings. (http://jakarta.apache.org/poi/poi-ruby.html)

-JRuby - http://jruby/codehaus.org
Not a bridge, but a 100% Java interpreter written in Java
Gives ruby access to all Java libraries.
No access to ruby extensions in C
"Almost" able to run RubyGems and Rails
Quick Development pace.
Still slow compared to C Ruby, but quoting Charles O. Nutter "I think it's now very reasonable to say we should beat C Ruby performance by the end of the year."

  • Can use ruby "each" on Java collections

  • Data type conversions

  • Full support for JavaBean properties


Using the IRuby interpreter, you can call Ruby methods from Java.

-XML-RPC - It's possible to run the java and ruby process independently and enable them to communicate.

-SOAP - It's possible to run the java and ruby process independently and enable them to communicate.

Slides at http://www.sourcesense.com/transfer/ruby_for_java_programmers.pdf

-Bill

Tags: , OSCON06, , , ,

No comments: