Tutorial :Programming on Lift on Realtime - Is it possible?



Question:

I have been programming Rails and Lift for a while. Rails, said, a joy to work on. But Lift performance is too awesome to be ignored. However, I find building stuff inside Lift is way slower compare to rails. For example, whenever a change in Lift webapp is made, I need to request maven to recompile/retest the whole webapp (which is a really heavy overhead).

I wonder if there is something like realtime compilation (and test) tools that can be used for Lift?


Solution:1

SBT (aka "simple-build-tool") has a mode where the it will monitor the project's files and directories for updates, and will re-run the build and test of your project. This works by adding a tilde in front of the target:

$ sbt ~test  

I don't know how to get Maven to do this. For what it's worth, SBT uses Ivy for dependency management, and is itself Maven-friendly.


Solution:2

I'd simply use the scala:cc target and JRebel.


Solution:3

If you make maven work in online mode, it will always try to update or download missed plugins or POM which is not necessary. So when I already have the necessary dependencies, I make maven work in offline mode by appending "-o" in the maven command. That will save a lot of time, hope it helps.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »