Skip to: Site menu | Main content

Groovy 

      Download | Documentation | Developers | Community

An agile dynamic language for the Java Platform

latest posts from our mailing-lists Add comment to Wiki View in Wiki Edit Wiki page Printable Version

Latest messages from our mailing-lists

User mailing-list

Re: [groovy-user] Problem with Date()
It may be a bug but not with Date. 30*24*60*60*1000 ==> -1702967296 I thought we got numeric promotion in Groovy but obviously not. You can avoid the overflow by specifying a bigger type: 30*24*60*60*1000L ==> 2592000000 30*24*60*60*1000.0 ==> 2592000000.0 But that won't help because you can't add a number bigger than Integer to a Date: new Date() + 30*24*60*60*1000L ==> groovy.lang.MissingMethodException: No signature of method: java.util.Date.plus() is applicable for argument types: (java.lang.Long) values: {2592000000} Jim --- Wings - Why take the train when you can fly? http://IFCX.org --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-user] problems compiling with 1.6-beta1
I think, I localized the problem. I have class B that lives in a jar: package com.caiss.stat.modelImpl class B { static def b = 1 } when I compile A: package com.caiss.stat.chartModels class A { def f() { def t = com.caiss.stat.modelImpl.B.b } } I get the following error, when I compile both classes together the problem does not manifest itself compile: Compiling 1 source file to /home/yegor/caiss/caiss-stat2/beta2/chartModels/build/classes java.lang.NoClassDefFoundError: [Lorg/codehaus/groovy/runtime/callsite/CallSite; at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2395) at java.lang.Class.getDeclaredMethods(Class.java:1763) at org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:264) at org.codehaus.groovy.ast.ClassNode.lazyClassInit(ClassNode.java:219) at org.codehaus.groovy.ast.ClassNode.getInterfaces(ClassNode.java:306) at org.codehaus.groovy.a
[groovy-user] Problem with Date()
In groovysh: d = new Date() d1 = new Date(d.time + 30*24*60*60*1000) brings me back to the future !!! Looks like a bug ?
Re: [groovy-user] grep usage
So you have a list of items (java beans can be accessed the same way as maps)... def items = [ [id:1,name:'aaa'] , [id:2,name:'bbb'], [id:3,name:'ccc' ] ] items.grep{ it.id ==1 || it.id == 2 }.each{ println it.name } prints: aaa bbb 'it' is the default name of the current element in the closure's iteration. If you want to override this you can do: items.grep{ p -> p.id == 1 || p.id ==2 } -mark On Fri, May 9, 2008 at 3:06 PM, Vinny public.gmane.org> wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-user] Groovy exception when using sql server money datatype and zero value
Yeah, that's printf, although I get a different message with the IAE. A float formatter will take a float or BigDecimal, but not int. Conversions are divided into the following categories: General - may be applied to any argument type Numeric Integral - may be applied to Java integral types: byte, Byte, short, Short, int and Integer, long, Long, and BigInteger Floating Point - may be applied to Java floating-point types: float, Float, double, Double, and BigDecimal So if you use a floating point format you need to be sure to supply an argument with a decimal point. But when the Groovy SQL type conversions are being done, it sees the zero value and chooses Integer for the type. You can do it this way: db.eachRow("select testmoney from javaweb.dbo.money") { money -> printf "Money is %4.2f\n", money.testmoney as Float } or better for monetary amounts: db.eachRow("select testmoney from javaweb.dbo.money") { money -> printf "Money is %4.2f\n", money.testmoney as BigDecimal } But I
[groovy-user] GroovyWS: setting a string property through WSClient broken?
Hello, I am trying to use GroovyWS to send a simple bean over the network in a fashion similar to the BookService example. However, I seem to run into trouble if I try to set a string property on a bean object from the WSClient side. I can see the MessageBean object in my WSDL: *** WSDL portion *** Here is the bean object on the server side: *** MessageBean.groovy *** package dunphy.chris.messagechomper.to class MessageBean { String message long id } *** MessageBean.aegis.xml (same package as MessageBean class) *** Re: [groovy-user] problems compiling with 1.6-beta1
ok with only groovy-all jar in groovyc taskdef's classpath, I get the following error: Compiling 2 source files to /home/yegor/caiss/caiss-stat2/beta2/guide/build/classes java.lang.NoClassDefFoundError: org/codehaus/groovy/transform/ASTTransformationVisitor at org.codehaus.groovy.control.CompilationUnit.(CompilationUnit.java:155) at org.codehaus.groovy.tools.javac.JavaAwareCompilationUnit.(JavaAwareCompilationUnit.java:51) at org.codehaus.groovy.tools.javac.JavaAwareCompilationUnit.(JavaAwareCompilationUnit.java:47) at org.codehaus.groovy.tools.FileSystemCompiler.(FileSystemCompiler.java:53) at org.codehaus.groovy.tools.FileSystemCompiler.main(FileSystemCompiler.java:245) at org.codehaus.groovy.ant.Groovyc.compile(Groovyc.java:786) at org.codehaus.groovy.ant.Groovyc.execute(Groovyc.java:554) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) at sun.reflect.GeneratedMethodAccessor239.invoke(U
[groovy-user] grep usage
Ok, Newb question. Is it possible to use the groovy grep method to filter a javabean from a list based on the value of one of it's properties? Something on the order of : for(p in list.grep(p.ID == 111)) { print p } // The above code does not work btw. Thanks in advance
Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Ed Clark-2 wrote: It may still be true that specifying types can slow down a program - I haven't benchmarked this in a while. The overhead comes at assignment where you have to cast or convert the Object result of the expression to the target type of the assignment. You also get boxing/unboxing costs for primitive types. I would not be over concerned about this if I were you. There are lots of gains to be made in optimising the runtime system so your programs will get faster without you having to "optimise" them yourself. At some point the increased speed will begin to make this overhead a larger proportion of the execution time of your program and you can begin to worry about tuning the 5%-10% of your code which will make a difference. Personally I very rarely type a variable unless it's part of the interface to some Java code. John Wilson
Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Wow, I didn't expect that answer. How recent is "very recently"? is there a penalty in 1.5.6? Was this due to things like extra type checking on assignment? Anything targeted to 1.6? Just wondering whether to start being more thorough in specifying types. Although I had said that I think it's a good idea to specify types, I'm also quite lazy ;-) and tend to leave them off if there's no performance payoff (especially if there's a penalty). Ed Clark --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-user] RFE: Add withWriter and withOutputStream to URL/URLConnection
Marc, Looks interesting to me. On the "response" part, it may be nice to have a way to specify the handling of the different final response codes: - being able to retry on (some) 5xx responses (after some specified delay), - being able to select the "best" next hop on a 3xx response that has a redirection list, - error handling of 4xx or 6xx responses (e.g., using an alternate URL), - maybe even being able to say how to handle login challenges (tho' I'm not to sure how easy it is to detect those) Ed Clark Marc Palmer wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Ed Clark-2 wrote: Until very recently using static typing frequently made the program slower. Now the Groovy runtime is getting faster it's likely that in future using static typing (especially if the type is a primitive) will make the program run faster. I have an experimental dynamic runtime which executes expressions almost twice as fast if the types of the variables are known and are primitive, John Wilson
Re: Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Peter Niederwieser wrote: I believe the original motivation to allow optional typing was to allow proper integration with Java. If you can declare the parameter and return types of methods then you can easily and clearly subclass Java classes and implement Java interfaces. Declaring typed properties make it easier for Java classes to use the properties. At one point there was an intention to use the declared type of a variable (rather than the actual type of the variable's value) to select methods but that seems never to have been implemented. My general rule of thumb with Groovy is to make anything which is likely to be seen from a Java program typed and declare everything else untyped. Like all rules of thumb there are exceptions, of course! John Wilson
Re: [groovy-user] RFE: Add withWriter and withOutputStream to URL/URLConnection
On 9 May 2008, at 15:28, Marc Palmer wrote: Actually, how would people feel about a HttpRequestBuilder? It could do stuff like this: def url = new URL("http://someserver.com/rest_api/dosomething") def req = new HttpRequestBuilder(url) req.post { headers { "Content-Type" "application/xml" Host "someserver.com" "User-Agent" "Groovy request builder 1.0" } // body("Something inline here") // -or- render using markupbuilder body { write '' someRoot { someNodeA("The value here") someNodeB("The value here") } } // -or- set url request params, automatically application/x-url-form or whatever it is encoded //params { //userId = "10494894" //authToken = "DFJKHJHEFKJHFKJHEFKJHFK" //} // read response with either Reader or InputStream depending on arg type in closure withResponse { InputStream stream -> assert headers.'Content-Type' == "application/xml" assert status == 200 // delegate to an object with access to headers.*/status e
Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Just curious - are there any performance benefits to specifying the type, either compile time or run time? I know that some languages can speed things up if given some type hints. (Given the extra dynamic nature of Groovy, there may be none.) I do think there are other benefits to explicitly typing, e.g. adding that little bit of additional info to make the code easier to read and understand. Ed Clark --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-user] dif between def obj = new MyObject() vs MyObject obj = new MyObject()
Peter Niederwieser schrieb: my bad... both declare a local variable (when done in a method or script), only if you use MyObject, then Groovy guarantees you that any value assigned to foo will be at last of class MyObject at runtime. If this rule is violated, then Groovy will throw a runtime exception when the assignment is done. Since the root of all classes is Object using Object won't do anything special. "def" can be seen as alias for Object atm. bye blackdrag
[groovy-user] RFE: Add withWriter and withOutputStream to URL/URLConnection
Hi, Using URL to POST is not really made any easier by the GDK it seems. How about we add withWriter/withOutputStream to URL/URLConnection? We could probably put them on URL and make it set the http method to POST on the url connection internally. Marc --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
[groovy-user] Cygwin support in the native launcher
Hi! I and Russel Winder were able to implement support for cygwin style paths in the native launcher. Please see http://groovy.codehaus.org/Native+Launcher#NativeLauncher-Pathsoncygwin The support is a little experimental, so it is not included in the prebuilt binaries on the wiki page or in the windows installer, i.e. you have to build the binary yourself. Instructions can be found on the wiki page. Note that you do not need to build the native launcher in cygwin in order to have cygwin support (but you can, of course). Please note that the "cygwin" version of the native launcher works as normal native launcher when used outside cygwin, i.e. uses normal windows paths. Someone asked for cygwin support a long time ago. If anyone actually uses this, please drop me an email and tell me how it works for you. And please report any issues (there are none known ATM). -::Antti::-
Re: [groovy-user] Invalid method code length
Bug submitted: http://jira.codehaus.org/browse/GROOVY-2816. I attached the file to the bug. Thanks, Chuck Alex Tkachman wrote:
Re: [groovy-user] with(..) method does not work properly in scripts
Jochen Theodorou wrote: If we were to change the resolving strategy then the behaviour in a class would change. It's entirely possible that this would then break existing code. I think we just have to live with the fact that some stuff just doesn't work in scripts. John Wilson
Re: [groovy-user] FactoryBuilderSupport question.
Danno, When I returned to my code I found that I had tossed it to get something else done. Once I recreated it, everything seems to be happy. I have forgotten to wire something up properly in one of the factories. Anyway, thanks for the offer to help. Looks like I'm in good shape for now. Thanks, Dave Danno Ferrin wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email

Developer mailing-list

Re: [groovy-dev] Syntax highlighting
Shrimp wrote: No idea what Eclipse function you're describing here. CTRL+Enter in what context? Looking through the Keys preferences I don't see any binding that uses this combination. Perhaps this is a custom binding? If so knowing the name of the command would be helpful.
[groovy-dev] JDK 5 vs 6 with Eclipse IDE plugin: Bad version number in .class file
I've tried the "stable" release of the Eclipse plugin as well the as dev version (as of today) and they are both exhibiting this same problem: I create a new Java project, add a groovy source folder, create a file, run it via Run As Groovy. All's well. Then I make a change and try running it again only to find that the plugin didn't recompile. Annoyed I right click on the file in the Package Explorer and select "Compile Groovy File" (not sure why this option exists.) In response I get an error dialog that says: An internal error occurred during: "Compiling selected Groovy files.". Bad version number in .class file Once this occurs Eclipse starts acting horribly flakey. Various menu items including Run As menu item won't draw. If you try running the groovy class through the Run As dialog you get a NoClassDefFoundError. It's pretty awful. I am developing on MacOS (Leopard.) Eclipse will have nothing to do with Apple's 64 bit JVM (all that 32 bit Carbon code, I guess) so it's running on a Java 5 JVM but I
[groovy-dev] invokedynamic: Is It What We Really Need?
Here are my thoughts on invokedynamic proposal http://groovyland.wordpress.com/2008/05/09/invokedynamic-is-it-what-we-really-need/ Alex --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] GroovyClassLoader recompile problem
No just point to the same resource file.lastModified() return "0L if the file does not exist or if an I/O error occurs" No file.lastModified() never throws an exception -> it returns 0L are you sure?? As far as I can see the Source URL that is parsed to the method might not be pointing to the same resource as the original location where found. when the source url is constructed the assumption seams to be that String somestring URL u1 = new URL(somestring); URL u2 = new URL(URLDecode(somestring, ENCODING) will point to the same resource, and that is a wrong assumption! This fails on windows, and do not have any guarantied behavior -> But the following should be guarantied on all platforms: File f = new File("/tmp/?+?") assert f.createNewFile() == true URL url = f.toURI().toURL() f = new File(url.toURI()) assert f.exists()==true or simply keeping the URI. I still don't see why all the explicit decoding/encoding takes place, It should not be needed at all File should be
Re: [groovy-dev] startGroovy.bat
I have already made a number of suggestions, but no-one picked up on them. I think the best bet is for me to make the changes in a branch rather than just change trunk and then put a patch up on JIRA for people to vote on and if approved apply -- a professional approach to changing trunk ;-) The only problem is that I haven't been able to take a Bazaar branch of Groovy as yet. I am hoping to be able to do this next week then I can put it up somewhere public so that anyone can branch it. I (and anyone else) will then be able to branch as and when the whim takes them. I will need to find somewhere to host the mirror branch as it is likely to be 120MB and my server is on the end of an ADSL line. I may look at hosting it on Launchpad as Codehaus is not yet set up for handling Bazaar branches. Once we have the branch Paul and I can also experiment with replacing Commons CLI 1.0 with something sensible.
Re: [groovy-dev] startGroovy.bat
Russel Winder schrieb: [...] well, instead of assumptions how about making a suggestion? bye blackdrag
Re: [groovy-dev] startGroovy.bat
Possibly, but the way it works at the moment severely restricts the reusability of the script. I think that startGroovy and startGroovy.bat can be tinkered with slightly to make them far more efficacious for launch scripts other than groovy and groovyc. There are built in assumptions that the scripts will all be in $GROOVY_HOME and that $GROOVY_HOME/lib/groovy*.jar is the groovy jar. I don't think it would take much rearrangement to make them far more flexible and therefore usable by groovy-based systems that are not colocated in $GROOVY_HOME.
Re: [groovy-dev] Problems with GroovyLexer
Klenk Michael schrieb: I am not sure.... but there is probably some special code in the parser, that prevents this problem from happening. Since I am not really an antlr user I don't know for sure. bye blackdrag
Re: [groovy-dev] startGroovy.bat
Russel Winder schrieb: STARTER_CLASSPATH is thought as internal variable, not as something from the outside. bye blackdrag
Re: [groovy-dev] GroovyClassLoader recompile problem
Hans Lund schrieb: the most important fact that you should ensure is, that the configuration used for this class loader has the recompilation enabled. Without that nothing will happen. So for the following I guess it is enabled. true, with the name as key and the code source or url as value does it need to be the same URL? this is fine as long as the file is still found. let's say the class you want to recompile is originally a source file in the file system, then usually the protocol is file. source.getPath() will return the path to the file... so either the path is encoded wrong, then file.lastModified(); will cause an exception, or it works. If the other path is taken, then the URL methods are taken... if that does not work, then it is a bug in URL So besides having a potential problem in URL itself, we have the encoding problem. Of course I can run a script like this one: File f = new File("/tmp/?+?") assert f.createNewFile() == true URL url = f.toURI().toURL() println url.path f =
Re: [groovy-dev] Grail subproject
because of the hell you have to go through every time you have a situation where non-standard setup is needed (and that happens quite often for me). Maven is a pain in the ass. The amount of time you waste on shit does not really matter at the end is just ain't worth it. I like maven's ideas I think their implementation is just plain crap. I can't wait to give Gradle a try. Thanks, Alex. --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] Grail subproject
Hi, (...) Sure, Maven seems to be a good choice. So what's stopping people from using Maven for Groovy Modules nowadays? Or Groovy itself by the way (it's a bit outdated) ? MD --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] Grail subproject
Hi all, (This is my first post on Groovy list... though I've been on Grails list for a while) IMHO, since Groovy is a JVM language, and all Java libraries are accessible, and Groovy based libs accessible to java (provided all dependencies are met) - why not just use Maven's repository as the centralized repository of stuff? Why do we need to invent another repository? - Brian On Wed, May 7, 2008 at 9:35 AM, Miguel Duarte public.gmane.org> wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] Grail subproject
GPAN = Groovy PAckage Network. Frankly, I don't care much about the name :-) There are other things I would like to discuss though. - How to implement dependencies from jars and other modules implemented in groovy - Reuse maven? - How to implement module testing (in CPAN, modules are only installed if they pass the test suite, unless you force installation) - Module and Core Groovy Documentation should be accessible from the command line (something like perldoc would be really handy - Perl has really good documentation) - Modules should be managed (installed, upgraded and removed) using a command line tool (...) --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] Grail subproject
CPAN stands for the "comprehensive perl archive network." The analogous thing would be the "comprehensive groovy archive network" or CGAN. But we don't need to be strictly analogous, did you have another acronym in mind? Best, Martin Miguel Duarte wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
[groovy-dev] Problems with GroovyLexer
Hi all, I'm writing at a SourceCodeFormatter for the Groovy Eclipse plugin. As help to analyze the file for formatting it afterwards i use the GroovyLexer to parse the document. This works very well. But i came across a suspicious error. If i parse a string with a $ included, the Lexer got an exception. The code is running Groovy Code which can be executed with no problems. Here is a small groovy scipt to reproduce this exception: original groovy File ------------------------- def i = 5 println "i: $i" Test groovy script which throws an exception with the following output: ------------------------- import org.codehaus.groovy.antlr.parser.GroovyLexer import antlr.Token def code = 'def i = 5\nprintln "i: $i"' GroovyLexer lexer = new GroovyLexer(new StringReader(code)) Token token = null while ((token = lexer.nextToken()).getType() != Token.EOF_TYPE) { println(token) } ------------------------- ["def",<81>,line=1,col=1] ["i",<84>,line=1,col=5] ["=",<120>,line=1,col=7] ["5",<194>,line=1,col=9] ["<
Re: [groovy-dev] Syntax highlighting
Yaa the plugin is installed properly and I got syntax highlighting also after doing some settings in eclipse. Now the issue is how to go back to the called function with CTRL+Enter like we do in java applications. Thanks glaforge wrote:
[groovy-dev] Problems with GroovyLexer
Hi all, I'm writing at a SourceCodeFormatter for the Groovy Eclipse plugin. As help to analyze the file for formatting it afterwards i use the GroovyLexer to parse the document. This works very well. But i came across a suspicious error. If i parse a string with a $ included, the Lexer got an exception. The code is running Groovy Code which can be executed with no problems. Here is a small groovy scipt to reproduce this exception: original groovy File ------------------------- def i = 5 println "i: $i" Test groovy script which throws an exception with the following output: ------------------------- import org.codehaus.groovy.antlr.parser.GroovyLexer import antlr.Token def code = 'def i = 5\nprintln "i: $i"' GroovyLexer lexer = new GroovyLexer(new StringReader(code)) Token token = null while ((token = lexer.nextToken()).getType() != Token.EOF_TYPE) { println(token) } ------------------------- ["def",<81>,line=1,col=1] ["i",<84>,line=1,col=5] ["=",<120>,line=1,col=7] ["5",<194>,line=1,col=9] ["
Re: [groovy-dev] Grail subproject
Well, it's not "my" project to rename it :-) I don't even know the current status of Grail. I just wanted to contact those who were proposing to do it to get things going. But I agree with Grail being a bad name. I would vote on GPAN (CPAN is really great, so It doesn't hurt to borrow a few ideas from it) On Wed, May 7, 2008 at 2:21 PM, Daniel.Sun public.gmane.org> wrote: --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
Re: [groovy-dev] Grail subproject
The name 'Grail' is too similar with 'Grails', which is a full-blown framework based on Groovy. If you want to contribute the project, I suggest it's nice to rename the name of the project. Best regards, Daniel.Sun Miguel Duarte-3 wrote:
[groovy-dev] Grail subproject
Hi! I've discovered groovy about 5 months ago, and I've been quite happy with the experience. Congratulations to everyone involved! The only thing that fell that it's missing is some sort of a groovy package manager, something like CPAN. Grail (http://groovy.codehaus.org/Groovy+realtime+archive+internet+lookup) seems to have been discussed, but it seems that progress has stalled. I would like to contact the person responsible for Grail, since I would be willing to contribute to make it happen. MD www.linkedin.com/in/malduarte --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email

JSR mailing-list

Groovy 1.5.6 is out!
Hi all, G2One and the Groovy development team is pleased to announce the release of Groovy 1.5.6, a bug fix release for the stable Groovy 1.5.x branch. A regression introduced in 1.5.5 was fixed, and 35 bugs have been resolved (generics, MOP, and joint compiler issues, better line information for IDE support, etc) As usual, you can download the latest Groovy dustribution here: http://groovy.codehaus.org/Download And read the change log to know all the details there: http://jira.codehaus.org/browse/GROOVY?report=com.atlassian.jira.plugin.system.project:changelog-panel Enjoy!
Fwd: final Groovy JSR?
Wasn't delivered. ---------- Forwarded message ---------- From: Bill Shannon public.gmane.org> Date: Sat, Apr 5, 2008 at 12:40 AM Subject: Re: final Groovy JSR? To: Guillaume Laforge public.gmane.org> Cc: jsr-241-comments-vP450+ZD9pU< at >public.gmane.org, Groovy JSR public.gmane.org> Guillaume Laforge wrote: But what if the library is compiled by Foo's Groovy compiler and my program using the library is compiled by Bar's Groovy compiler? You have to decide whether this is important and/or likely. I agree you can probably ignore this for the first version. Will this get any easier in Java SE 7 with the new dynamic language bytecode?
Fwd: final Groovy JSR?
Wasn't delivered. ---------- Forwarded message ---------- From: Bill Shannon public.gmane.org> Date: Fri, Apr 4, 2008 at 11:59 PM Subject: Re: final Groovy JSR? To: Guillaume Laforge public.gmane.org> Cc: jsr-241-comments-vP450+ZD9pU< at >public.gmane.org, Groovy JSR public.gmane.org> Guillaume Laforge wrote: Yes, exactly. I think it would be better if you did, but it's up to you to decide. You're allowed to make that choice. It's up to your expert group to decide whether that's a good choice. Personally, I think this might be acceptable for a first release, but long term it will limit acceptance of Groovy. But you should work through the scenarios for how you expect people to use Groovy to see if it will be an issue for you. For example, do you expect people to write libraries using Groovy, which they would distribute as jar files? We include them in the TCK User's Guide. Let me f
Re: final Groovy JSR?
Yes, for sure, conceptually speaking, this would be desired. For Java, this is simpler as a call to a method is directly encoded in the bytecode. No intermediary layer of indirection. It then just depends on the runtime part (JDK classes, third party libraries, etc) But for a dynamic language, in the bytecode you'll find some calls to utility classes handling the double dispatch. Some of them are public APIs (which will be part of the JSR), but others may be present that are specific to each implementation. So we'll have to think deeper as to what we really want to make portable or not. Tricky issue :-) Right. This has always been possible (as long as you have the Groovy runtime on your classpath). We can seamlessly integrate with Java, or any other alternative language for the JVM. But the problem comes when we have to be compatible between different implementations of Groovy. At the basic object level, things are just fine, but it's when you get into metaprogramming techniques that this may be more prob
Re: final Groovy JSR?
Bonjour Liz, On Wed, Mar 26, 2008 at 11:37 AM, Liz M Kiener public.gmane.org> wrote: Alright, I saw it. It'll take me some time to get the EDR finished, and it won't be before JavaOne. Yes. Yup, I saw that, this is handy. Merci beaucoup :-)
Re: final Groovy JSR?
Hi Bill, Thanks a lot for your explanations. I haven't been able to answer earlier, I'm sorry. Some comments inline. On Sat, Mar 22, 2008 at 8:24 PM, Bill Shannon public.gmane.org> wrote: What do you mean by language/compiler portion, and runtime portion exactly? I just want to be sure I understood correctly. For the language part, we need to explain the semantics of the language, its grammar, etc. For the runtime part, you mean things like the libraries? ie. a closure class, a GString class, etc. Is that what you meant? Okay, it's up to us to decide the level of integration the spec mandates or not for a language to be considered a valid Groovy implementation. Furthermore the TCK will help ensure this. Ok, that makes perfect sense. Back on the level of integration mentioned above, and on this portability / interoperability aspect, Groovy mandates a seamless integration with Java. But does it mean we'd also mandate a perfect interoperability with other Groovy implementatio
Re: final Groovy JSR?
Hello Bill, On Fri, Mar 21, 2008 at 7:25 PM, Bill Shannon public.gmane.org> wrote: Very good question. Actually, after a long period of hibernation on the JSR front, we're resuming work on it in the upcoming months. But we'd be happy to have some guidance to the steps to follow, and details of the key deliverables that are expected to ship with the JSR. So far, the RI is there, of course, in the shape of Groovy 1.5.4. The TCK is not split from the Groovy test suites, so we'd need to find an easy way for people to reuse it if they want to develop a compatible Groovy language. On the spec side, we have the language grammar in an EBNF and diagram form, but what is still missing is the writing of the formal specification document, beyond our online documentation or the books we've written on the topic.
Re: [groovy-dev] Tentative Roadmap
On Dec 17, 2007 10:25 AM, Alexandru Popescu ? gmail.com> wrote: You're welcome :-) At least, it's not in contradiction with the roadmap! Agreed, this is what the 1.5.x releases are for. It's going to be a long process I suspect, as various experiments will have to be done, lots of discussions, a nice general proposal of what we really want, etc. So it's something that is going to be done in parallel to the progress we make in 1.x. I tried to put certain features at certain milestones, but we can certainly reorder the priorities. I've put multiple assignments early in the roadmap because we had promised them in 1.1/1.5, but as they're certainly not critical, we can postpone them to a latter release, it's not really critical. In the new features, there are things which should be discussed for inclusion or not. For instance, anonymous inner classes, nested classes and co. Initially, in the early days of Groovy, we didn't want to support them because we found them ugly, and
Tentative Roadmap
Dear Groovy developers, Now that we have released 1.5, it is time to think about the future of Groovy, by discussing its roadmap. After some discussions at GDC#4 ( http://docs.codehaus.org/display/GroovyJSR/GDC4+Discussions), on the lists, and elsewhere, we've listed possible improvements and new features. Jochen and myself compiled a tentative roadmap this weekend, taking these ideas into account and trying to lay them out across potential release numbers. This is a tentative roadmap. Certain features can be discussed, whether we do want them or not. And there's room for moving features from one to another release. New ideas missing can also be introduced. So it's still pretty open at the moment. Note that the roadmap can change across the course of time according to the progress (or lack thereof) we make on the GEPs (Groovy Extension Proposals). It is not set in stone today, even after our upcoming discussions. The GEPs will drive us through the releases. It is very important that we try to clearly de
What's new in Groovy 1.5?
Hi all, After the announcement of the release of Groovy 1.5, as promised in the release notes, here's a detailed article on what's new in Groovy 1.5. Read it on InfoQ: http://www.infoq.com/articles/groovy-1.5-new
Groovy 1.5 is there!
Hi all, I'm very pleased to announce the release of Groovy 1.5. You can read the release notes there: http://docs.codehaus.org/display/GROOVY/2007/12/07/Groovy+1.5+released An upcoming article on InfoQ will give you a more in-depth overview of this new version. Thanks a lot to everybody: developers, contributors, users. Without you, Groovy wouldn't be the great dynamic language it is today.
Release candidate 2 is available!
Dear all, The Groovy development team and G2One , the Groovy & Grails company, are happy to announce the new milestone of Groovy: the second release candidate is here. Just a few weeks after the first release candidate, this new version focused mainly on bug fixing, ironing out the Swing console with a nice new icon toolbar and the interactive shell, and the XML handling. You can have a closer look at the JIRA issuesfor more detailed information and you can download Groovy 1.1-rc-2 from the usual place. Apart from these bugs and little improvements, we kept on increasing the performance of Groovy. As an informal benckmark, we measured the time taken by our test suites to run, and for instance, according to the Grails team, the Grails test suites executed about 40% faster with Groovy 1.1-rc-2 than with Groovy 1.1-rc-1, of course, depending on your project
Groovy 1.1-beta-3 released, RC-1 and 1.1-final around the corner
Dear Groovy friends, I've blogged about the new here: http://glaforge.free.fr/weblog/index.php?itemid=222&catid=2 and there: http://docs.codehaus.org/display/GROOVY/2007/09/20/Groovy+1.1-beta-3+released%2C+RC-1+and+1.1-final+around+the+corner But here it is: Groovy 1.1-beta-3 is there, paving the way for an RC-1 in the following weeks, and if all goes well, for 1.1-final in October, right in time for the Grails eXchange conference that takes place in London. This conference will also be the opportunity for the Groovy developer team to meet for the fourth Groovy Developer Conference! With Groovy 1.1 released by then, it'll be time to think about what's going to happen for the next major version of Groovy. Before going through the new release, let me recap some of the nice things that have been happening lately around Groovy: * JetBrains released a second milestone to the wonderful Groovy & Grails IntelliJ IDEA plugin, so be sure to check it out, as you'll feel at ease developing Groovy with all the
how to make new specification request.
i'm working in web application projects using JSF . i'm asked from team manager to write "module specification request" for every web module. can anybody tell me what the content of any specification request document.
how to maike
get scripting engine by file extension
Hello! I have an application where I use JSR-223 for evaluating the scripts, and I use file extension for identifying the scripting engine that is required to evaluate the script: ScriptEngineManager scriptEngineManager = new ScriptEngineManager(); ScriptEngine engine = scriptEngineManager.getEngineByExtension("groovy"); With groovy-1.0 it works fine. but with groovy-1.1-beta2 this code throws a following exception: Exception in thread "main" java.lang.IncompatibleClassChangeError: Found interface groovy.lang.MetaClass, but class was expected at com.sun.script.groovy.GroovyScriptEngine.( GroovyScriptEngine.java:63) at com.sun.script.groovy.GroovyScriptEngineFactory.getScriptEngine( GroovyScriptEngineFactory.java:87) at javax.script.ScriptEngineManager.getEngineByExtension( ScriptEngineManager.java:275) at And in the version 1.0 there really was "public abstract class MetaClass" which is now "public interface MetaClass extends MetaObjectProtocol"
Groovy 1.1-beta-2 released!
Dear community, The Groovy team is pleased to announce the release of Groovy 1.1-beta-2, yet another step on our aggressive roadmap towards the release of Groovy 1.1 in October. For this release, I would like especially to highlight two key contributions to the project: * First of all, after we've added Java 5 annotation support in Groovy 1.1-beta-1, this time, it was generics' turn. Thanks to the help of some JBoss developers who've integrated Groovy in JBoss Seam, we've been able to test our support for annotations and generics, and to make sure we would release a quality milestone to our users. Groovy is the first alternative dynamic language for the JVM that supports annotations and generics, so that you can integrate Groovy with any Enterprise application frameworks like EJB 3 / JPA, JBoss Seam, Google Guice, Spring, etc. * Secondly, I'm very happy to report the contribution of JetBrains to the development of Groovy. While working on the IntelliJ IDEA plugin for Groovy and Grails, the talentu
Groovy 1.1-beta-1 released with annotation support
Dear all, After Groovy was awarded the first prize of the JAX conferencein Germany last week for being the *most innovative and creative project in 2007 in the Java community*, we're pleased to announce the *release of Groovy 1.1-beta-1*. This release is the first beta release after the release of Groovy 1.0. But it's a very important release as we've been working on key features putting Groovy clearly as the *de facto enterprise scripting solution*. Indeed, Groovy is now the first and sole alternative language for the JVM that *supports Java 5 annotations*. Groovy 1.1-beta-1 also supports Java 5 *static imports*. You can now use Groovy to write your EJB 3 / JPA beans, to wire your components with Google Guice, to mark your services transactional
Re: Fwd: JavaOne EG Meeting Room
Will there be any conference phone facilities, as I'll be in the UK that day Jez.
RE: Fwd: JavaOne EG Meeting Room
I'll be there and happy to meet everybody. Guillaume, I guess I'm not yet an official member of the JSR expert group. Would you mind promoting me so? ;-) cheers Dierk --------------------------------------------------------------------- To unsubscribe from this list please visit: http://xircles.codehaus.org/manage_email
Fwd: JavaOne EG Meeting Room
For those who will be at JavaOne this year (Groovy / Grails developers and JSR EG members), we might have a room to make a quick meeting at the Argent hotel if needs be. ---------- Forwarded message ---------- From: Liz M Kiener public.gmane.org> Date: Mar 22, 2007 6:36 AM Subject: JavaOne EG Meeting Room To: SPECLEADS-vP450+ZD9pU< at >public.gmane.org Hello All - The PMO is pleased to offer you once more this year a room at the Argent Hotel for EG meetings during JavaOne. The room will be available all week until Fri 11 May on a first come first served basis. You can schedule the room by sending me email with date and time you would like. Kind regards, Liz :-)