News from Grailsland

The past

Last year November Martin Adamek and me started to work on a full-featured set of modules to support the Groovy programming language and the grails application server. After being quite impressed (and a little bit depressed) about the feature-set of the Intellij Groovy/Grails plug-in, we wanted to create something similar for NetBeans.

One key responsibility of all OpenSource projects is to carefully look around what's already out in the world. Re-use of existing sourcecode and/or leveraging existing libraries is a given in this culture. Therefore we started off our work by using the existing, but inactive coyote plug-in. Doing a language plug-in. with an extensive feature-set comparable to the Intellij plug-in. goes way beyond the scope of the otherwise very helpful Schliemann framework.

This left us with the cumbersome tasks of coding everything from scratch against the NetBeans Editor API. Luckily we soon discovered Tor Norby's GSF Framework. GSF's purpose is to help creating exactly what we were about to create - A new scripting language support module. GSF really achieves this goal and has been one of the reasons, why we are able to develop so many features in such a short period of time.

Here are the modules and there main duties:

groovy.support

Collection of helper- and utility classes alongside the Customizers.

groovy.editor

Editing Groovy sourcecode files. All the bells and whistles like syntax-highlighting, folding resides here.

groovy.gsp

Support for editing Groovy server pages files (GSP).

groovy.grails

Here's all the code interfacing with an ex-process grails server. Architecture-specific execution of the "grails <target>".

groovy.grailsproject

Support for the new NetBeans project type "Grails-Project" together with all visual components like Wizards, Actions, Node-renderers and the like.

groovy.kit

Wrapper module for the ones above to show-up as a single entity in NetBeans PluginManager.

The present

Installation

NetBeans 6.1

Initially we started in NetBeans old CVS trunk which soon became NetBeans 6.0. We soon realized, that we need to use some new API's, therefore the suite of modules needs NetBeans 6.1 as a minimum.

Binary

Please use the daily snapshots from the NetBeans source-repository continous integration system (Hudson), which can be found here:

deadlock.netbeans.org Builds

By using these builds, you are going to get all the pre-configured development UpdateCenter which include our modules. 

Source

... Or work with the NetBeans sources from the mercurial repository:

hg.netbeans.org

and build it yourself (it is easy!, No really it is, no one forced me to write this.)

Here's a great description, how to do this:

 WorkingWithNetBeansSources

The Modules

Binary

The Plug-ins are available from the UpdateCenter, therefore just go to:

Tools > Plug-ins > "Available Plug-ins" > "Groovy and Grails"

and install them.

Source

The sourcecode for the Groovy/Grails modules lives in the "contrib" repository:

contrib repository webinterface 

there are six subdirectories starting with "groovy.\*".

If you build them in this order:

  1. groovy.support
  2. groovy.editor
  3. groovy.gsp
  4. groovy.grails
  5. groovy.grailsproject
  6. groovy.kit

using ant:

ant -f groovy.\*/build.xml

you have them automatically up and running the next time you start NetBeans.

Screenshots

So what are you getting by using these modules? Pictures entering the stage:

  1. Method-completion including JavaDoc display for Groovy and Java:



  2. Code Folding of Groovy sourcfiles:



  3. Starting, stopping of Grails-Server:



  4. Importing existing Grails projects. Well arranged display of project structure:



  5. Groovy/Grails module settings integrated into NetBeans options dialog:



  6. Marking of sourcecode errors:



  7. Easy navigation of Groovy sourcecode by using a navigator view:



  8. Customizing of Grails Environment and Serverport. Auto-deploy to Glassfish Appserver:



  9. Starting common grails-tasks from context menu:



  10. Status of running grails server displayed in status-line:



  11. Syntax Highlighting:



Participation

I would love to get feedback about this project. No matter how much planning one is doing, at the end of the day the software should be used and should be usable for real live users. Therefore I'm bleeding to get your feedback. What you like, what you don't like, what you think we should implement. Ideally, you file your bugs and wishes right where they will end-up anyway and that's the NetBeans issue-tracking system Issuezilla.

