diff --git a/packages/java/parser-jvm-plugin-backbone/src/main/java/com/vaadin/hilla/parser/plugins/backbone/EndpointExposedPlugin.java b/packages/java/parser-jvm-plugin-backbone/src/main/java/com/vaadin/hilla/parser/plugins/backbone/EndpointExposedPlugin.java index 34c591d0ce..d7ef7ddaae 100644 --- a/packages/java/parser-jvm-plugin-backbone/src/main/java/com/vaadin/hilla/parser/plugins/backbone/EndpointExposedPlugin.java +++ b/packages/java/parser-jvm-plugin-backbone/src/main/java/com/vaadin/hilla/parser/plugins/backbone/EndpointExposedPlugin.java @@ -95,12 +95,20 @@ public NodeDependencies scan(@NonNull NodeDependencies nodeDependencies) { .getEndpointExposedAnnotationName(); var exposed = classInfo.getAnnotations().stream() .map(AnnotationInfoModel::getName) - .anyMatch(endpointExposedAnnotationName::equals); + .anyMatch(endpointExposedAnnotationName::equals) + || alwaysExpose(classInfo); var classInfoNode = exposed ? EndpointExposedNode.of(classInfo) : EndpointNonExposedNode.of(classInfo); return classInfoNode; } + private boolean alwaysExpose(ClassInfoModel classInfo) { + return classInfo + .is("com.vaadin.flow.spring.data.jpa.CrudRepositoryService") + || classInfo.is( + "com.vaadin.flow.spring.data.jpa.ListRepositoryService"); + } + /** * Replaces generic type parameters used in {@code @EndpointExposed} with * their arguments defined in type signatures of endpoint class hierarchy