-
Notifications
You must be signed in to change notification settings - Fork 1.5k
ClassCastException in PersistenceProvider$HibernateScrollableResultsIterator.next with GraalVM native-image #2848
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
Comments
@derkoe thanks for reporting and the reproducer. We'll look into it. |
We're missing a reflection hint to look up the @SpringBootApplication
@ImportRuntimeHints(MyJpaRuntimeHints.class)
public class JpaNativeApplication { ...
// ...
public class MyJpaRuntimeHints implements RuntimeHintsRegistrar {
@Override
public void registerHints(RuntimeHints hints, ClassLoader classLoader) {
hints.reflection().registerType(Query.class, MemberCategory.INVOKE_PUBLIC_METHODS);
} |
christophstrobl
added a commit
that referenced
this issue
Mar 22, 2023
This commit makes sure we're able to invoke the method required for streaming results. Resolves: #2848
christophstrobl
added a commit
to christophstrobl/spring-aot-smoke-tests
that referenced
this issue
Mar 22, 2023
gregturn
pushed a commit
that referenced
this issue
Mar 22, 2023
This commit makes sure we're able to invoke the method required for streaming results. Resolves: #2848
Merged to |
klajdipaja
pushed a commit
to klajdipaja/spring-data-jpa
that referenced
this issue
Mar 24, 2023
This commit makes sure we're able to invoke the method required for streaming results. Resolves: spring-projects#2848
wilkinsona
pushed a commit
to spring-projects/spring-aot-smoke-tests
that referenced
this issue
Apr 18, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When you create a repository method that returns a
Stream<Entity>
and you compile and run the application with GraalVM native-image the following error occurs:How to reproduce:
You can also build the app with native-image, run it and open http://localhost:8080/test
Here is the full stack trace of the error when calling http://localhost:8080/test
Environment
The text was updated successfully, but these errors were encountered: