This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 210382 - Convert groovy cluster to new @DataObject.Registration annotation
Summary: Convert groovy cluster to new @DataObject.Registration annotation
Status: RESOLVED FIXED
Alias: None
Product: groovy
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.2
Hardware: PC Windows 7
: P4 normal (vote)
Assignee: Martin Janicek
URL:
Keywords:
Depends on: 208394
Blocks:
  Show dependency tree
 
Reported: 2012-03-29 15:40 UTC by skygo
Modified: 2012-04-04 10:09 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Convertion proposal of layer folder on cluster (51.53 KB, patch)
2012-03-29 21:29 UTC, skygo
Details | Diff
Convertion proposal of layer folder on cluster (54.02 KB, patch)
2012-03-30 09:51 UTC, skygo
Details | Diff
Convertion proposal of layer folder on cluster (54.02 KB, patch)
2012-03-30 12:07 UTC, skygo
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description skygo 2012-03-29 15:40:05 UTC
Hi,
I am opening this task to offer refactoring of groovy cluster to new @DataObject.Registration and some related cleaning (i.e. using constant) Some Loader related action will also be patched.

I first need to have agreement of assignee to review change and then I will work on the patch.
Comment 1 Martin Janicek 2012-03-29 15:48:33 UTC
Sure, I'll be more than happy to review your changes ;]
Comment 2 skygo 2012-03-29 21:29:51 UTC
Created attachment 117509 [details]
Convertion proposal of layer folder on cluster

This patch concern the following module of the cluster

groovy.editor
groovy.grailsproject
groovy.gsp
groovy.support

Action rewrite using annotation with messages anotation also.

As groovy.editor use language annotation I was not able to completly remove the Loaders folder to keep icon (with blue star) usage.

Seems that unit test of groovy.editor is broken but not sure I'am gulty :p.
I am not using groovy so any regression (menu, visual placement)you may see please let me know ;p.



PS:
Fix 2 duplicated nbjunit present in project.xml to be sure not interfering with my build.
Comment 3 Martin Janicek 2012-03-30 06:19:05 UTC
After applying your patch I can see one regression. GSP files (most probably related to groovy.gsp module) aren't recognized and thus language coloring, highlighting etc. isn't working.
Comment 4 Martin Janicek 2012-03-30 06:26:59 UTC
Not sure if it might cause the problem but looking at diff, GspDataLoader is using DataObject.Registration annotation, but gsp language is also registered via @Language annotation (see GspLanguage class). Maybe we should move action registrations to GspLanguage in the same way as it is in GroovyLanguage?
Comment 5 skygo 2012-03-30 09:51:50 UTC
Created attachment 117532 [details]
Convertion proposal of layer folder on cluster

I factorize more to avoid typo into the gsp module.

I reintroduce the icon for gsp file.

I install grails and I see all actions on gsp file and I can use autocompletion with color. (gsp appears to be kind of html to me).
Comment 6 Martin Janicek 2012-03-30 10:20:48 UTC
Ok, new patch seems to me fine. Just one small cosmetic change - please delete the empty comment before GroovyProjectModule class declaration.

Btw: I really like these changes :] .. annotations are so much readable than the old layer based code.
Comment 7 Martin Janicek 2012-03-30 10:22:20 UTC
Oops, whiteboard was changed by mistake --> clearing it
Comment 8 skygo 2012-03-30 12:07:45 UTC
Created attachment 117539 [details]
Convertion proposal of layer folder on cluster

Remove of the empty comment. 


PS: some of layer entry can be refactored to use Template annotation. (but to stay on topic I did not refactor them)
Comment 9 Martin Janicek 2012-03-30 14:48:09 UTC
Great I'm totally satisfied with the last diff. Do you have privileges for pushing those changes or should I integrate them by myself?
Comment 10 skygo 2012-03-30 15:05:13 UTC
I have not asked for this privilege yet :p you must push this change yourself.
Comment 11 Martin Janicek 2012-03-30 15:10:01 UTC
Ok, I'm on it. Thanks a lot for your contribution!
Comment 12 Martin Janicek 2012-04-03 07:37:10 UTC
Fixed in: web-main #a980fcca1932
Comment 13 Quality Engineering 2012-04-04 10:09:14 UTC
Integrated into 'main-golden', will be available in build *201204040400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/a980fcca1932
User: Martin Janicek <mjanicek@netbeans.org>
Log: #210382 - Convert groovy cluster to new @DataObject.Registration annotation