Google App Engine Adds Java Support, Groovy Meta-Programming
Zarf writes "Yesterday Google announced that the Google App Engine now supports Java development, and fast on the heels of the Java announcement is an announcement for Groovy support! Groovy is a dynamic programming language for the JVM that is a near super-set of Java. Much Java syntax is valid Groovy syntax, however, Groovy adds powerful meta-programming features, and the new functionality will bring these meta-programming features to App Engine development. Groovy got special attention from the SpringSource Groovy team and the Google App Engine Java team, and it was this collaboration that helped create the changes that were the big secret in the recent Groovy release of 1.6.1."
This really opens the floodgates for cloud computing. I can't wait to port to this platform.
But Groovy is NEW! And new is better! Just ask any developer!
There's no -1 for "I don't get it."
Reading TFA, it looks like a scalable servlet container. No J2EE as far as I can tell.
Well, it's biggest advantage is that it is a language written to run on the JVM*. You can talk to Java classes when you need to, but it's really a dynamic language that Java developers can easily learn and use. Type can be strong or weak depending on what you want/need, you can write Groovy unit tests against Java code, etc.
*of course there's Jython, but Groovy was designed from the ground up to be used by Java developers.
Reviewing just the first hour of video games.
Running Ruby using Jruby on Google AppEngine.
http://blog.bigcurl.de/2009/04/running-sinatra-apps-on-google.html
Should get you started.
java is extremely efficient so I have no idea what you're talking about. It's far more efficient than python which is the original GAE platform. I know it's fashionable to bash java on /., but you should at least know what you're talking about. Or, are you suggesting that everyone write their web apps in C?
Just goes to prove that Python is the best language ever. Clearly you don't ever need to learn anything else. I strongly encourage you to not learn Groovy as it would poison your mind.
Obviously there's nothing the JVM has to offer you.
[signature]
http://olabini.com/blog/tag/gae/
In fact, you should thank ThoughtWorks guys for several of the recent blog posts on GAE involving JRuby, Groovy and also Clojure.
Well it would be a great improvement over t
Segmentation Fault
I can't believe you don't know what a Hasemalphaginnojinglanaporphomism is.
Incorrect. The Servlet platform imposes those restrictions already, with the container handling all the messy details of threading and networking. It works just fine in 90%+ of the cases.
Javascript + Nintendo DSi = DSiCade
I'm not sure I fully understand the reason for Groovy? I've read a lot of the documentation, but it doesn't answer the fundamental question ... as a java developer, why would I learn this language when I can just use java? Is it just for the new language features? Can someone illuminate?
Java is my main language, but I definitely see the value in Groovy. For instance, how do you pass functions or other code blocks around in java? You either use very clumsy and verbose anonymous inner classes, or.. or nothing. Groovy handles this gracefully.
Basically Groovy is a scripting language that lets you use java classes. It's not really much different than Jython or JRuby, it's just more java-like in syntax.
While your two links are interesting, I think you have to do more work to make your point. Can you cite why those links prove the superiority of Python? And what specifically do you mean by 'rewrite the bible'?
Regarding efficiency, I give you this. The relevant sentence: "I decided to redo several of the tests with updated versions of Python (2.5) and the JDK (Java 6). And indeed, my suspicions were confirmed: Java has made huge speed improvements, and is now faster than Python in almost all cases."
[Ego]out
Let me just say that you don't need to rewrite the bible every time you want to do any operation on python (or pretty much any other language)
Compare this http://code.google.com/appengine/docs/java/datastore/dataclasses.html
with this: http://code.google.com/appengine/docs/python/datastore/entitiesandmodels.html
Yes, because it's so hard to use the 2 click, automated IDE function to generate all those getters and setters. They aren't required by the language, btw, just for encapsulation. You know, that thing that's one of the selling points of OO.
You write exactly as much code as you do in Python, autogenerate convenience methods (getters, setters, toString, etc.), and end up with your beans. Besides, who cares how hard it is to write a bean class. This isn't exactly the core effort during app development, now is it? How many awesome libraries are there in Java for things like IOC, data access, web frameworks (MVC and otherwise)? There's piles and piles. Are some of them stinkers? Yes, but there's tons of robust, usable, and EFFICIENT frameworks out there. There's tons of free stuff, free app servers, free IDEs, free plugins, free libraries. Some of the best stuff in development was written in Java first (e.g. JUnit, Spring, etc.). This stuff is so good it's been ported to other platforms.
And to boot, the "slow and bloated" Java arguments are belied by the sheer volume of apps out there that are written in Java and you likely have no idea. Check out the networking portion of your favorite MMO game, it's likely written in Java, server side. Tons of banking software is written in Java once you get past the big iron portion. Tons of sites on the web are as well. Some of the biggest, custom forums in the world are Java (WOW forums are).
Yeah, the GP was right, you are ignorant, and don't seem to know what you're speaking about.
Surely there is a way to make Java even less readable than Groovy. Maybe make the entire language pure regular expressions or allow every character including the . to be an object.
One outcome of Sun's future liquidation is that no-one is around to promote the 1 Jesus language & Java ends up fragmenting into thousands of derivatives like Linux or Fortran.
Anyone who has ever maintained perl will tell you that it isn't always the best idea to give programmers the choice of how to do things. If there is a right way, don't give them the option of doing it the wrong way, because many will do so. And if two ways are equally good, just pick one--there's no reason to give people an option!
A slashdotter who didn't build his own computer is like a Jedi who didn't build his own lightsaber.
*shrug* I'm not convinced that Java is all that more complicated or time-consuming for the developer. And since 1.6, with annotations and generics, I'm not sure that the complaint about inflexibility is really there.
Suffice to say, I don't think that Python is the crystal clear choice. On the other hand, I'm not sure the differences are significant - so it probably is up to your coding (team's?) preference and style.
[Ego]out
df -h
Still funny.
Groovy is to Java as PERL is to C. Many similarities, plenty of points of comparison, some interactivity, arguably some interchangeability. It is not a "super set" or even an extension. It's a new language, written in another language. It's a scripting tool, written in Java, that optionally generates Java for execution not in a Groovy engine.
It doesn't give you "compiled Java" any more than Java gives you compiled Java, and other tools (like gjc) give you native executables from software written in Java.
It's got good. It's got bad. It's new. It leverages old. If you're going to use it, you've got to learn it.
No magic, just different.
End the FUD
Does this Groovy implementation mean now the end of Jython? If Groovy is so "Pythony", is there a real need to further develop Jython?
What are the relative advantages/disadvantages of Groovy over Jython?
"Sum Ergo Cogito"
Clearly in the context of processor efficiency. So now you're claiming that my use of java instead of jvm in the context of processor efficiency leads to a logical reply about poor java libraries?
I know most people that are reading at this point think I should drop this, but I'm endlessly fascinated at the lengths people will go to avoid admitting any form of mistake or oversight.
And the jvm is far more efficient than python. The stuff done with the jit is very impressive.
My beef is with the amount of code that has to be written, and the inflexibility of Java.
You just build a class on python, few includes, you're done. Not like Java. Also, no Expando in Java.
There's Expando in Groovy. And Groovy seeks to remove a lot of the syntactic clutter of Java. Read a Groovy book or intro and you'll see its benefits; it's got a lot (most) features of Python/Ruby, etc., while using and being completely compatible with Java.
Dynamic languages are gaining popularity extremely fast for a whole host of reasons. If you haven't used a dynamic language then you probably won't understand why they are attractive very easily, but if you have it will probably seem obvious. They do have a lot of downsides and I think the jury is still out to some extent whether the reams of code now being written in them is going to be maintainable down the track.
Groovy is Java made into a dynamic language and with innumerable convenience features added. The best way to describe it is to imagine if java was turned into Ruby.
I suspect one reason Google has focused on it is because of Grails, which is java's main player in the RAD web-app development arena (more or less the equivalent of Django, which they also support for the Python app engine). It doesn't work on App Engine yet, but I strongly suspect that is where they are headed.