<a href="javascript:mixpanel_track_link('http://liftweb.com/','link:liftweb.com');">my first encounter with Lift</a>Or they could use the google approach and change the link in the last moment to point to a tracking service.
That is also because using lift?
You should never put js in the href like this, or insert extra referral links prior to going to the real link as google have been doing recently; it breaks the web.
I'm in no position to say whether Yesod or Lift is better; I just wish more people would consider Haskell at all--it's a great choice for web programming (among many other things).
However, two things that I constantly bumped into maintaining a small Yesod app is that there was a fairly constant stream of API changes and that deployment on different machines was annoying because of version conflicts installing packages.
If you use Yesod, you are probably best off using a Cabal sandbox (e.g. via cabal-dev) and making specific package versions dependencies. Of course, that may be questionable from a security perspective.
I ended up rewriting that particular web app to Play, which offers some of the same benefits, but was a lot easier to deploy. You can create a stand-alone version of an application with play dist, which includes all the required jars, and the only thing required on a server is the Java runtime environment. Also, Maven/sbt seems a lot more mature than Cabal. As an added advantage, you can use tried and tested Java or can go all-functional via Scala.
I know fpcomplete use stackage for their School of Haskell[2]. This way, there is never any package dependency problem. Which gives them the incredible ability to execute yesod application directly on their server from the code of an user changing the code in the browser. If you haven't did it yet, you should really try it.
Also, concerning the deployment, having a single statically linked binary is very similar to having a single jar file. And this is very easy to deploy using heroku for example.
You can ask me more detail if you want to know how I deploy my application but this is mostly very well documented in the wiki.
[1]: https://github.com/fpco/stackage [2]: https://www.fpcomplete.com/school
But yeah, Cabal is certainly a bit of a pain. Happily, people are working on it. Superior cabal-dev functionality is going to be integrated into cabal proper very soon, if it hasn't already, for example.
Also, couldn't you just compile your binary with static linking and just deploy that? I understand there can be problems if you depend on certain non-Haskell libraries like GUI toolkits, but that shouldn't be an issue for a web app. I think a statically linked binary is pretty similar to a jar file in practice.
Having been using lift professionally for the last year or so, this is definitely my biggest complaint. I feel like Lift got it wrong here -- the *Var model is just hard to reason about. Our app has a lot of complicated logic to save and restore state at the appropriate times, and this model is supposedly the Right Way to do things.
> the fact that it supposes I don't know how to program HTML/JavaScript
Not sure why you say that; I've never gotten this feeling.
> the hostility toward Scala that Lift's creator harbors
Lift has 50 committers now. It's not going anywhere. If dickead maintainers were a real problem, nobody would be using glibc anymore. (I don't have any thoughts on whether DPP is a dickhead; I do think Drepper is, though :-)
One thing you didn't mention is the whole CssSel model combined with the way lift does templating. I think it's awesome, and hopefully I'll never have to work with another style of templating again in my life. (In fact, I wrote an implementation of it in haskell for my personal static site generator, because I love it so much: http://hackage.haskell.org/package/hquery </shamelessplug>).
I was reticent about statefulness on the server-side, until I read an article about statefulness in Lift[1], which does mention how having session affinity helps with it.
Mostly, my questions are: does it scale and how do you handle state loss (due to servers catching on fire or other hardware/software failures)?
You state "the server side statefulness of Lift" as a reason it would behoove people to avoid Lift, without bothering to explain why that is a reason to avoid Lift (it isn't--see http://lift.la/blog/lift-state-and-scaling). You state the language "supposes [you] don't know how to program HTML/JS" again without explaining how that is the case (it isn't--I am very good at both, and have never felt as much freedom to use those skills unfettered by server side concerns as I have with Lift; that's anecdotal, but if you make some specific complaints, I'll be glad to address them). And last but not least, you argue that David is hostile towards Scala without providing a single shred of evidence to support your statement.
In the future, it would behoove you to provide evidence for your claims.
I would definitely not pick Lift today for a new project.
as to why typesafe chose play over lift: they wanted to go with lift but dpp didn't want to work with them - didnt think it a wise decision. his explanation: http://www.quora.com/Lift-web-framework/Why-did-Typesafe-sel...
Well, this doesn't sound a lot better than him leaving the project.
Some of the main points are weak and don't really apply to differentiating Lift specifically. For example, the fact that Lift is Scala-based doesn't make it any different than Symfony is PHP-based or Spring MVC is Java-based. Subjective, but I definitely understand that that this is an opinionated view (rather than a objective "Lift has Feature X" viewpoint).
Similarly, what server-side framework that's in wide usage nowadays doesn't have the ability to have some form of generated/dynamic JS wiring? I'd say that's table stakes nowadays, not something to callout by any means.
I wish Clojure had a batteries included framework like this just to draw more attention to the language.
There is not enough documentation (by a large margin, even with the books, one example being the dozens of hooks you could hook into if they were documented), it's too complicated and there are a millions ways to do one thing.
That said the rendering and binding is the best way to do rendering I've seen yet. I'd wish this was easily usable with other frameworks. And Rogue (from foursquare) for Mongo on top of Liftweb persistence mapping is excellent. My understanding they will support things outside Lift in the future.
I was evaluating between Play and Lift and I ended up choosing....Lift. Lift has an extremely high barrier to entry mainly because of the poor documentation. When I first started off with scala, I didn't even know what the hell was SBT, when I downloaded Lift, there were a lot of things that were confusing - I was expecting perfectly organized folders just like ruby on rails, but everything was almost hidden/scattered. However this was the only barrier to starting up with Lift. I also did read about the controversies about the framework, etc [1]. of Lift, but honestly, none of them actually mattered to the developer, that is me. Now that I've chosen Lift, I think I made the right choice. Now, WHY is Lift better?
1) It's a 3+ year old Framework that is extremely stead-fast and stable, production-ready.
2) Scalability - This is a subjective view, but many high profile companies switch to Scala from Ruby/PHP/etc. when they need to scale. And Lift is a really good framework that gets the job done. [2][3]
3) Contrary to popular belief, once you cross the barrier to entry, it becomes much much easier to develop Web apps with Lift. Remember those wordpress days? How scary it was in the beginning to write custom themes and plugins?? But once you started writing a few, it felt like a breeze, right? That's what I'm talking about - That's exactly how Lift is too! [4]
4) Security - Security is hard. Sure you can write your Web app without using a framework. But if you use RoR, you will realize how much work is being done on behalf of you to make your app secure (Authenticity token, CSRF protection ,etc.) Lift is no different and it is one of the most securest frameworks I've ever worked with.[5] This is a very good guide explaining why you need to choose Lift over anything else.[6]
5) RoR vs Scala - Now, Imagine this scenario - You are a sculptor (web developer). You have two materials to choose from to create a statue (your web app). One is ordinary clay (Ruby on Rails) and the other one is a Metal, preferably some alloy made of copper and bronze (Lift). It is extremely easy to model your Statue (your web app) in Clay. And once you're done modeling, you can add some chemicals, or even thin layers of metal on top of it, etc. to make it strong (Think Unicorn, Phusion, etc). But, no matter what you do, the core is still made of clay and if you throw it down, your clay model will shatter into pieces.
Now compare it with the Bronze alloy (Lift). It is extremely hard to make a statue with it, but once you make statue with it, it's going to be so hard and robust, it can handle pressure (load) well - Even if you drop it, it might deform slightly, but never break. But, the disadvantage is that it takes too long to model a statue with this metal. However, you should decide if the trade-off in time is worth the effort in the long run. Of course everyone wants a nice status that is robust!
In the real world, you will probably be ok with RoR, but when you need to scale, you will realize the potential benefits you are missing out soon[7] - For example, if RoR can handle X requests/sec, and Lift can handle 10x requests per second, and assuming X requests require an Amazon box, then you save 9 boxes with Lift. That is huge savings for your start up, isn't it? I always wonder why people try so hard to scale RoR. It's a great framework, but the wiser thing to do would be to use something more efficient when you need to , than holding onto something that is less efficient because you like it. Also RoR has its own confusing terminologies (personal opinion). For example:
render json: @post
render :json => {:errors}
Notice the colons before and after the word 'json'.If you are interested in Scala, Coursera has a course on Learning Scala by Martin Odersky (The creator of Scala) and it is really good. Scala is not a purely functional programming language, which means if you are accustomed to programming in Ruby style, you can take it with you to Scala too.
[1]http://www.quora.com/Lift-web-framework/Why-did-Typesafe-sel...
[2]http://img.scoop.it/FP9bEzouSr7kRinQRAtGmDl72eJkfbmt4t8yenIm...
[3]http://www.quora.com/Why-did-foursquare-choose-Lift
[4]http://stackoverflow.com/questions/2573608/what-type-of-weba...
[5]http://seventhings.liftweb.net/security