We have our own Component-name which is (you guessed it): "groovy".

The Issuezilla landing page could be found here:

NetBeans Issuezilla 

The future

There are still many, many things missing from the modules. Depending on the interest, people are showing for the initial release ( we won't make it into NetBeans 6.1 ), these are candidates
for features of the next release:

  1. Debugging support. (yes - it's sad but true, that we have no debugging support at the moment)
  2. MultiView for easy navigation between corresponding Model-View-Controller files.
  3. Refactoring support.

Links:

Kommentare:

Matthias,
Nice write-up. Congrats on the progress.

Gesendet von Cynthia Hardenbrook am März 20, 2008 at 09:58 AM MEZ #

good job.

maybe the people should vote for their favorite issue. So the community have more influence to implementation order.

greetz
Christian

Gesendet von Christian Schleif am März 20, 2008 at 02:26 PM MEZ #

Great news. It's sad, that it will be not available for NetBeans 6.1. Would it be possible to create a development version of the plugin which is compatible with NetBeans 6.1? Or even better with 6.0?

Keep up the good work!
Stefan

Gesendet von Stefan am März 20, 2008 at 02:41 PM MEZ #

good job
Keep up the good work!

Gesendet von ChinaBoy am März 20, 2008 at 08:26 PM MEZ #

on Windows xp I have trouble

Gesendet von china boy am März 21, 2008 at 11:16 AM MEZ #

@Stefan: oops, i didn't made myself clear enough: We won't be shipped as part of 6.1, but work perfectly fine in 6.1.

The Problem is only, that you don't see the Grails modules in the update centers pre-configured in the 6.1 Beta but only in the ones burned into the development builds.

Should i post the NBM's here?

Gesendet von guest am März 21, 2008 at 01:05 PM MEZ #

@ChinaBoy: Can you give me some more information, what exactly goes wrong?

Gesendet von guest am März 21, 2008 at 01:07 PM MEZ #

when I Create a new Grails Project,
come out a Warning incessant:
;might be because your user directory is on a Windows UNC path(issue #46813)? If so ,try using mapped drive letters.

Gesendet von ChinaBoy am März 21, 2008 at 10:04 PM MEZ #

Yes, it would be great when you could publish nbm-files which are installable in the NetBeans 6.1 beta.
And it would be much better, when there would be a source for getting up to date files for the next or for the official 6.1 release.
In this case much more people would use it and you could get much more feedback. Maybe you could also setup an online repository, it must not be the official one.

Bye,
Stefan

Gesendet von Stefan am März 22, 2008 at 06:14 AM MEZ #

Buen trabajo, espero ansioso una versión estable. Sigan adelante!

Gesendet von henry am März 23, 2008 at 10:02 AM MEZ #

Fantastic!

Gesendet von Dustin Whitney am März 24, 2008 at 10:33 AM MEZ #

I have the same problem as chinaboy.

veeeeery annoying!

WinXP SP2
JDK 1.6.0_05
netbeans-dev-20080325150617
Grails 1.0.2
Groovy 1.5.4

Gesendet von JS am März 25, 2008 at 11:31 AM MEZ #

oh yes,
the problem harassment me several day.
any body resolve this problem?

Gesendet von ChinaBoy am März 25, 2008 at 01:16 PM MEZ #

;might be because your user directory is on a Windows UNC path(issue #46813)? If so ,try using mapped drive letters.

SOLUCION: La ruata a la carpeta donde se encuentre nuestro proyecto no debe contener espacios por ejemplo:

C:\\Mis Documentos\\MiProyectoGrails

La anterior ruta es incorreta por que hay un espacio entre Mis y Documentos.

--

SOLUTION: The path to the folder that holds our project must not contain spaces for example:

C:\\My Documents\\MiProyectoGrails

The previous path was incorrect that there is a space between and My Documents.

Gesendet von henry am März 27, 2008 at 08:34 PM MEZ #

@henry
You Are right!
Thanks you for help me.

Gesendet von ChinaBoy am März 28, 2008 at 06:11 AM MEZ #

Yep it did the trick ...

By the way, it's really nice. I think Grails on Netbeans is one of the many «next big thing».

Here are some remarks though:

+ stop application doesn't work
+ the launch of the grails shell is a bit buggy

Also, some ideas for new features:

+ although the contextual menu is great, wouldn't it be great to have a small toolbar with 5 buttons (new [domain, controller, view, taglib, service]) and their keyboard shortcut?

+ integration with servers inside the IDE: right-click on a grails project -> deploy to -> GFv3/JBoss/Tomcat

Keep up. I can't wait for the new features.

Gesendet von JS am März 28, 2008 at 06:57 AM MEZ #

great wrappup! Nice to hear about the progress.

And bring on the debugger. I'm eager to get this for future projects :-)

Timo

Gesendet von Timo Haberkern am März 29, 2008 at 12:52 PM MEZ #

looks great but I do not unerstand why code completion still does not work.

Gesendet von baijianhua am März 29, 2008 at 07:08 PM MEZ #

I download netbeans night build and groovy plugin with the plugin manager. but unfortunately, the method completion does not work for me :-(
But this plugin is still very greate, keep on your wonderful work, guys

Gesendet von baijianhua am März 29, 2008 at 07:12 PM MEZ #

When the smart code completion come out?
I can not wait for!

Gesendet von smart code completion ? am März 30, 2008 at 07:08 AM MESZ #

I have installed Netbeans 6.1RC on OS-X 10.5, but I do not see the Groovy and Grails plugs-ins. Do I need to download the NBM from somewhere, if so - what and where from? Thanks for a great product, looking forward to using it with Groovy/Grails. Stephen

Gesendet von Stephen Lewis am April 16, 2008 at 10:05 AM MESZ #

Hi Stephen,

thanks for your interest. Please download the NBM's from the location given in section 2 from this later post:

http://blogs.sun.com/schmidtm/entry/back_from_easter_vacation_grails

They are hyperlinked. Take all six, save them locally and install them into NetBeans by going to "Tools/Plugins/Downloaded ..."

Gesendet von schmidtm am April 16, 2008 at 10:20 AM MESZ #

please help: i got error messages after downloading these:
\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* files
org-netbeans-modules-groovy-editor.nbm
org-netbeans-modules-groovy-grails.nbm
org-netbeans-modules-groovy-grailsproject.nbm
org-netbeans-modules-groovy-gsp.nbm
org-netbeans-modules-groovy-kit.nbm
org-netbeans-modules-groovy-support.nbm
\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* error
Missing required modules for Plugin Common Scripting Language API:
Common Scripting Language Support [module org.netbeans.modules.gsf/2 = 1]
Missing required modules for Plugin Common Scripting Language Support:
Common Scripting Language Support [module org.netbeans.modules.gsf/2 = 1]
Missing required modules for Plugin Embedded Ruby (RHTML):
Common Scripting Language Support [module org.netbeans.modules.gsf/2 = 1]
Missing required modules for Plugin Ruby Platform:
Common Scripting Language Support [module org.netbeans.modules.gsf/2 = 1]

Gesendet von yu le am April 27, 2008 at 06:47 AM MESZ #

this was also downloaded before error:
org-netbeans-modules-gsf-tools.nbm

Gesendet von yu le am April 27, 2008 at 06:49 AM MESZ #

I have the finished, released Netbeans 6.1 installed on my machine. But no Grails plugin is available. Is this as it should be?

Gesendet von Keith Thomas am August 26, 2008 at 11:08 AM MESZ #

@Keith Thomas[I have the finished, released Netbeans 6.1 installed on my machine. But no Grails plugin is available. Is this as it should be?]

R/

Debes usar una versión en desarrollo, por ejemplo NetBeans 6.5 Beta

--

You must use a development version, for example NetBeans 6.5 Beta

Gesendet von Henry am August 26, 2008 at 11:18 AM MESZ #

Senden Sie einen Kommentar:
  • HTML Syntax: Ausgeschaltet
About

schmidtm

Search

Archives
« April 2014
MoDiMiDoFrSaSo
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Heute