I'm new to Scala but I do know JAVA. Can Scala projects be compiled into web apps and deployed to Webservers like JAVA?
Thanks!
Scala code is converted into byte code after compilation, hence yes it can be done.
here this should help for starting
Related
I am using JDT to get ASTs and type resolvers for Java sources in Eclipse, is there a way to achieve the same for Scala sources in Scala projects?
No, it is not possible to parse Scala with Java Development Tools. Scala and Java are two completely different languages. They have different syntax, different semantics, different type systems.
I am new to web development, but quite familiar with both Java and Python. In my beginning experiments with web development using Java, I discovered Apache Wicket; around the same time I also discovered Jython (v 2.5). I am wondering if there's a way to integrate Wicket and Jython so I can write Jython scripts instead of Java classes to use Wicket. So far I haven't been able to do that.
Ideas?
I don't see why not.
There are many people using Wicket successfully with Scala language. It should be the same with Jython, JRuby, Closure, ...
See https://github.com/wicketstuff/core/tree/master/jdk-1.5-parent/scala-extensions-parent for example with Scala.
I have PyDev set up in Eclipse to do Jython web development. Instead of using the Jython interpreter to handle my servlets I prefer to use the Jython compiler instead for a particular project I'm working on.
Within Eclipse I use Tomcat to test my web apps. The sort of process that I'm looking for is would be very similar to standard Java web development. I'd like to do something like;
Put my Jython scripts in the source folder.
Have the Jython compiler compile the scripts into Java classes when I republish to the Tomcat server.
Pretty much the same as if I would use Java but with Jython scripts instead. I'm having trouble setting this process up in Eclipse. What would be the best way to go about this?
Maybe you have a look at snakefight
How to make a standalone lift application? Which tools/libraries to use? How does the performance compare to using lift application as a war in some application server?
With onejar maven plugin http://onejar-maven-plugin.googlecode.com/svn/mavensite/usage.html and maven I could package jetty and project with dependencies inside one jar.
The part of the question on performance doesn't really fit with the rest. You are primarily asking how to package the Lift application as a single JAR/WAR. This doesn't have anything to do with the runtime.
At runtime you will still be running inside a Servlet container (could be Jetty, Tomcat or a full-blown Java EE server). How you package your application won't affect the performance.
You could take a look at Hudson (a great Continuous Integration Server) to see how they deliver as a single WAR file that contains an embedded Servlet container. You can download the WAR file and run it from the command line: java -jar hudson.war
I know this is an old question, but...
If you are using sbt, I wrote a plugin to produce 'executable' wars like those mentioned above.
https://github.com/glenford/sbt-jetty-embed
It seems to me that since GWT 2.0's development mode runs until your project is complete there is essentially no technical reason to run the actual Java->Javascript portion of the compiler when developing. Unfortunately in Idea 9 before your application server starts up the GWT compiler runs and the output is bundled into your .war. The server-side .java files are (somewhat) incrementally compiled when you do an Intellij "Make" but the GWT code always does a full compile.
Without resorting to writing my own build scripts is there a way to have Intellij not compile GWT code when I am developing and instead rely only on development mode?
You can use GWT Run configuration to start GWT in Dev Mode. In such case IDEA will not build war file so GWT compiler won't run.