Lift vs Rails

13 views
Skip to first unread message

jack

unread,
Aug 23, 2009, 10:45:39 AM8/23/09
to Lift
I am doing a startup company that involves both a lot of processing on
the backend (in the code) and a decent amount of comet/ajax in the
frontend.It is very important that the code quickly on the server. I
have seen the light with respect to Scala and Lift looks terrific. My
only concern is how new it is and the availability of resources
(programmers, books etc).

I really do want to use Lift instead of Rails. Could somebody please
convince me? :)

Derek Williams

unread,
Aug 23, 2009, 12:49:03 PM8/23/09
to lif...@googlegroups.com
On Sun, Aug 23, 2009 at 8:45 AM, jack <jack....@gmail.com> wrote:
I really do want to use Lift instead of Rails. Could somebody please
convince me? :)

I used to struggle with Rails (and to a lesser extent Merb) because it was difficult to do things that weren't the "Rails Way". Lift does have a recommended way of doing things as well but I haven't yet run into issues where I had to fight the framework in order to do things my way. This aspect along with the performance and ease of use makes it my preferred framework by far.

If you are not doing the coding yourself, finding a programmer might be an issue as experienced Scala developers (not to mention Lift developers) are probably much harder to find then Ruby and Rails developers.

As far as existing libraries, being able to use any Java library is a big plus. It can sometimes be hard to find a good (or maintained) ruby library in order to use an existing binary (C/C++) library.

The only thing at the moment that I would like to be better is Text Editor/IDE support. I don't find this to be too bad of a problem though as I spent all of my Ruby development struggling with the same things. I ended up using Vim for ruby development, and have now turned to Emacs for Scala development. For learning Scala I used Eclipse as it did a good job of giving me documentation for Classes/Methods. After a couple of months of coding I only have to reference the scaladocs once in a while as I find the language to be very natural. But these are issues that you will run into with Ruby development too, as getting good IDE support for a dynamic language can be even more difficult.

I'd recommend Lift for your project, especially considering you want to use plenty of Ajax/Comet. I never even considered using Comet in a web project of mine until I started using Lift. The only case where I might recommend Rails is if you are not a decent coder yourself and you aren't able to find a good Lift developer to work with.

Hope this helps

--
Derek Williams

marius d.

unread,
Aug 23, 2009, 1:08:24 PM8/23/09
to Lift
Looks like you don't need to be convinced :) ... Scala with its
features + Java compatibility + Lift's rich set of features +
performance of Scala & Lift makes it a no brainer. Enumerating all the
pros of Scala and Lift would just take way to long.


The list of Scala books and the Lift book are enlisted here
http://www.scala-lang.org/node/959

Br's,
Marius

David Pollak

unread,
Aug 23, 2009, 1:18:13 PM8/23/09
to lif...@googlegroups.com
Jack,

I started doing Rails in 2004.  At the time, there was one Rails book and a few Ruby books.  There had been a few RubyConf conferences and SD Forum had the first Ruby & Rails conference in Silicon Valley.  Ruby was mid-pack in the second set of the Tiobe index.

By those metrics, Lift and Scala are about 4-5 years behind Ruby and Rails.

From an operational standpoint, Scala and Lift are light-years ahead of where Ruby/Rails was in 2004... in fact, managing moderate to high traffic Scala/Lift sites is much easier than Ruby/Rails/Mongrel is today.  Because Lift and Scala can take advantage of every Java library, there is similar richness in the quantity and quality of external libraries.

Two year ago, Scala was virtually unknown.  At JavaOne this year, Scala and Lift books were 3 of the top 10 best sellers at the JavaOne bookstore.  Most Scala and Lift talks were standing room only.

As with every new technology, there are adoption risks, but I think Scala "crossed the chasm" this year at JavaOne and is entering the early mainstream phase.  Companies including Twitter, LinkedIn, SAP, OfficeDepot, etc. all have Scala in production.

I can put you in touch with a dozen high quality Lift/Scala developers... folks who are currently making their living with Java/Ruby/Obj-C, but would rather do Scala and Lift coding.  If you've got funding, I can find you good Scala & Lift developers.

