Annotation Type BatchMapping
Resolves a field for every object in a list with one call, as in Spring for
GraphQL: the answer to the N+1 problem of a SchemaMapping that would
otherwise query once per object.
The method takes a List of the sources and returns either a Map from
each source to its value, or a List with one value per source in order.
@BatchMapping(typeName = "Book")
public Map<Book, Author> author(List<Book> books) { ... }
-
Optional Element Summary
Optional Elements
-
Element Details
-
typeName
String typeNameThe object type the field belongs to; empty means the class's@SchemaMappingtype.- Default:
""
-
value
-
field
-