gorm data service findAllBy dynamic finder method referencing id property does not compile
- Dominant language
- Groovy
- Stars
- 2.9k
- Forks
- 975
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 92
Description
### Task List
- [x] Steps to reproduce provided
- [x] Stacktrace (if present) provided
- [x] Example that reproduces the problem uploaded to Github
- [x] Full description of the issue provided (see below)
### Steps to Reproduce
1. create a gorm data service like this:
```groovy
@Service(Dummy)
interface DummyDataService {
List findAllByIdInList(List ids)
}
```
2. try to compile (e.g. `gradle(w) classes`)
### Expected Behaviour
data service should compile
### Actual Behaviour
```
Cannot implement finder for non-existent property [id] of class [myapp.Dummy]
@ line 9, column 2.
List findAllByIdInList(List ids)
^
1 error
:compileGroovy FAILED
```
### Environment Information
- **Operating System**: win x64
- **GORM Version:** 6.1.10
- **Grails Version (if using Grails):** 3.3.8
- **JDK Version:** oracle 8u151
### Example Application
- sample app will be referenced in a minute
Contributor guide
Research direction
Start with the DummyDataService example and reproduce the failure using `gradle(w) classes` in the referenced example application. Trace the GORM data service dynamic finder handling for `findAllByIdInList`; done means the service compiles without reporting a missing `id` property.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- groovy
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100