You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@grails.apache.org by "jdaugherty (via GitHub)" <gi...@apache.org> on 2026/10/12 13:53:13 UTC
[PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
jdaugherty opened a new pull request, #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445
A GORM data service is an interface (`@Service(Quest) interface QuestService`) whose implementation GORM generates at compile time, but every artefact lookup in GrailsArtifact accepted GrClassDefinition only. The domain-class toolbar therefore said "Nothing here" under "Go To Service" for the service `generate-all` had just written, the interface itself got no toolbar, and the Spring bean discoverer skipped it, while a service written as a class resolved fine.
GrailsArtifact now asks a single `isArtefactDefinition` rule, which SERVICE overrides to admit GrInterfaceDefinition; getType, isInstance and the instance cache all go through it, so interfaces under other artefact directories remain unrecognised. The lookups return GrTypeDefinition, the common supertype, and callers were widened accordingly. GrailsTestCase's addService/addController accept interface and trait declarations so the case can be exercised in light fixtures.
Reported in the Grails 8 talk at https://github.com/kousen/holygrails8.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "jdaugherty (via GitHub)" <gi...@apache.org>.
jdaugherty commented on PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445#issuecomment-6301192345
@fernando88to I'm going to go ahead and merge this since I've addressed all of your feedback. If you feel there's more to do let me know and I'm happy to iterate. I'm trying to prep for a vote this week to release all of these changes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445#issuecomment-6127084638
## [Codecov](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:x: Patch coverage is `73.33333%` with `12 lines` in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 50.0267%. Comparing base ([`efcbecc`](https://app.codecov.io/gh/apache/grails-intellij-plugin/commit/efcbeccc78211f36ed1cd4c6dc75eb4e3bbd600f?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`7bef7c7`](https://app.codecov.io/gh/apache/grails-intellij-plugin/commit/7bef7c74acf803d79badc603309e9ac5448a5e8e?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 3 commits behind head on main.
| [Files with missing lines](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [...llij/plugin/actions/GrailsGotoRelatedProvider.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Factions%2FGrailsGotoRelatedProvider.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2FjdGlvbnMvR3JhaWxzR290b1JlbGF0ZWRQcm92aWRlci5qYXZh) | 0.0000% | [6 Missing :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...he/grails/intellij/plugin/util/GrailsArtifact.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Futil%2FGrailsArtifact.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL3V0aWwvR3JhaWxzQXJ0aWZhY3QuamF2YQ==) | 86.6667% | [0 Missing and 2 partials :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...ls/intellij/plugin/editor/GenerateTestsAction.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Feditor%2FGenerateTestsAction.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2VkaXRvci9HZW5lcmF0ZVRlc3RzQWN0aW9uLmphdmE=) | 0.0000% | [1 Missing :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...llij/plugin/editor/toolbar/GenerateActionBase.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Feditor%2Ftoolbar%2FGenerateActionBase.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2VkaXRvci90b29sYmFyL0dlbmVyYXRlQWN0aW9uQmFzZS5qYXZh) | 0.0000% | [1 Missing :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...n/editor/toolbar/GenerateControllerActionBase.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Feditor%2Ftoolbar%2FGenerateControllerActionBase.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2VkaXRvci90b29sYmFyL0dlbmVyYXRlQ29udHJvbGxlckFjdGlvbkJhc2UuamF2YQ==) | 0.0000% | [1 Missing :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...gin/references/filter/FilterReferenceProvider.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Freferences%2Ffilter%2FFilterReferenceProvider.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL3JlZmVyZW5jZXMvZmlsdGVyL0ZpbHRlclJlZmVyZW5jZVByb3ZpZGVyLmphdmE=) | 50.0000% | [1 Missing :warning: ](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
[](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
```diff
@@ Coverage Diff @@
## main #445 +/- ##
==================================================
+ Coverage 49.9918% 50.0267% +0.0349%
Complexity 551 551
==================================================
Files 699 699
Lines 24354 24355 +1
Branches 6368 6369 +1
==================================================
+ Hits 12175 12184 +9
+ Misses 9363 9353 -10
- Partials 2816 2818 +2
```
| [Files with missing lines](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [...ils/intellij/lib/testFramework/GrailsTestCase.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=libs%2FtestFramework%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Flib%2FtestFramework%2FGrailsTestCase.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-bGlicy90ZXN0RnJhbWV3b3JrL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovbGliL3Rlc3RGcmFtZXdvcmsvR3JhaWxzVGVzdENhc2UuamF2YQ==) | `91.7476% <100.0000%> (ø)` | |
| [...in/actions/GrailsCreateActionByUsageIntention.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Factions%2FGrailsCreateActionByUsageIntention.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2FjdGlvbnMvR3JhaWxzQ3JlYXRlQWN0aW9uQnlVc2FnZUludGVudGlvbi5qYXZh) | `72.9167% <100.0000%> (ø)` | |
| [...intellij/plugin/editor/toolbar/GoToTestAction.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Feditor%2Ftoolbar%2FGoToTestAction.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2VkaXRvci90b29sYmFyL0dvVG9UZXN0QWN0aW9uLmphdmE=) | `33.3333% <100.0000%> (ø)` | |
| [...n/editor/toolbar/GrailsGoToArtefactActionBase.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Feditor%2Ftoolbar%2FGrailsGoToArtefactActionBase.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2VkaXRvci90b29sYmFyL0dyYWlsc0dvVG9BcnRlZmFjdEFjdGlvbkJhc2UuamF2YQ==) | `41.6667% <ø> (+41.6667%)` | :arrow_up: |
| [.../plugin/lang/gsp/resolve/taglib/GspTagLibUtil.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Flang%2Fgsp%2Fresolve%2Ftaglib%2FGspTagLibUtil.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL2xhbmcvZ3NwL3Jlc29sdmUvdGFnbGliL0dzcFRhZ0xpYlV0aWwuamF2YQ==) | `86.2245% <100.0000%> (ø)` | |
| [...gin/references/controller/ControllerReference.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Freferences%2Fcontroller%2FControllerReference.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL3JlZmVyZW5jZXMvY29udHJvbGxlci9Db250cm9sbGVyUmVmZXJlbmNlLmphdmE=) | `77.7778% <100.0000%> (ø)` | |
| [...eferences/controller/GrailsNamespaceReference.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Freferences%2Fcontroller%2FGrailsNamespaceReference.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL3JlZmVyZW5jZXMvY29udHJvbGxlci9HcmFpbHNOYW1lc3BhY2VSZWZlcmVuY2UuamF2YQ==) | `62.5000% <100.0000%> (ø)` | |
| [.../plugin/references/urlMappings/UrlMappingUtil.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=plugin%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fplugin%2Freferences%2FurlMappings%2FUrlMappingUtil.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9ncmFpbHMvaW50ZWxsaWovcGx1Z2luL3JlZmVyZW5jZXMvdXJsTWFwcGluZ3MvVXJsTWFwcGluZ1V0aWwuamF2YQ==) | `67.5439% <100.0000%> (ø)` | |
| [...e/hibernate/persistent/GormPersistenceMapping.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=pluginModules%2Fhibernate%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fmodule%2Fhibernate%2Fpersistent%2FGormPersistenceMapping.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luTW9kdWxlcy9oaWJlcm5hdGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2dyYWlscy9pbnRlbGxpai9tb2R1bGUvaGliZXJuYXRlL3BlcnNpc3RlbnQvR29ybVBlcnNpc3RlbmNlTWFwcGluZy5qYXZh) | `50.0000% <100.0000%> (ø)` | |
| [...llij/module/spring/GrailsSpringBeanDiscoverer.java](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree&filepath=pluginModules%2Fspring%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fgrails%2Fintellij%2Fmodule%2Fspring%2FGrailsSpringBeanDiscoverer.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-cGx1Z2luTW9kdWxlcy9zcHJpbmcvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2dyYWlscy9pbnRlbGxpai9tb2R1bGUvc3ByaW5nL0dyYWlsc1NwcmluZ0JlYW5EaXNjb3ZlcmVyLmphdmE=) | `66.3462% <100.0000%> (ø)` | |
| ... and [6 more](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | |
... and [5 files with indirect coverage changes](https://app.codecov.io/gh/apache/grails-intellij-plugin/pull/445/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
</details>
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "jdaugherty (via GitHub)" <gi...@apache.org>.
jdaugherty commented on PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445#issuecomment-6126841899
@fernando88to would you be willing to review this bug fix?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "jdaugherty (via GitHub)" <gi...@apache.org>.
jdaugherty merged PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "jdaugherty (via GitHub)" <gi...@apache.org>.
jdaugherty commented on code in PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445#discussion_r4289550668
##########
plugin/src/main/java/org/apache/grails/intellij/plugin/util/GrailsArtifact.java:
##########
@@ -80,7 +81,16 @@ public enum GrailsArtifact {
DOMAIN(NotNullLazyValue.createValue(() -> AllIcons.Nodes.DataTables), "", "domain"),
CONTROLLER(NotNullLazyValue.createValue(() -> AllIcons.Nodes.Controller), "Controller", "controllers"),
TAGLIB(NotNullLazyValue.createValue(() -> GroovyMvcIcons.Taglib), "TagLib", "taglib"),
- SERVICE(NotNullLazyValue.createValue(() -> AllIcons.FileTypes.Config), "Service", "services"),
+ SERVICE(NotNullLazyValue.createValue(() -> AllIcons.FileTypes.Config), "Service", "services") {
+ /**
+ * A GORM data service is an interface annotated with {@code grails.gorm.services.Service}; GORM
+ * generates the implementation at compile time, so the interface is the only source artefact.
Review Comment:
Good catch, thanks. Reworded in af60dd8 along the lines of your suggestion, with the reason spelled out (the annotation may not resolve). Also added `testUnannotatedServiceInterfaceIsAServiceArtefact` so the documented behaviour is pinned: a plain `interface PricingService` under `grails-app/services` is recognised as a service.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Recognise GORM data services declared as interfaces [grails-intellij-plugin]
Posted by "fernando88to (via GitHub)" <gi...@apache.org>.
fernando88to commented on code in PR #445:
URL: https://github.com/apache/grails-intellij-plugin/pull/445#discussion_r4265989011
##########
plugin/src/main/java/org/apache/grails/intellij/plugin/util/GrailsArtifact.java:
##########
@@ -80,7 +81,16 @@ public enum GrailsArtifact {
DOMAIN(NotNullLazyValue.createValue(() -> AllIcons.Nodes.DataTables), "", "domain"),
CONTROLLER(NotNullLazyValue.createValue(() -> AllIcons.Nodes.Controller), "Controller", "controllers"),
TAGLIB(NotNullLazyValue.createValue(() -> GroovyMvcIcons.Taglib), "TagLib", "taglib"),
- SERVICE(NotNullLazyValue.createValue(() -> AllIcons.FileTypes.Config), "Service", "services"),
+ SERVICE(NotNullLazyValue.createValue(() -> AllIcons.FileTypes.Config), "Service", "services") {
+ /**
+ * A GORM data service is an interface annotated with {@code grails.gorm.services.Service}; GORM
+ * generates the implementation at compile time, so the interface is the only source artefact.
Review Comment:
The javadoc says "annotated with `grails.gorm.services.Service`", but the code accepts any
interface and never checks the annotation. A quick test confirms that a plain
`interface PricingService` without `@Service` under `grails-app/services` is recognised as a
service. I think not requiring the annotation is right, since it may not resolve, but the comment
should say so:
```suggestion
* A GORM data service ({@code @Service(Domain) interface FooService}) is an interface whose
* implementation GORM generates at compile time. The annotation is not checked: any interface
* named {@code *Service} under {@code grails-app/services} is a service artefact.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org