Thanks,

David
--
Lift, the simply functional web framework http://liftweb.net
Beginning Scala http://www.apress.com/book/view/1430219890
Follow me: http://twitter.com/dpp
Git some: http://github.com/dpp

Meredith Gregory

unread,
Aug 23, 2009, 1:33:35 PM8/23/09
to lif...@googlegroups.com
Jack,

For my money Rails is somewhat more mature than lift, but lift is on a trajectory to overtake Rails feature-wise and is certainly already there performance-wise. The real issue, to me, is Scala vs Ruby. Quite apart from being more slightly more performant and equally expressive, the real win of Scala is its types allow you scale the code over time. What i mean by that is that a type system like Scala's allows you to
  • navigate code
  • substitute and refactor code while preserving properties
  • design for abstraction
One of the biggest problems of Ruby code -- and seasoned Ruby devs will tell you this -- is that in a code block of 10 lines -- that is part of say a 100K line project -- if i point to a line of code, you can't tell me what it is doing. This is compounded by the fact that with monkey-patching, even if you thought you knew, with the next check-in in some other part of the codebase, you don't.

In the same situation in Scala any given expression has a type that the compiler may infer. So, i don't need to know Joe Bloggs who wrote that block. i reason about what it does through the types. This gives better separation of dev teams -- not just code blocks. This is good if you want to scale up your efforts organizationally -- either by spreading it out over different groups working at approximately the same time, or by spreading development out over time. i'm not saying this is a silver bullet. Software is hard and there are always non-linear or cyclical dependencies, but types really help with practical development. After a while, you get to the point where you can design using types, and then cutting the code is like falling off a log. At this point designing for highly leveraged abstractions that significantly reduce the amount of code and increase the applicability of code is within your grasp.

The guy who makes these points in a much less zealous and much more reasoned, dispassionate way with lots of practical examples is Bill Venners. His recent talk for JavaOne -- which is on video (i'll look for the link) -- is quite powerful in this regard. Heck, even Charles Nutter, in his own blog acknowledges that Scala is the heir apparent of Java for the JVM.

Don't get me wrong -- i'm not a Scala biggot. There are a lot of corners of this language i don't like. For my money, Haskell is a better language. But, Haskell doesn't run on the JVM. You can't ship Haskell apps as jars or wars and smoothly hook them into maven repos, and you can't very easily build Haskell apps using standard JVM libs. So, that's why Scala, and that's why lift.

Well... there's also the fact that the Scala and lift communities are populated by very impressive people who are very open and incredibly responsive.

Best wishes,

--greg

On Sun, Aug 23, 2009 at 7:45 AM, jack <jack....@gmail.com> wrote:



--
L.G. Meredith
Managing Partner
Biosimilarity LLC
1219 NW 83rd St
Seattle, WA 98117

+1 206.650.3740

http://biosimilarity.blogspot.com

Jack Widman

unread,
Aug 23, 2009, 2:20:37 PM8/23/09
to lif...@googlegroups.com
Thanks Marius. I agree its a no brainer. Just wanted some independent confirmation!. 

Jack Widman

unread,
Aug 23, 2009, 2:24:06 PM8/23/09
to lif...@googlegroups.com
Thanks Greg. Your points on the compiler are well taken. A compiled language with higher order functions, general functional programming paradigms and all the rest that Scala has is great. I also like Haskell, but like you, I think the JVM and surrounding Java Culture, to the extent that it is useful for us is very valuable.

Jack Widman

unread,
Aug 23, 2009, 2:19:10 PM8/23/09
to lif...@googlegroups.com
Thanks Derek for the quick and helpful response. I am going to go with Lift. 

Jack Widman

unread,
Aug 23, 2009, 2:14:56 PM8/23/09
to lif...@googlegroups.com
This was just what I needed to push me over the edge. Actually I was there already and the biggest two reasons were a compiled, functional language and Lift's comet support.  Thanks for the quick responses everybody, and David, I will keep in mind what you said about developers. I am on the verge of getting funding. 
Reply all
Reply to author
Forward
0 new messages