Browse Source

Provide a more actionable CGLIB error message with native

Closes gh-34370
pull/34387/head
Sébastien Deleuze 12 months ago
parent
commit
16ec08aec8
  1. 2
      spring-core/src/main/java/org/springframework/cglib/core/AbstractClassGenerator.java

2
spring-core/src/main/java/org/springframework/cglib/core/AbstractClassGenerator.java

@ -360,7 +360,7 @@ abstract public class AbstractClassGenerator<T> implements ClassGenerator { @@ -360,7 +360,7 @@ abstract public class AbstractClassGenerator<T> implements ClassGenerator {
// SPRING PATCH BEGIN
if (inNativeImage) {
throw new UnsupportedOperationException("CGLIB runtime enhancement not supported on native image. " +
"Make sure to include a pre-generated class on the classpath instead: " + getClassName());
"Make sure to enable Spring AOT processing in order to pre-generate this class: " + getClassName());
}
// SPRING PATCH END
byte[] b = strategy.generate(this);

Loading…
Cancel
Save