-
Notifications
You must be signed in to change notification settings - Fork 683
Update documentation. #3174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update documentation. #3174
Conversation
Add section on reserved method names within repository interfaces.
@@ -37,6 +37,11 @@ public interface CrudRepository<T, ID> extends Repository<T, ID> { | |||
The methods declared in this interface are commonly referred to as CRUD methods. | |||
`ListCrudRepository` offers equivalent methods, but they return `List` where the `CrudRepository` methods return an `Iterable`. | |||
|
|||
[IMPORTANT] | |||
==== | |||
The repository interface implies a few reserved methods like `findById(ID identifier)` that always target the domain types identifier property regardless of its property name. Read more about this in "`xref:repositories/query-methods-details.adoc#repositories.query-methods.reserved-methods[Defining Query Methods]`". |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to watch for broken references in case a Data module doesn't ship a repositories/query-methods-details.adoc
documentation page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there one you're aware of right off the top of your head?
Add DDD context. Explain identifier to domain object relationship. Tweak wording.
[TIP] | ||
==== | ||
Spring Data considers domain types to be entities, more specifically aggregates. | ||
So you will see the term "entity" used throughout the documentation that can be interchanged with the term "domain type" or "aggregate". |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@odrotbohm any opinion on wording? We want to make the point that identifiers need sometimes a different handling than properties, yet in both cases we need to express access to these via some name.
Add section on reserved method names within repository interfaces.
Related to: #3173